You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
335 B

  1. from django.test import TestCase
  2. from hc.api.models import Check
  3. class CheckModelTestCase(TestCase):
  4. def test_it_strips_tags(self):
  5. check = Check()
  6. check.tags = " foo bar "
  7. self.assertEquals(check.tags_list(), ["foo", "bar"])
  8. check.tags = " "
  9. self.assertEquals(check.tags_list(), [])