示例#1
0
文件: base.py 项目: agripo/website
 def create_category(self, name="Category name"):
     cat = ProductCategory(name=name)
     cat.save()
     return cat
示例#2
0
 def test_category_only_needs_a_name(self):
     cat = ProductCategory(name="Cat 1")
     cat.save()  # Should not raise