diff options
Diffstat (limited to 'spec/requests/api/commits_spec.rb')
-rw-r--r-- | spec/requests/api/commits_spec.rb | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/spec/requests/api/commits_spec.rb b/spec/requests/api/commits_spec.rb index 60763eb..99cdbc3 100644 --- a/spec/requests/api/commits_spec.rb +++ b/spec/requests/api/commits_spec.rb @@ -19,10 +19,10 @@ describe API::API, 'Commits' do it "should return commits per project" do get api("/commits"), options - response.status.should eq 200 - json_response.count.should eq 1 - json_response.first["project_id"].should eq project.id - json_response.first["sha"].should eq commit.sha + expect(response.status).to eq 200 + expect(json_response.count).to eq 1 + expect(json_response.first["project_id"]).to eq project.id + expect(json_response.first["sha"]).to eq commit.sha end end @@ -51,15 +51,15 @@ describe API::API, 'Commits' do it "should create a build" do post api("/commits"), options.merge(data: data) - response.status.should eq 201 - json_response['sha'].should eq "da1560886d4f094c3e6c9ef40349f7d38b5d27d7" + expect(response.status).to eq 201 + expect(json_response['sha']).to eq "da1560886d4f094c3e6c9ef40349f7d38b5d27d7" end it "should return 400 error if no data passed" do post api("/commits"), options - response.status.should eq 400 - json_response['message'].should eq "400 (Bad request) \"data\" not given" + expect(response.status).to eq 400 + expect(json_response['message']).to eq "400 (Bad request) \"data\" not given" end end end |