示例#1
0
 def test_prepare_nlu_text(self):
     expected = "India is beautiful"
     text, entities = DataUtility.extract_text_and_entities(expected)
     actual = DataUtility.prepare_nlu_text(text, entities)
     assert expected == actual
示例#2
0
 def test_prepare_nlu_text_with_entities(self):
     expected = "n=[8](n), p=1[8](n), k=2[8](n) ec=[14](ec), ph=[3](p)"
     text, entities = DataUtility.extract_text_and_entities(expected)
     actual = DataUtility.prepare_nlu_text(text, entities)
     assert expected == actual