Exemplo n.º 1
0
 def test_symbols(self):
     actual = count_words("¿Te gusta Python?")
     expected = {'te': 1, 'gusta': 1, 'python': 1}
     self.assertEqual(actual, expected)
Exemplo n.º 2
0
 def test_apostrophe(self):
     actual = count_words("don't stop believing")
     expected = {"don't": 1, 'stop': 1, 'believing': 1}
     self.assertEqual(actual, expected)
Exemplo n.º 3
0
 def test_capitalization(self):
     actual = count_words("Oh what a day what a lovely day")
     expected = {'oh': 1, 'what': 2, 'a': 2, 'day': 2, 'lovely': 1}
     self.assertEqual(actual, expected)
Exemplo n.º 4
0
 def test_simple_sentece(self):
     actual = count_words("oh what a day what a lovely day")
     expected = {"oh": 1, "what": 2, "a": 2, "day": 2, "lovely": 1}
     self.assertEqual(actual, expected)
Exemplo n.º 5
0
 def test_simple_sentence(self):
     actual = count_words("oh what a day what a lovely day")
     expected = {'oh': 1, 'what': 2, 'a': 2, 'day': 2, 'lovely': 1}
     self.assertEqual(actual, expected)
Exemplo n.º 6
0
 def test_capitalization(self):
     actual = count_words("Oh what a day what a lovely day")
     expected = {"oh": 1, "what": 2, "a": 2, "day": 2, "lovely": 1}
     self.assertEqual(actual, expected)
Exemplo n.º 7
0
 def test_symbols(self):
     actual = count_words("¿Te gusta Python?")
     expected = {"te": 1, "gusta": 1, "python": 1}
     self.assertEqual(actual, expected)
Exemplo n.º 8
0
 def test_symbols(self):
     actual = count_words("Oh what a day, what a lovely day!")
     expected = {'oh': 1, 'what': 2, 'a': 2, 'day': 2, 'lovely': 1}
     actual = count_words("¿Te gusta Python?")
     expected = {'te': 1, 'gusta': 1, 'python': 1}
     self.assertEqual(actual, expected)
Exemplo n.º 9
0
 def test_symbols(self):
     actual = count_words("Oh what a day, what a lovely day!")
     expected = {'oh': 1, 'what': 2, 'a': 2, 'day': 2, 'lovely': 1}
     self.assertEqual(actual, expected)
Exemplo n.º 10
0
 def test_capitalization(self):
     actual = count_words("Oh what a day what a lovely day")
     expected = {'oh': 1, 'what': 2, 'a': 2, 'day': 2, 'lovely': 1}
     self.assertEqual(actual, expected)
Exemplo n.º 11
0
 def test_apostrophe(self):
     actual = count_words("don't stop believing")
     expected = {"don't": 1, 'stop': 1, 'believing': 1}
     self.assertEqual(actual, expected)
Exemplo n.º 12
0
 def test_simple_sentence(self):
     actual = count_words("oh what a day what a lovely day")
     expected = {'oh': 1, 'what': 2, 'a': 2, 'day': 2, 'lovely': 1}
     self.assertEqual(actual, expected)