File tree 6 files changed +18
-2
lines changed
6 files changed +18
-2
lines changed Original file line number Diff line number Diff line change 1
1
language : ruby
2
2
rvm :
3
- - 1.9
4
3
- 2.0
5
4
- 2.1
6
5
- 2.2
Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ source 'https://rubygems.org'
2
2
3
3
group :development do
4
4
gem 'rspec' , '~> 3.1.0'
5
+ gem 'rspec-power_assert'
5
6
6
7
gem 'guard-rspec' , "~> 4.3.1"
7
8
Original file line number Diff line number Diff line change 26
26
rb-inotify (>= 0.9 )
27
27
lumberjack (1.0.9 )
28
28
method_source (0.8.2 )
29
+ power_assert (0.2.1 )
29
30
pry (0.10.1 )
30
31
coderay (~> 1.1.0 )
31
32
method_source (~> 0.8.1 )
45
46
rspec-support (~> 3.1.0 )
46
47
rspec-mocks (3.1.3 )
47
48
rspec-support (~> 3.1.0 )
49
+ rspec-power_assert (0.2.0 )
50
+ power_assert (~> 0.2.0 )
51
+ rspec (>= 2.14 )
48
52
rspec-support (3.1.2 )
49
53
slop (3.6.0 )
50
54
thor (0.19.1 )
@@ -60,3 +64,4 @@ DEPENDENCIES
60
64
libnotify
61
65
rb-notifu
62
66
rspec (~> 3.1.0 )
67
+ rspec-power_assert
Original file line number Diff line number Diff line change @@ -8,7 +8,8 @@ TDDBC for Ruby with RSpec
8
8
## 動作確認環境
9
9
* ruby 2.1.x
10
10
* ruby 2.0.x
11
- * ruby 1.9.x
11
+
12
+ ruby 1.9以前では動きません
12
13
13
14
## セットアップ
14
15
``` bash
Original file line number Diff line number Diff line change 18
18
let ( :greeting ) { "Yeah!" }
19
19
it { should eq "Yeah! TDD BootCamp!" }
20
20
end
21
+
22
+ describe "Using power assert " do
23
+ let ( :greeting ) { "Wow!" }
24
+
25
+ it do
26
+ is_asserted_by { sample . say ( greeting ) == "Wow! TDD BootCamp!" }
27
+ end
28
+ end
21
29
end
22
30
end
Original file line number Diff line number Diff line change 20
20
root_dir = File . expand_path ( File . dirname ( __FILE__ ) + "/.." )
21
21
Dir [ "#{ root_dir } /lib/**/*.rb" ] . each { |f | require f }
22
22
23
+ require "rspec-power_assert"
24
+
23
25
RSpec . configure do |config |
24
26
# rspec-expectations config goes here. You can use an alternate
25
27
# assertion/expectation library such as wrong or the stdlib/minitest
You can’t perform that action at this time.
0 commit comments