i have this test
describe 'PUT #start' do
before do
put :start, abtest_id: @variation.abtest.id.to_s,
variation_id: @variation.id.to_s, format: 'json'
end
it "shoud return HTTP 200 status code" do
expect(response.response_code).to eql(200)
end
end
This is the response
Failure/Error: expect(response.response_code).to eql(200)
expected: 200
got: 405
(compared using eql?)
I can't make put request with rspec. Someone would have an alternative to test it?
Aucun commentaire:
Enregistrer un commentaire