aruba-rspec 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fb22f810601d4864d1c83ff1d8230855e681ff22
|
4
|
+
data.tar.gz: 985b41b67f6b1c57f29e515b1a8c162234ad884a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0a9b45bb6ef47f4b6c95f81834c00890da30b529c4ce90890d243b1929a8040f31b2c0158ef41b41589c470fdd94e6d444c4440ee12bdccaae99a7117d9c83a1
|
7
|
+
data.tar.gz: f399628ee25684852e042ecaf5fe2a302fbe2e963f95fda1a0eb8ac492e8d61f48c75c769b621886f6370aa906e103e83c72259c41eed8869fcb6765bdb7c42b
|
@@ -2,7 +2,8 @@ RSpec::Matchers.define :have_exit_status do |status|
|
|
2
2
|
match do |ruby|
|
3
3
|
raise ArgumentError, "expected should be a Proc" unless ruby.respond_to?(:call)
|
4
4
|
ruby.call
|
5
|
-
$?.exitstatus
|
5
|
+
@ruby_exit_status = $?.exitstatus
|
6
|
+
@ruby_exit_status == status
|
6
7
|
end
|
7
8
|
|
8
9
|
def supports_block_expectations?
|
@@ -10,7 +11,7 @@ RSpec::Matchers.define :have_exit_status do |status|
|
|
10
11
|
end
|
11
12
|
|
12
13
|
failure_message do |ruby|
|
13
|
-
"expected that code would exit #{status}"
|
14
|
+
"expected that code would exit #{status}, instead exited #{@ruby_exit_status}"
|
14
15
|
end
|
15
16
|
|
16
17
|
failure_message_when_negated do |ruby|
|
data/lib/aruba/rspec/version.rb
CHANGED
@@ -24,7 +24,7 @@ describe 'have_exit_status matcher' do
|
|
24
24
|
double_cmd('thing', exit: 101)
|
25
25
|
expect {
|
26
26
|
expect { `thing` }.to have_exit_status(100)
|
27
|
-
}.to raise_error(RSpec::Expectations::ExpectationNotMetError, /expected that code would exit 100/)
|
27
|
+
}.to raise_error(RSpec::Expectations::ExpectationNotMetError, /expected that code would exit 100, instead exited 101/)
|
28
28
|
end
|
29
29
|
end
|
30
30
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aruba-rspec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Eric Saxby
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-06-
|
11
|
+
date: 2014-06-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|