Skip to content

Commit aae8cc3

Browse files
committed
tests: cosmetical changes
1 parent 77b42a5 commit aae8cc3

12 files changed

+18
-1
lines changed

test/test_animation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ def __init__(self):
1717
x,y = director.get_window_size()
1818

1919
self.sprite = Sprite(pyglet.resource.animation('dinosaur.gif'))
20-
self.sprite.position = 0, y/2
20+
self.sprite.position = x/2, y/2
2121
self.add( self.sprite )
2222

2323

test/test_recorder.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ def __init__(self):
2727

2828

2929
if __name__ == "__main__":
30+
print "records 6 seconds, snapshots in the tmp subdir"
3031
director.set_recorder(25, "tmp/frame-%d.png", 6)
3132
director.init()
3233
test_layer = TestLayer ()

test/test_remove_add_by_name.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@
1111

1212

1313
if __name__ == "__main__":
14+
print "in cocos 0.3.0 and cocos 0.4.0 is expected to fail"
15+
print "with traceback ... :Exception: Name already exists: color"
16+
1417
director.init( resizable=True )
1518

1619
main_scene = cocos.scene.Scene()

test/test_rotate_move_reverse.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ def on_key_press(self, k, m):
3535
self.sprite.do(action + Reverse(action))
3636

3737
if __name__=="__main__":
38+
print "press space to initiate action"
3839
director.init(fullscreen=0, width=800, height=600)
3940
scene = cocos.scene.Scene()
4041
scene.add(Logo())

test/test_schedule.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ def change_y(self, dt):
3333

3434

3535
if __name__ == "__main__":
36+
print "sprite will change to a random position each second"
3637
director.init()
3738
test_layer = TestLayer ()
3839
main_scene = cocos.scene.Scene (test_layer)

test/test_sequence1.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ def __init__(self):
2424

2525

2626
if __name__ == "__main__":
27+
print "sprite moves to midscreen and then hides"
2728
director.init()
2829
test_layer = TestLayer ()
2930
main_scene = cocos.scene.Scene (test_layer)

test/test_sequence2.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ def __init__(self):
2424

2525

2626
if __name__ == "__main__":
27+
print "sprite moves from left border to midscreen,\nteleports down,\nmoves to right border"
2728
director.init()
2829
test_layer = TestLayer ()
2930
main_scene = cocos.scene.Scene (test_layer)

test/test_sequence3.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ def __init__(self):
3030

3131

3232
if __name__ == "__main__":
33+
print "starting from midscreen, sprite 1 moves left and then up;"
34+
print "sprite2 does the reverse action "
3335
director.init()
3436
test_layer = TestLayer ()
3537
main_scene = cocos.scene.Scene (test_layer)

test/test_sequence4.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ def __init__(self):
2626

2727

2828
if __name__ == "__main__":
29+
print " sprite starts at the left, goes to center screen and"
30+
print "then does the reverse action."
2931
director.init()
3032
test_layer = TestLayer ()
3133
main_scene = cocos.scene.Scene (test_layer)

test/test_sequence5.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ def __init__(self):
2424

2525

2626
if __name__ == "__main__":
27+
print "starting from left border, sprites moves"
28+
print "two times screen_width/2 to the right."
2729
director.init()
2830
test_layer = TestLayer ()
2931
main_scene = cocos.scene.Scene (test_layer)

test/test_target.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ def __init__(self):
3131

3232

3333
if __name__ == "__main__":
34+
print "two actions at the same time"
3435
director.init()
3536
test_layer = TestLayer ()
3637
main_scene = cocos.scene.Scene (test_layer)

test/test_unscaled_win_resize.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ def __init__(self):
2323

2424

2525
if __name__ == "__main__":
26+
print "Using do_not_scale=True in director.init, content will not"
27+
print "be scaled on resize. Use ctrl-f to toggle fullscreen"
2628
director.init(width=300, height=300, do_not_scale=True)
2729
test_layer = TestLayer ()
2830
main_scene = cocos.scene.Scene (test_layer)

0 commit comments

Comments
 (0)