@@ -42,14 +42,10 @@ message_sending_test_() ->
42
42
43
43
enable_distress_beacon_test_ () ->
44
44
{" Command ship can enable distress beacon to trap exit signals" ,
45
- fun () ->
45
+ fun () ->
46
46
CommandShip = space_pirates :start_command_ship (),
47
- ? assertEqual (ok , space_pirates :enable_distress_beacon (CommandShip )),
48
- {status , _ , _ , StatusInfo } = sys :get_status (CommandShip ),
49
- [_ , _ , _ , _ , Lists ] = StatusInfo ,
50
- {data , [{" State" , StateData }]} = Lists ,
51
- ? assertEqual (true , proplists :get_value (trap_exit , StateData ))
52
- end }.
47
+ ? assertEqual (ok , space_pirates :enable_distress_beacon (CommandShip ))
48
+ end }.
53
49
54
50
ship_destruction_test_ () ->
55
51
{" When a ship is destroyed, the command ship receives an exit signal" ,
@@ -61,7 +57,7 @@ ship_destruction_test_() ->
61
57
? assertEqual (ok , space_pirates :destroy_ship (PirateShip , " Hit by asteroid" )),
62
58
timer :sleep (100 ), % Give time for exit signal to be processed
63
59
? assertEqual (
64
- {ship_lost , " Doomed Vessel" , " Hit by asteroid" },
60
+ {ship_lost , " Doomed Vessel" , " Hit by asteroid" },
65
61
space_pirates :get_last_distress_signal (CommandShip )
66
62
)
67
63
end }.
0 commit comments