Skip to content

Commit 1efde76

Browse files
authored
PYTHON-1384 Remove usages of unittest.assertDictContainsSubset (#1206)
1 parent 7780e90 commit 1efde76

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

tests/integration/cqlengine/management/test_management.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ def test_table_property_update(self):
254254

255255
table_options = management._get_table_metadata(ModelWithTableProperties).options
256256

257-
self.assertDictContainsSubset(ModelWithTableProperties.__options__, table_options)
257+
self.assertLessEqual(ModelWithTableProperties.__options__.items(), table_options.items())
258258

259259
def test_bogus_option_update(self):
260260
sync_table(ModelWithTableProperties)

tests/integration/standard/test_metadata.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1751,9 +1751,9 @@ def test_init_cond(self):
17511751
cql_init = encoder.cql_encode_all_types(init_cond)
17521752
with self.VerifiedAggregate(self, **self.make_aggregate_kwargs('update_map', 'map<int, int>', init_cond=cql_init)) as va:
17531753
map_res = s.execute("SELECT %s(v) AS map_res FROM t" % va.function_kwargs['name'])[0].map_res
1754-
self.assertDictContainsSubset(expected_map_values, map_res)
1754+
self.assertLessEqual(expected_map_values.items(), map_res.items())
17551755
init_not_updated = dict((k, init_cond[k]) for k in set(init_cond) - expected_key_set)
1756-
self.assertDictContainsSubset(init_not_updated, map_res)
1756+
self.assertLessEqual(init_not_updated.items(), map_res.items())
17571757
c.shutdown()
17581758

17591759
def test_aggregates_after_functions(self):

0 commit comments

Comments
 (0)