diff options
author | Robert Speicher <rspeicher@gmail.com> | 2017-02-10 04:21:31 +0300 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2017-02-10 04:23:41 +0300 |
commit | 0d9cce410dd146e512dc84fdb39bff13929a1362 (patch) | |
tree | 213a54c9f8b365d5e673c9e89cfb29f63893e234 /spec/requests/api/groups_spec.rb | |
parent | e355d8fe287002df0948033a19db9caaf8174555 (diff) |
Remove a transient failure from spec/requests/api/groups_spec.rb
Diffstat (limited to 'spec/requests/api/groups_spec.rb')
-rw-r--r-- | spec/requests/api/groups_spec.rb | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/spec/requests/api/groups_spec.rb b/spec/requests/api/groups_spec.rb index 15592f1f702..f78bde6f53a 100644 --- a/spec/requests/api/groups_spec.rb +++ b/spec/requests/api/groups_spec.rb @@ -35,7 +35,8 @@ describe API::Groups, api: true do expect(response).to have_http_status(200) expect(json_response).to be_an Array expect(json_response.length).to eq(1) - expect(json_response.first['name']).to eq(group1.name) + expect(json_response) + .to satisfy_one { |group| group['name'] == group1.name } end it "does not include statistics" do @@ -70,7 +71,7 @@ describe API::Groups, api: true do repository_size: 123, lfs_objects_size: 234, build_artifacts_size: 345, - } + }.stringify_keys project1.statistics.update!(attributes) @@ -78,7 +79,8 @@ describe API::Groups, api: true do expect(response).to have_http_status(200) expect(json_response).to be_an Array - expect(json_response.first['statistics']).to eq attributes.stringify_keys + expect(json_response) + .to satisfy_one { |group| group['statistics'] == attributes } end end |