Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[#118] Replace assertEquals with assertEqual in tests (main) #120

Merged
merged 1 commit into from
Aug 6, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions packaging/test_rule_engine_plugin_logical_quotas.py
Original file line number Diff line number Diff line change
Expand Up @@ -563,10 +563,10 @@ def test_adding_duplicate_attribute_names_with_different_values_or_units_is_not_

# Assert that the quota values are what we expect them to be.
values = self.get_logical_quotas_attribute_values(col, include_max_values=True)
self.assertEquals(values[self.maximum_number_of_data_objects_attribute()], 10)
self.assertEquals(values[self.maximum_size_in_bytes_attribute()], 1000)
self.assertEquals(values[self.total_number_of_data_objects_attribute()], 0)
self.assertEquals(values[self.total_size_in_bytes_attribute()], 0)
self.assertEqual(values[self.maximum_number_of_data_objects_attribute()], 10)
self.assertEqual(values[self.maximum_size_in_bytes_attribute()], 1000)
self.assertEqual(values[self.total_number_of_data_objects_attribute()], 0)
self.assertEqual(values[self.total_size_in_bytes_attribute()], 0)

expected_output = ['-169000 SYS_NOT_ALLOWED']

Expand All @@ -584,10 +584,10 @@ def test_adding_duplicate_attribute_names_with_different_values_or_units_is_not_

# Show that the quota values have not changed.
values = self.get_logical_quotas_attribute_values(col, include_max_values=True)
self.assertEquals(values[self.maximum_number_of_data_objects_attribute()], 10)
self.assertEquals(values[self.maximum_size_in_bytes_attribute()], 1000)
self.assertEquals(values[self.total_number_of_data_objects_attribute()], 0)
self.assertEquals(values[self.total_size_in_bytes_attribute()], 0)
self.assertEqual(values[self.maximum_number_of_data_objects_attribute()], 10)
self.assertEqual(values[self.maximum_size_in_bytes_attribute()], 1000)
self.assertEqual(values[self.total_number_of_data_objects_attribute()], 0)
self.assertEqual(values[self.total_size_in_bytes_attribute()], 0)

@unittest.skipIf(test.settings.RUN_IN_TOPOLOGY, "Skip for Topology Testing")
def test_executing_logical_quotas_rules_do_not_fail_when_group_permissions_are_present__issue_46(self):
Expand Down Expand Up @@ -940,8 +940,8 @@ def make_directory(self, dir_name, files, file_size):

def assert_quotas(self, coll, expected_number_of_objects, expected_size_in_bytes):
values = self.get_logical_quotas_attribute_values(coll)
self.assertEquals(values[self.total_number_of_data_objects_attribute()], expected_number_of_objects)
self.assertEquals(values[self.total_size_in_bytes_attribute()], expected_size_in_bytes)
self.assertEqual(values[self.total_number_of_data_objects_attribute()], expected_number_of_objects)
self.assertEqual(values[self.total_size_in_bytes_attribute()], expected_size_in_bytes)

def enable_rule_engine_plugin(self, config, namespace=None):
config.server_config['log_level']['rule_engine'] = 'trace'
Expand Down
Loading