mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-30 16:58:40 -04:00
tests: fix syntax error on Python 3
This commit is contained in:
parent
b73c627c61
commit
dc1f5dd3b1
@ -105,8 +105,9 @@ def test_seq_property_getitem():
|
||||
assert prop[-3] == item_a
|
||||
|
||||
# Long index
|
||||
assert prop[1L] == item_b
|
||||
assert prop[-1L] == item_b
|
||||
if sys.version_info[0] < 3:
|
||||
assert prop[long(1)] == item_b
|
||||
assert prop[long(-1)] == item_b
|
||||
|
||||
# Out of bounds access
|
||||
with pytest.raises(IndexError):
|
||||
@ -158,10 +159,11 @@ def test_seq_property_setitem():
|
||||
assert tuple(prop) == (item_c, item_b, item_a)
|
||||
|
||||
# Long index
|
||||
prop[1L] = item_b
|
||||
assert prop[1] == item_b
|
||||
prop[-1L] = item_b
|
||||
assert prop[-1] == item_b
|
||||
if sys.version_info[0] < 3:
|
||||
prop[long(1)] = item_b
|
||||
assert prop[1] == item_b
|
||||
prop[long(-1)] = item_b
|
||||
assert prop[-1] == item_b
|
||||
|
||||
# Out of bounds access
|
||||
with pytest.raises(IndexError):
|
||||
|
Loading…
x
Reference in New Issue
Block a user