def test_bloom_filter_will_be_disabled(self): self.create_index('test_index') # Bloom filters have been removed from the 1.x branch after 1.4.0 no_more_bloom = (1, 4, 0) version_number = curator.get_version(self.client) if version_number < no_more_bloom: self.assertTrue(curator.disable_bloom_filter(self.client, 'test_index')) settings = self.client.indices.get_settings(index='test_index') self.assertEquals('false', settings['test_index']['settings']['index']['codec']['bloom']['load'])
def test_bloom_filter_will_be_disabled(self): self.create_index('test_index') # Bloom filters have been removed from the 1.x branch after 1.4.0 no_more_bloom = (1, 4, 0) version_number = curator.get_version(self.client) if version_number < no_more_bloom: self.assertTrue(curator.disable_bloom_filter(self.client, 'test_index')) settings = self.client.indices.get_settings(index='test_index') self.assertEquals('false', settings['test_index']['settings']['index']['codec']['bloom']['load'])
def test_dev_version_with_dash(self): client = Mock() client.info.return_value = {'version': {'number': '9.9.9-dev'}} version = curator.get_version(client) self.assertEqual(version, (9, 9, 9))
def test_negative(self): client = Mock() client.info.return_value = {'version': {'number': '9.9.9'}} version = curator.get_version(client) self.assertNotEqual(version, (8, 8, 8))
def test_dev_version_with_dash(self): client = Mock() client.info.return_value = {'version': {'number': '9.9.9-dev'} } version = curator.get_version(client) self.assertEqual(version, (9,9,9))
def test_negative(self): client = Mock() client.info.return_value = {'version': {'number': '9.9.9'} } version = curator.get_version(client) self.assertNotEqual(version, (8,8,8))