9
9
from game_map import GameMap
10
10
from entity import Actor
11
11
12
+
12
13
class TestSetupGame (unittest .TestCase ):
13
14
def test_new_game (self ):
14
15
'''
@@ -20,12 +21,13 @@ def test_new_game(self):
20
21
self .assertIsInstance (eng .game_map , GameMap )
21
22
self .assertIsInstance (eng .player , Actor )
22
23
24
+
23
25
class TestMainMenu (unittest .TestCase ):
24
26
def test_on_render (self ):
25
27
'''
26
28
test that the main menu:
27
29
draws the background, prints some text
28
- '''
30
+ '''
29
31
mm = setup_game .MainMenu ()
30
32
console = tcod .console .Console (width = 10 , height = 10 , order = 'F' )
31
33
@@ -75,19 +77,19 @@ def test_ev_keydown_n(self):
75
77
ret = mm .ev_keydown (event = event )
76
78
self .assertIsInstance (ret , MainGameEventHandler )
77
79
78
- def test_ev_keydown_c (self ):
79
- '''
80
- test that pressing c will return None since we've not
81
- implemented saving and continuing yet
82
- '''
83
- mm = setup_game .MainMenu ()
84
- event = tcod .event .KeyDown (
85
- scancode = tcod .event .Scancode .C ,
86
- sym = tcod .event .K_c ,
87
- mod = tcod .event .Modifier .NONE
88
- )
89
- ret = mm .ev_keydown (event = event )
90
- self .assertIsNone (ret )
80
+ # def test_ev_keydown_c(self):
81
+ # '''
82
+ # test that pressing c will return None since we've not
83
+ # implemented saving and continuing yet
84
+ # '''
85
+ # mm = setup_game.MainMenu()
86
+ # event = tcod.event.KeyDown(
87
+ # scancode=tcod.event.Scancode.C,
88
+ # sym=tcod.event.K_c,
89
+ # mod=tcod.event.Modifier.NONE
90
+ # )
91
+ # ret = mm.ev_keydown(event=event)
92
+ # self.assertIsNone(ret)
91
93
92
94
def test_ev_keydown_other (self ):
93
95
'''
@@ -100,4 +102,4 @@ def test_ev_keydown_other(self):
100
102
mod = tcod .event .Modifier .NONE
101
103
)
102
104
ret = mm .ev_keydown (event = event )
103
- self .assertIsNone (ret )
105
+ self .assertIsNone (ret )
0 commit comments