Esempio n. 1
0
def test_list_wrap_list():
    assert isinstance(a[2], PropList)
    assert isinstance(get(a, 2), PropList)
Esempio n. 2
0
def test_dict_wrap_list():
    assert isinstance(d.qualities, PropList)
    assert isinstance(d["qualities"], PropList)
    assert isinstance(get(d, "qualities"), PropList)
Esempio n. 3
0
def test_list_wrap_dict():
    assert isinstance(a[1], PropDict)
    assert isinstance(get(a, 1), PropDict)
Esempio n. 4
0
def test_dict_wrap_dict():
    assert isinstance(d.info, PropDict)
    assert isinstance(d["info"], PropDict)
    assert isinstance(get(d, "info"), PropDict)
Esempio n. 5
0
def test_list_access():
    assert a[0] == 1
    assert get(a, 0) == 1
Esempio n. 6
0
def test_dict_access():
    print(type(d))
    assert d.name == "abcdef"
    assert d["name"] == "abcdef"
    assert get(d, "name") == "abcdef"