README.rdoc in pickle-0.1.19 vs README.rdoc in pickle-0.1.20
- old
+ new
@@ -1,11 +1,11 @@
= pickle
Pickle gives you cucumber steps that create your models easily from factory-girl or
machinist factories/blueprints. You can also just use ActiveRecord but it's not as cool.
-References to the models are stored, not necessarily for the purpose of checking the db
+References to the models are stored in the current world, not necessarily for the purpose of checking the db
(although you could use it for that), but for enabling easy reference to urls, and for
building complex givens which require a bunch of models collaborating
== CI
@@ -22,11 +22,18 @@
script/plugin install git://github.com/ianwhite/pickle.git
# or, plugin as submodule
git submodule add git://github.com/ianwhite/pickle.git vendor/plugins/pickle
-
+== Contributors
+
+The following people have Pickle better:
+
+* {Nick Rutherford}[http://github.com/nruth]
+* Tobi Knaup
+* {Michael MacDonald}[http://github.com/schlick]
+
== Get Started
(you'd better install cucumber)
script/generate pickle [paths] [email]
@@ -105,15 +112,15 @@
Given a person: "fred" exists
And a person: "ethel" exists
And a fatherhood exists with parent: user "fred", child: user "ethel"
-"Given <b>n</b> models exist", e.g.
+"Given <b>n models</b> exist", e.g.
Given 10 users exist
-"Given <b>n</b> <b>models</b> exist with <b>fields</b>", examples:
+"Given <b>n models</b> exist with <b>fields</b>", examples:
Given 10 users exist with activated: false
==== Then steps
@@ -131,15 +138,15 @@
Then a person should exist with child: person "ethel"
Then a user should exist with activated: false
Then a user should exist with activated: true, email: "fred@gmail.com"
-"Then <b>n</b> <b>models</b> should exist", e.g.
+"Then <b>n models</b> should exist", e.g.
Then 10 events should exist
-"Then <b>n</b> <b>models</b> should exist with <b>fields</b>", e.g.
+"Then <b>n models</b> should exist with <b>fields</b>", e.g.
Then 2 people should exist with father: person "fred"
===== Asserting associations
@@ -157,11 +164,11 @@
"Then <b>a model</b> should [be|have] [a|an] <b>predicate</b>", e.g.
Then the user should have a status # => user.status?.should == true
Then the car: "batmobile" should be fast # => car.fast?.should == true
-"Then <b>a model</b> should [be|have] [a|an] <b>predicate</b>", e.g.
+"Then <b>a model</b> should not [be|have] [a|an] <b>predicate</b>", e.g.
Then person: "fred" should not be childless # => fred.childless?.should == false
=== Regexps for use in your own steps
@@ -184,10 +191,12 @@
# ...
end
end
Then /^#{capture_model} should be one of #{capture_model}'s posts$/ do |post, forum|
- model(forum).posts.should include(post)
+ post = model!(post)
+ forum = model!(forum)
+ forum.posts.should include(post)
end
*capture_fields*
This is useful for setting attributes, and knows about pickle model names so that you
\ No newline at end of file