예제 #1
0
 def test_components_from_name_should_handle_empty_strings(self):
     expected = []
     result = bg_elasticsearch._components_from_name("")
     self.assertEqual(result, expected)
예제 #2
0
 def test_components_from_name_should_create_array_by_splitting_on_dots(self):
     expected = ["a", "b", "c", "d"]
     result = bg_elasticsearch._components_from_name("a.b.c.d")
     self.assertEqual(result, expected)
예제 #3
0
 def test_components_from_name_should_ignore_double_dots(self):
     expected = ["a", "b", "c"]
     result = bg_elasticsearch._components_from_name("a.b..c")
     self.assertEqual(result, expected)
예제 #4
0
 def test_components_from_name_should_throw_AttributeError_on_None_path(self):
     with self.assertRaises(AttributeError):
         bg_elasticsearch._components_from_name(None)
예제 #5
0
 def test_components_from_name_should_handle_empty_strings(self):
     expected = []
     result = bg_elasticsearch._components_from_name("")
     self.assertEqual(result, expected)
예제 #6
0
 def test_components_from_name_should_ignore_double_dots(self):
     expected = ["a", "b", "c"]
     result = bg_elasticsearch._components_from_name("a.b..c")
     self.assertEqual(result, expected)
예제 #7
0
 def test_components_from_name_should_create_array_by_splitting_on_dots(
         self):
     expected = ["a", "b", "c", "d"]
     result = bg_elasticsearch._components_from_name("a.b.c.d")
     self.assertEqual(result, expected)
예제 #8
0
 def test_components_from_name_should_throw_AttributeError_on_None_path(
         self):
     with self.assertRaises(AttributeError):
         bg_elasticsearch._components_from_name(None)