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 do |
7 all except jruby-9000 ✔ |
6 |
let(:method) { 'create_repos'} |
7 all except jruby-9000 ✔ |
7 |
let(:alt_method) { 'repos.create'} |
7 all except jruby-9000 ✔ |
8 |
|
|
9 |
it { described_class.constants.should include :DEPRECATION_PREFIX }
|
7 all except jruby-9000 ✔ |
10 |
|
|
11 |
context '.deprecate' do |
7 all except jruby-9000 ✔ |
12 |
before do
|
7 all except jruby-9000 ✔ |
13 |
Github.deprecation_tracker = []
|
× |
14 |
end
|
|
15 |
|
|
16 |
it 'tracks messages' do |
7 all except jruby-9000 ✔ |
17 |
Github.should_receive(:warn).once() |
× |
18 |
Github.deprecate(method)
|
× |
19 |
Github.deprecate(method)
|
× |
20 |
end
|
|
21 |
|
|
22 |
it 'prints the message through Kernel' do |
7 all except jruby-9000 ✔ |
23 |
Github.should_receive(:warn).once() |
× |
24 |
Github.deprecate method
|
× |
25 |
end
|
|
26 |
end
|
|
27 |
|
|
28 |
it 'prints the message through Kernel' do |
7 all except jruby-9000 ✔ |
29 |
Github.should_receive(:warn) |
× |
30 |
Github.warn_deprecation method
|
× |
31 |
end
|
|
32 |
end # Github |