Commit 3b560d04 authored by Robert Schilling's avatar Robert Schilling

POST should be PUT in the API labels specs

parent 5dac2937
...@@ -306,16 +306,16 @@ describe API::Labels do ...@@ -306,16 +306,16 @@ describe API::Labels do
end end
it 'returns 400 for too long color code' do it 'returns 400 for too long color code' do
post api("/projects/#{project.id}/labels", user), put api("/projects/#{project.id}/labels", user),
name: 'Foo', name: 'label1',
color: '#FFAAFFFF' color: '#FFAAFFFF'
expect(response).to have_gitlab_http_status(400) expect(response).to have_gitlab_http_status(400)
expect(json_response['message']['color']).to eq(['must be a valid color code']) expect(json_response['message']['color']).to eq(['must be a valid color code'])
end end
it 'returns 400 for invalid priority' do it 'returns 400 for invalid priority' do
post api("/projects/#{project.id}/labels", user), put api("/projects/#{project.id}/labels", user),
name: 'Foo', name: 'label1',
priority: 'foo' priority: 'foo'
expect(response).to have_gitlab_http_status(400) expect(response).to have_gitlab_http_status(400)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment