Skip to content

Commit 0c74a59

Browse files
committed
Merge pull request #1372 from dhermes/test-proj-query-order
Using query order in test_projection_query.
2 parents 03d4104 + ac6b80f commit 0c74a59

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

system_tests/datastore.py

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -269,6 +269,7 @@ def test_ordered_query(self):
269269
def test_projection_query(self):
270270
filtered_query = self._base_query()
271271
filtered_query.projection = ['name', 'family']
272+
filtered_query.order = ['name', 'family']
272273

273274
# NOTE: There are 9 responses because of Catelyn. She has both
274275
# Stark and Tully as her families, hence occurs twice in
@@ -279,6 +280,9 @@ def test_projection_query(self):
279280
self.assertEqual(len(entities), expected_matches)
280281

281282
arya_entity = entities[0]
283+
catelyn_tully_entity = entities[3]
284+
sansa_entity = entities[8]
285+
282286
arya_dict = dict(arya_entity)
283287
self.assertEqual(arya_dict, {'name': 'Arya', 'family': 'Stark'})
284288

@@ -287,13 +291,6 @@ def test_projection_query(self):
287291
self.assertEqual(catelyn_stark_dict,
288292
{'name': 'Catelyn', 'family': 'Stark'})
289293

290-
if EMULATOR_DATASET is None:
291-
catelyn_tully_entity = entities[3]
292-
sansa_entity = entities[8]
293-
else:
294-
catelyn_tully_entity = entities[8]
295-
sansa_entity = entities[7]
296-
297294
catelyn_tully_dict = dict(catelyn_tully_entity)
298295
self.assertEqual(catelyn_tully_dict,
299296
{'name': 'Catelyn', 'family': 'Tully'})

0 commit comments

Comments
 (0)