Skip to content

Instantly share code, notes, and snippets.

@mccutchen
Created September 24, 2010 21:01
Show Gist options
  • Save mccutchen/596044 to your computer and use it in GitHub Desktop.
Save mccutchen/596044 to your computer and use it in GitHub Desktop.
Worst comment ever?
def test_recipe_ref_creation(self):
# There are 7 recipes in the fixtures plus 3 cookbooks containing 3, 2
# and 1 recipes, respectively, which adds up to 15 initial
# RecipeReferences (because two those cookbook recipes belong to
# another user'saccount, which leads to one RecipeReference under that
# cookbook and one under the AccountRef for that account, plus one
# more reference for a recipe duplicated in two cookbooks).
refs = cookbook_models.RecipeReference.all().fetch(1000)
self.failUnlessEqual(len(refs), 15)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment