Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

message_test.py 1.6KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. import million.analyze.message_evaluation as msg_val
  2. from test.TestCase import TestCase
  3. class MessageTest(TestCase):
  4. def test_single_digit(self, overrides=None, exclude=None):
  5. message = self._message_with_text("1")
  6. assert 1 == msg_val.get(message)
  7. def test_message_nominal(self, overrides=None, exclude=None):
  8. message = self._message_with_text("1234")
  9. assert 1234 == msg_val.get(message)
  10. def test_message_with_text(self, overrides=None, exclude=None):
  11. message = self._message_with_text("... 😏😏 269")
  12. assert 269 == msg_val.get(message)
  13. def test_message_with_text_2(self, overrides=None, exclude=None):
  14. message = self._message_with_text("331 allez la")
  15. assert 331 == msg_val.get(message)
  16. def test_message_with_text_3(self, overrides=None, exclude=None):
  17. message = self._message_with_text("Ok 2160")
  18. assert 2160 == msg_val.get(message)
  19. def test_message_value_cut(self, overrides=None, exclude=None):
  20. message = self._message_with_text("66...😏😏😏9")
  21. assert 669 == msg_val.get(message)
  22. def test_message_value_cut_2(self, overrides=None, exclude=None):
  23. message = self._message_with_text("82heyyyyyy69")
  24. assert 8269 == msg_val.get(message)
  25. def test_message_value_cut_2(self, overrides=None, exclude=None):
  26. message = self._message_with_text("9339 9339 9339 9339")
  27. assert 9339 == msg_val.get(message)
  28. def test_message_in_middle(self, overrides=None, exclude=None):
  29. message = self._message_with_text("A peine 5565 ouais...")
  30. assert 5565 == msg_val.get(message)