diff options
author | Valery Sizov <valery@gitlab.com> | 2016-08-11 18:30:18 +0300 |
---|---|---|
committer | James Edwards-Jones <jedwardsjones@gitlab.com> | 2017-02-01 22:45:41 +0000 |
commit | ceb1ebd9590aaddc96cc059735bcf571464a8460 (patch) | |
tree | 1f7a4ade7c6c54dbddce3e9054cf97cf9a5d7f83 /spec/requests/api | |
parent | 659cceb0e8694b58a8b665de3f338245244ef114 (diff) | |
download | gitlab-ce-ceb1ebd9590aaddc96cc059735bcf571464a8460.tar.gz |
Active tense test coveragejej-backport-active-tense-specs
Ports changes from https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/642 back into CE
Diffstat (limited to 'spec/requests/api')
-rw-r--r-- | spec/requests/api/builds_spec.rb | 2 | ||||
-rw-r--r-- | spec/requests/api/groups_spec.rb | 8 | ||||
-rw-r--r-- | spec/requests/api/projects_spec.rb | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/spec/requests/api/builds_spec.rb b/spec/requests/api/builds_spec.rb index 645e36683bc..bd6e23ee769 100644 --- a/spec/requests/api/builds_spec.rb +++ b/spec/requests/api/builds_spec.rb @@ -67,7 +67,7 @@ describe API::Builds, api: true do context 'unauthorized user' do let(:api_user) { nil } - it 'should not return project builds' do + it 'does not return project builds' do expect(response).to have_http_status(401) end end diff --git a/spec/requests/api/groups_spec.rb b/spec/requests/api/groups_spec.rb index 1187d2e609d..a027c23bb88 100644 --- a/spec/requests/api/groups_spec.rb +++ b/spec/requests/api/groups_spec.rb @@ -326,7 +326,7 @@ describe API::Groups, api: true do expect(response).to have_http_status(404) end - it "should only return projects to which user has access" do + it "only returns projects to which user has access" do project3.team << [user3, :developer] get api("/groups/#{group1.id}/projects", user3) @@ -338,7 +338,7 @@ describe API::Groups, api: true do end context "when authenticated as admin" do - it "should return any existing group" do + it "returns any existing group" do get api("/groups/#{group2.id}/projects", admin) expect(response).to have_http_status(200) @@ -346,7 +346,7 @@ describe API::Groups, api: true do expect(json_response.first['name']).to eq(project2.name) end - it "should not return a non existing group" do + it "does not return a non existing group" do get api("/groups/1328/projects", admin) expect(response).to have_http_status(404) @@ -354,7 +354,7 @@ describe API::Groups, api: true do end context 'when using group path in URL' do - it 'should return any existing group' do + it 'returns any existing group' do get api("/groups/#{group1.path}/projects", admin) expect(response).to have_http_status(200) diff --git a/spec/requests/api/projects_spec.rb b/spec/requests/api/projects_spec.rb index a1db81ce18c..753dde0ca3a 100644 --- a/spec/requests/api/projects_spec.rb +++ b/spec/requests/api/projects_spec.rb @@ -459,7 +459,7 @@ describe API::Projects, api: true do before { project } before { admin } - it 'should create new project without path and return 201' do + it 'creates new project without path and return 201' do expect { post api("/projects/user/#{user.id}", admin), name: 'foo' }.to change {Project.count}.by(1) expect(response).to have_http_status(201) end |