Skip to content

Commit

Permalink
Tests fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
khozzy committed Nov 26, 2020
1 parent 2d53ab4 commit 8522c11
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
3 changes: 1 addition & 2 deletions gym_corridor/tests/test_corridor.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ def test_should_return_state_action_dict(self):

# then
assert len(sa) == 20
assert sa["0"] == [MOVE_RIGHT]
assert sa["19"] == []
for i in range(1, 18):
for i in range(0, 18):
assert sa[str(i)] == [MOVE_LEFT, MOVE_RIGHT]
6 changes: 3 additions & 3 deletions gym_fsw/tests/test_fsw.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ def test_should_initialize(self):

# then
assert fsw is not None
assert 1 == fsw.observation_space.n
assert 11 == fsw.observation_space.n
assert 2 == fsw.action_space.n

def test_should_start_from_initial_position(self):
Expand Down Expand Up @@ -41,7 +41,7 @@ def test_should_follow_optimal_path_and_find_reward(self):
assert state == '4'

state, reward, done, _ = fsw.step(0)
assert state == '5'
assert state == '10'
assert reward == 100
assert done is True

Expand Down Expand Up @@ -98,7 +98,7 @@ def test_should_initialize_bigger_environment(self):
assert state == '2'

state, _, _, _ = fsw.step(1)
assert state == '13'
assert state == '12'

def test_should_get_all_states_and_actions(self):
# given
Expand Down

0 comments on commit 8522c11

Please sign in to comment.