Skip to content

Commit

Permalink
Some more context.
Browse files Browse the repository at this point in the history
  • Loading branch information
futurechimp committed Jun 9, 2011
1 parent 4bd607f commit c967225
Showing 1 changed file with 23 additions and 7 deletions.
30 changes: 23 additions & 7 deletions test/app/controllers/wires_controller_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,31 @@ class WiresControllerTest < Test::Unit::TestCase
end

context "show action" do
setup do
@wire = Wire.make
@wire.save
get "/wires/show/#{@wire.id}"
context "when the @wire has no feed_items" do
setup do
@wire = Wire.make
@wire.save
get "/wires/show/#{@wire.id}"
end

should "work" do
puts last_request.params
assert last_response.ok?
end
end

should "work" do
puts last_request.params
assert last_response.ok?
context "when the @wire has feed_items" do
setup do
@wire = Factory.make_wire
@feed_items = @wire.feed_items
get "/wires/show/#{@wire.id}"
end

should "work" do
puts last_request.params
assert last_response.ok?
end

end
end
end
Expand Down

0 comments on commit c967225

Please sign in to comment.