예제 #1
0
파일: base.py 프로젝트: agripo/website
 def create_category(self, name="Category name"):
     cat = ProductCategory(name=name)
     cat.save()
     return cat
예제 #2
0
파일: test_shop.py 프로젝트: agripo/website
 def test_category_only_needs_a_name(self):
     cat = ProductCategory(name="Cat 1")
     cat.save()  # Should not raise