mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-18 04:39:14 +00:00
Merge pull request #13327 from cyrillefr/FixRSpecRailsHttpStatus
Fixes RSpec Rails HttpStatus offenses
This commit is contained in:
@@ -52,7 +52,7 @@ RSpec.describe Spree::Admin::ProductsController, type: :controller do
|
||||
}
|
||||
]
|
||||
|
||||
expect(response).to have_http_status(302)
|
||||
expect(response).to have_http_status(:found)
|
||||
end
|
||||
|
||||
it 'does not redirect to bulk_products' do
|
||||
@@ -169,7 +169,7 @@ RSpec.describe Spree::Admin::ProductsController, type: :controller do
|
||||
|
||||
spree_put :create, product: product_attrs_with_image
|
||||
|
||||
expect(response).to have_http_status 200
|
||||
expect(response).to have_http_status :ok
|
||||
end
|
||||
end
|
||||
|
||||
@@ -179,7 +179,7 @@ RSpec.describe Spree::Admin::ProductsController, type: :controller do
|
||||
{ supplier_id: nil, primary_taxon_id: nil }
|
||||
),
|
||||
button: 'create'
|
||||
expect(response).to have_http_status 200
|
||||
expect(response).to have_http_status :ok
|
||||
expect(response).to render_template('spree/admin/products/new')
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user