travis-ci
236 of 236 new or added lines in 16 files covered. (100.0%)
7219 of 11573 relevant lines covered (62.38%)
33.13 hits per line
1 |
# encoding: utf-8
|
|
2 |
|
|
3 |
require 'spec_helper'
|
7 all except jruby-9000 ✔ |
4 |
|
|
5 |
describe Github::API, 'endpoint' do |
7 all except jruby-9000 ✔ |
6 |
let(:endpoint) { "https://my-company/api/v3/" } |
7 all except jruby-9000 ✔ |
7 |
let(:options) { {:endpoint => endpoint } } |
7 all except jruby-9000 ✔ |
8 |
let(:path) { "/repos/GitHub/issues-dev/issues" } |
7 all except jruby-9000 ✔ |
9 |
|
|
10 |
subject(:api) { described_class.new(options) }
|
7 all except jruby-9000 ✔ |
11 |
|
|
12 |
before { |
7 all except jruby-9000 ✔ |
13 |
stub_get(path, 'https://my-company/api/v3').
|
× |
14 |
to_return(:body => "[]", :status => 200, :headers =>{}) |
× |
15 |
} |
|
16 |
|
|
17 |
its(:endpoint) { should == endpoint }
|
7 all except jruby-9000 ✔ |
18 |
|
|
19 |
it "doesn't truncate endpoint" do |
7 all except jruby-9000 ✔ |
20 |
expect { api.get_request(path) }.not_to raise_error() |
× |
21 |
end
|
|
22 |
end
|