Skip to content

Commit 0d96a1b

Browse files
committed
Changing new index names to be alphabetical for teams example
1 parent 5a66f94 commit 0d96a1b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

autonormalize/tests/test_normalize.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ def test_variable_types():
234234
def test_make_entityset_default_args(teams_input):
235235
normalized_entityset = autonormalize.make_entityset(teams_input.get_df(), teams_input.get_deps())
236236

237-
dic_one = {'team_jersey_num': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9],
237+
dic_one = {'jersey_num_team': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9],
238238
'team': ['Red', 'Red', 'Red', 'Orange', 'Orange', 'Yellow',
239239
'Yellow', 'Green', 'Green', 'Blue'],
240240
'jersey_num': [1, 2, 3, 1, 2, 1, 5, 8, 2, 2],
@@ -254,7 +254,7 @@ def test_make_entityset_default_args(teams_input):
254254
assert normalized_entityset.entities[2].df.equals(pd.DataFrame(
255255
dic_three, index=['austin', 'boston', 'chicago', 'honolulu']))
256256

257-
assert normalized_entityset.entities[0].variable_types['team_jersey_num'] == Index
257+
assert normalized_entityset.entities[0].variable_types['jersey_num_team'] == Index
258258
assert normalized_entityset.entities[0].variable_types['team'] == Id
259259
assert normalized_entityset.entities[0].variable_types['jersey_num'] == Numeric
260260
assert normalized_entityset.entities[0].variable_types['player_name'] == Categorical
@@ -272,7 +272,7 @@ def test_make_entityset_custom_args(teams_input):
272272
name='Teams',
273273
variable_types={'state': Text})
274274

275-
dic_one = {'team_jersey_num': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9],
275+
dic_one = {'jersey_num_team': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9],
276276
'team': ['Red', 'Red', 'Red', 'Orange', 'Orange', 'Yellow',
277277
'Yellow', 'Green', 'Green', 'Blue'],
278278
'jersey_num': [1, 2, 3, 1, 2, 1, 5, 8, 2, 2],
@@ -293,7 +293,7 @@ def test_make_entityset_custom_args(teams_input):
293293
assert normalized_entityset.entities[2].df.equals(pd.DataFrame(
294294
dic_three, index=['austin', 'boston', 'chicago', 'honolulu']))
295295

296-
assert normalized_entityset.entities[0].variable_types['team_jersey_num'] == Index
296+
assert normalized_entityset.entities[0].variable_types['jersey_num_team'] == Index
297297
assert normalized_entityset.entities[0].variable_types['team'] == Id
298298
assert normalized_entityset.entities[0].variable_types['jersey_num'] == Numeric
299299
assert normalized_entityset.entities[0].variable_types['player_name'] == Categorical

0 commit comments

Comments
 (0)