Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- describe String, "param parsing" do
- before(:each) do
- @result = { "foo" => "bar", "this" => "that" }
- end
- it "scans then injects" do
- "foo=bar&this=that&".scan_then_inject.should == @result
- end
- it "scans groups then injects" do
- "foo=bar&this=that&".scan_groups_then_inject.should == @result
- end
- it "scans splat hashes" do
- "foo=bar&this=that&".scan_then_splat_hash.should == @result
- end
- it "splits then splat hashes" do
- "foo=bar&this=that&".split_then_splat_hash.should == @result
- end
- end
Add Comment
Please, Sign In to add comment