Commit b1df8c4e authored by Douwe Maan's avatar Douwe Maan

Merge branch 'fix-label-api-spec' into 'master'

Make label API spec independent of order

See merge request !7013
parents ded1e2f6 d9d0b81b
...@@ -22,8 +22,7 @@ describe API::API, api: true do ...@@ -22,8 +22,7 @@ describe API::API, api: true do
expect(response).to have_http_status(200) expect(response).to have_http_status(200)
expect(json_response).to be_an Array expect(json_response).to be_an Array
expect(json_response.size).to eq(2) expect(json_response.size).to eq(2)
expect(json_response.first['name']).to eq(group_label.name) expect(json_response.map { |l| l['name'] }).to match_array([group_label.name, label1.name])
expect(json_response.second['name']).to eq(label1.name)
end end
end end
......
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