Пример #1
0
    def test_read_from_line_handles_two_column(self):
        index = 23
        text = "this is a sentence"
        line = self.instance_to_line(text, index)

        instance = SentenceInstance.read_from_line(line)
        assert instance.text == text
        assert instance.index == index
        assert instance.label is None
Пример #2
0
 def test_read_from_line_handles_one_column(self):
     text = "this is a sentence"
     instance = SentenceInstance.read_from_line(text)
     assert instance.text == text
     assert instance.label is None
     assert instance.index is None