Ejemplo n.º 1
0
    def test_add_final_sentence_language_double_quotes(self):
        """Test add_final_sentence_language() with double quotes at end."""
        input = 'Current "sentence"'
        expected = 'Current "sentence."'

        rl = ResultsLanguage(standard_data)
        actual = rl.add_final_sentence_language(input)

        self.assertEqual(actual, expected)
Ejemplo n.º 2
0
    def test_add_final_sentence_language_end_on_date(self):
        """Test add_final_sentence_language() ending on a date."""
        input = "Current sentence Dec. 31, 2016,"
        expected = "Current sentence Dec. 31, 2016."

        rl = ResultsLanguage(standard_data)
        actual = rl.add_final_sentence_language(input)

        self.assertEqual(actual, expected)
Ejemplo n.º 3
0
    def test_add_final_sentence_language_single_quotes(self):
        """Test add_final_sentence_language() with single quotes at end."""
        input = "Current 'sentence'"
        expected = "Current 'sentence.'"

        rl = ResultsLanguage(standard_data)
        actual = rl.add_final_sentence_language(input)

        self.assertEqual(actual, expected)
Ejemplo n.º 4
0
    def test_add_final_sentence_language_no_quotes(self):
        """Test add_final_sentence_language() without quotes."""
        input = "Current sentence"
        expected = "Current sentence."

        rl = ResultsLanguage(standard_data)
        actual = rl.add_final_sentence_language(input)

        self.assertEqual(actual, expected)
Ejemplo n.º 5
0
    def test_add_final_sentence_language_double_quotes(self):
        """Test add_final_sentence_language() with double quotes at end."""
        input = 'Current "sentence"'
        expected = 'Current "sentence."'

        rl = ResultsLanguage(standard_data)
        actual = rl.add_final_sentence_language(input)

        self.assertEqual(actual, expected)
Ejemplo n.º 6
0
    def test_add_final_sentence_language_single_quotes(self):
        """Test add_final_sentence_language() with single quotes at end."""
        input = "Current 'sentence'"
        expected = "Current 'sentence.'"

        rl = ResultsLanguage(standard_data)
        actual = rl.add_final_sentence_language(input)

        self.assertEqual(actual, expected)
Ejemplo n.º 7
0
    def test_add_final_sentence_language_end_on_date(self):
        """Test add_final_sentence_language() ending on a date."""
        input = "Current sentence Dec. 31, 2016,"
        expected = "Current sentence Dec. 31, 2016."

        rl = ResultsLanguage(standard_data)
        actual = rl.add_final_sentence_language(input)

        self.assertEqual(actual, expected)
Ejemplo n.º 8
0
    def test_add_final_sentence_language_no_quotes(self):
        """Test add_final_sentence_language() without quotes."""
        input = "Current sentence"
        expected = "Current sentence."

        rl = ResultsLanguage(standard_data)
        actual = rl.add_final_sentence_language(input)

        self.assertEqual(actual, expected)