aboutsummaryrefslogtreecommitdiffstats
path: root/spec
diff options
context:
space:
mode:
Diffstat (limited to 'spec')
-rw-r--r--spec/controllers/track_controller_spec.rb4
-rw-r--r--spec/fixtures/track_things.yml13
2 files changed, 14 insertions, 3 deletions
diff --git a/spec/controllers/track_controller_spec.rb b/spec/controllers/track_controller_spec.rb
index bf3c952c7..39542cb63 100644
--- a/spec/controllers/track_controller_spec.rb
+++ b/spec/controllers/track_controller_spec.rb
@@ -24,12 +24,12 @@ describe TrackController, "when making a new track on a request" do
end
it "should make track and redirect if you are logged in " do
- TrackThing.count.should == 1
+ TrackThing.count.should == 2
session[:user_id] = users(:bob_smith_user).id
post :track_request, :url_title => info_requests(:fancy_dog_request).url_title,
:track_thing => { :track_medium => "email_daily" },
:submitted_track => 1
- TrackThing.count.should == 2
+ TrackThing.count.should == 3
response.should redirect_to(:controller => 'request', :action => 'show', :url_title => info_requests(:fancy_dog_request).url_title)
end
diff --git a/spec/fixtures/track_things.yml b/spec/fixtures/track_things.yml
index 863db3c50..1c4b323fd 100644
--- a/spec/fixtures/track_things.yml
+++ b/spec/fixtures/track_things.yml
@@ -1,4 +1,4 @@
-track_fancy_dog:
+track_fancy_dog_request:
id: "10"
track_query: request:why_do_you_have_such_a_fancy_dog
track_type: request_updates
@@ -9,3 +9,14 @@ track_fancy_dog:
public_body_id:
created_at: 2007-10-01 00:00:00
updated_at: 2007-01-01 00:00:00
+track_fancy_dog_search:
+ id: "11"
+ track_query: fancy dog
+ track_type: search_query
+ track_medium: email_daily
+ tracking_user_id: "2"
+ info_request_id:
+ tracked_user_id:
+ public_body_id:
+ created_at: 2007-10-01 00:00:00
+ updated_at: 2007-01-01 00:00:00