From 320405b48cdd73b0b025b233b6014dc0101a91cf Mon Sep 17 00:00:00 2001 From: eee-c Date: Wed, 22 Jul 2009 00:01:06 -0400 Subject: [PATCH] Features from the legacy app that are still missing in this version --- .../recipe_alternate_preparations.feature | 27 +++++++++++++++++++ features/recipe_replacement.feature | 25 +++++++++++++++++ 2 files changed, 52 insertions(+) create mode 100644 features/recipe_alternate_preparations.feature create mode 100644 features/recipe_replacement.feature diff --git a/features/recipe_alternate_preparations.feature b/features/recipe_alternate_preparations.feature new file mode 100644 index 0000000..e0ab055 --- /dev/null +++ b/features/recipe_alternate_preparations.feature @@ -0,0 +1,27 @@ +Feature: Alternate preparations for recipes + + As a user curious about a recipe + I want to see a list of similar recipes + So that I can find a recipe that matches my tastes or ingredients on hand + + Scenario: No alternate preparation + + Given a "pancake" recipe with "buttermilk" in it + And no other recipes + When I view the recipe + Then I should see no alternate preparations + + Scenario: Alternate preparation + + Given a "Hearty Pancake" recipe with "wheat germ" in it + And a "Buttermilk Pancake" recipe with "buttermilk" in it + And a "Pancake" recipe with "chocolate chips" in it + When the three pancake recipes are alternate preparations of each other + And I visit the "Hearty Pancake" recipe + Then I should see a link to the "Buttermilk Pancake" recipe + And I should see a link to the "Pancake" recipe + And I should not see a link to the "Hearty Pancake" recipe + When I click the "Buttermilk Pancake" link + Then I should see a link to the "Hearty Pancake" recipe + And I should see a link to the "Pancake" recipe + And I should not see a link to the "Buttermilk Pancake" recipe diff --git a/features/recipe_replacement.feature b/features/recipe_replacement.feature new file mode 100644 index 0000000..b1f675e --- /dev/null +++ b/features/recipe_replacement.feature @@ -0,0 +1,25 @@ +Feature: Updating recipes in our cookbook + + As an author + I want to mark recipes as replacing old one + So that I can record improvements and retain previous attempts for reference + + Scenario: No previous or next version of a recipe + + Given a "Buttermilk Pancake" recipe with "buttermilk" in it + When I view the recipe + Then I should not see previous versions of the recipe + And I should not see updated versions of the recipe + + Scenario: A previous version of the recipe + + Given a "Buttermilk Pancake" recipe with "buttermilk" in it + And a "Buttermilk Pancake" recipe on another day with "lowfat milk" in it + When the recipe with "buttermilk" is marked as update of the previous recipe + And I visit the recipe with "buttermilk" in it + Then I should see a link to the previous recipe with "lowfat milk" in it + And I should not see updated versions of the recipe + And I visit the recipe with "lowfat milk" in it + Then I should see a link to the updated recipe with "buttermilk" in it + And I should not see previous versions of the recipe +