示例#1
0
 def test_custom_split(self):
     self.assertEqual(split_category("Skin and Hair Care"), {"Skin Care", "Hair Care"})
示例#2
0
 def test_oxford_comma(self):
     self.assertEqual(split_category("Foo, Bar, and Baz"), {"Foo", "Bar", "Baz"})
示例#3
0
 def test_simple_split(self):
     self.assertEqual(split_category("Home and Garden"), {"Home", "Garden"})
示例#4
0
 def test_empty(self):
     self.assertEqual(split_category(""), set())
示例#5
0
 def test_oxford_comma(self):
     self.assertEqual(split_category('Foo, Bar, and Baz'),
                      {'Foo', 'Bar', 'Baz'})
示例#6
0
 def test_custom_split(self):
     self.assertEqual(split_category('Skin and Hair Care'),
                      {'Skin Care', 'Hair Care'})
示例#7
0
 def test_simple_split(self):
     self.assertEqual(split_category('Home and Garden'),
                      {'Home', 'Garden'})