From 9cea623595a7347289186dda4273ee65dffea8cb Mon Sep 17 00:00:00 2001 From: Gibheer Date: Thu, 29 Nov 2012 22:22:21 +0100 Subject: don't overwrite the request --- spec/unit/controller/call_spec.rb | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'spec') diff --git a/spec/unit/controller/call_spec.rb b/spec/unit/controller/call_spec.rb index af6f719..d62a3dc 100644 --- a/spec/unit/controller/call_spec.rb +++ b/spec/unit/controller/call_spec.rb @@ -11,4 +11,12 @@ describe Zero::Controller, '.call' do it "returns an object with the first element being a status" do subject[0].should be_kind_of(Numeric) end + + it "does not modify an existing request" do + r = Zero::Request.new(env) + r.params['foo'] = 'bar' + subject + r = Zero::Request.create(env) + expect(r.params['foo']).to eq('bar') + end end -- cgit v1.2.3-70-g09d2