b68fde6a8209915c883eaa8b32eac5f0ef3390cf,nltk/test/unit/test_util.py,TestEverygrams,test_everygrams,#TestEverygrams#,16

Before Change


                ("c",),
            ]
        )
        output = list(everygrams(self.test_data))
        // Test for expected output.
        self.assertEqual(set(output), expected_output)
        // Test that no grams are repeated.
        self.assertEqual(len(output), len(expected_output))

After Change


            ("b", "c"),
            ("c",),
        ]
        output = everygrams(iter(self.test_data))
        self.assertCountEqual(output, expected_output)

        // Test everygrams with a max length of 2.
        expected_output = [("a",), ("a", "b"), ("b",), ("b", "c"),("c",),]
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: nltk/nltk
Commit Name: b68fde6a8209915c883eaa8b32eac5f0ef3390cf
Time: 2020-07-15
Author: dmolitor@ucla.edu
File Name: nltk/test/unit/test_util.py
Class Name: TestEverygrams
Method Name: test_everygrams


Project Name: nltk/nltk
Commit Name: b68fde6a8209915c883eaa8b32eac5f0ef3390cf
Time: 2020-07-15
Author: dmolitor@ucla.edu
File Name: nltk/test/unit/test_util.py
Class Name: TestEverygrams
Method Name: test_everygrams_pad_right


Project Name: nltk/nltk
Commit Name: b68fde6a8209915c883eaa8b32eac5f0ef3390cf
Time: 2020-07-15
Author: dmolitor@ucla.edu
File Name: nltk/test/unit/test_util.py
Class Name: TestEverygrams
Method Name: test_everygrams_pad_left