blob: eb658e968389db7684d4aee27c1ddc19af214c39 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
import libpry
from libpathod import utils
class uparse_anchor_spec(libpry.AutoTree):
def test_simple(self):
assert utils.parse_anchor_spec("foo=200", {}) == ("foo", "200")
libpry.raises(utils.AnchorError, utils.parse_anchor_spec, "foobar", {})
libpry.raises(utils.AnchorError, utils.parse_anchor_spec, "*=200", {})
libpry.raises(utils.AnchorError, utils.parse_anchor_spec, "foo=bar", {})
class udata_path(libpry.AutoTree):
def test_simple(self):
libpry.raises(ValueError, utils.data.path, "nonexistent")
tests = [
udata_path(),
uparse_anchor_spec()
]
|