Пример #1
0
 def test_owner_all(self, user_factory, brewery_factory, brew_factory):
     owner = user_factory(is_public=True)
     brewery = brewery_factory(brewer=owner)
     brew_1 = brew_factory(brewery=brewery, is_public=True)
     brew_2 = brew_factory(brewery=brewery, is_public=False)
     q = BrewUtils.brew_list_query(extra_user=owner).all()
     assert brew_1 in q
     assert brew_2 in q
Пример #2
0
 def test_public_only(self):
     ret = BrewUtils.fermenting()
     assert len(ret) == 2
Пример #3
0
 def test_display_info(self):
     ret = BrewUtils.display_info(self.brew1)
     assert 'not in particular style' in ret
Пример #4
0
 def test_brew_description(self):
     ret = BrewUtils.description(self.brew1)
     assert ret == 'unspecified style'