Permalink
Browse files

Added a functionnal test for the line_item creation

  • Loading branch information...
1 parent 2f25781 commit e2a6b78bec2bd576f57050be5cd06cde3fea8ec7 @jbdoumenjou committed Aug 29, 2011
Showing with 2 additions and 2 deletions.
  1. +2 −2 test/functional/line_items_controller_test.rb
@@ -18,10 +18,10 @@ class LineItemsControllerTest < ActionController::TestCase
test "should create line_item" do
assert_difference('LineItem.count') do
- post :create, :line_item => @line_item.attributes
+ post :create, :product_id => products(:ruby).id
end
- assert_redirected_to line_item_path(assigns(:line_item))
+ assert_redirected_to cart_path(assigns(:line_item).cart)
end
test "should show line_item" do

0 comments on commit e2a6b78

Please sign in to comment.