rspec-matchers-power_assert_matchers 0.0.1 → 0.0.2

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
  SHA256:
3
- metadata.gz: 7848df26d206ed3701ce48dba26ababbc006a8a7526fdc2dd4115d7606262f65
4
- data.tar.gz: 6abaa1b1122699706d6371b7f6f523adbe80fa028b2a6a03a9535156050daf3c
3
+ metadata.gz: d564799c1a95c1c7ccd5702c5d788de447df3a29d4433880d7430263d75e7a10
4
+ data.tar.gz: e1c483922b43ad1eba63eff3e07166972000b2cfe4894952c59cb18ab94c4bc6
5
5
  SHA512:
6
- metadata.gz: d44db9e8b5a8900b9f0c58b29b13bfa2b5aa5bbbe9ead6ffa7757c8a18d73bd74285d4c0fa7a320f8aaebc8c7aa8f6f510d76560c50ba5e4c1711fc196270c0a
7
- data.tar.gz: bd1e868d1f523e1a74dfebfbc3ae1bf72e783b84a7c3997630e7ec45f42daf211e9889a7bc8d7a0becb91f96eb8958c5e511583f2df28f4b4a90872715b21edb
6
+ metadata.gz: 63f00e88d7f87e554dd4373d6e31153c9488e1240af240106df4bdf695d20dac337bd8972a126d6db0224009b29cb6c622e7793be3933483d8068586f8a64a88
7
+ data.tar.gz: 33e1bdba40c829f1ef0d15d4ab107480b486389be6435d3894837117cc3f93609ba4957598deefbbef6bede26545df99abc19792794b459824e16c7d01fe24c0
File without changes
data/README.md CHANGED
@@ -24,7 +24,7 @@ Add below code into your `library`'s gemspec
24
24
 
25
25
  ```ruby
26
26
  Gem::Specification.new do |gem|
27
- gem.add_development_dependency 'rspec-matchers-power_assert_matchers', '0.0.1'
27
+ gem.add_development_dependency 'rspec-matchers-power_assert_matchers', '0.0.2'
28
28
  end
29
29
  ```
30
30
 
@@ -32,7 +32,7 @@ Or add below into your `application`'s `Gemfile`
32
32
 
33
33
  ```ruby
34
34
  group :test do
35
- gem 'rspec-matchers-power_assert_matchers', '0.0.1'
35
+ gem 'rspec-matchers-power_assert_matchers', '0.0.2'
36
36
  end
37
37
  ```
38
38
 
@@ -42,7 +42,7 @@ So adding this into your `spec_helper.rb` or `rails_helper.rb`
42
42
  require 'rspec/matchers/power_assert_matchers'
43
43
  ```
44
44
 
45
- The you can use `power_assert` with a simple custom matcher in rspec.
45
+ Then you can use `power_assert` with a simple custom matcher in rspec.
46
46
 
47
47
  Use `expect` with block, and use `be_assert` matcher.
48
48
 
@@ -81,10 +81,10 @@ If you want to easy to check the behavior, this repository has example specs.
81
81
  ```console
82
82
  $ git clone git@github.com:kachick/rspec-matchers-power_assert_matchers.git
83
83
  $ cd rspec-matchers-power_assert_matchers
84
- $ cat ./examples/spec/example_spec.rb
85
- Rough examples will be shown!
86
84
  $ bundle install
87
85
  $ bundle exec rake look_at_examples
86
+ Rough examples will be shown!
87
+ $ bundle exec rake run_examples
88
88
  Some results will be shown!
89
89
  ```
90
90
 
@@ -36,18 +36,18 @@ RSpec::Matchers.define(:be_assert) do
36
36
  end
37
37
 
38
38
  result
39
- when String
40
- raise NotImplementedError
41
39
  else
40
+ dsl_context.failure_message do
41
+ # https://github.com/rspec/rspec-expectations/blob/43bf64b01f8356979ffbc373b2e81d2ab1389b29/lib/rspec/matchers/built_in/base_matcher.rb#L97-L99
42
+ # https://github.com/rspec/rspec-expectations/blob/43bf64b01f8356979ffbc373b2e81d2ab1389b29/lib/rspec/matchers/built_in/be.rb#L7-L18
43
+ "expected: truthy value\n got: #{RSpec::Support::ObjectFormatter.format(actual)}"
44
+ end
45
+
42
46
  actual
43
47
  end
44
48
  end
45
49
 
46
50
  supports_block_expectations
47
-
48
- description do
49
- 'as a be_truthy with power_assert'
50
- end
51
51
  end
52
52
 
53
53
  require_relative 'power_assert_matchers/version'
@@ -4,7 +4,7 @@
4
4
  module RSpec
5
5
  module Matchers
6
6
  module PowerAssertMatchers
7
- VERSION = '0.0.1'
7
+ VERSION = '0.0.2'
8
8
  end
9
9
  end
10
10
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rspec-matchers-power_assert_matchers
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kenichi Kamiya
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-05-19 00:00:00.000000000 Z
11
+ date: 2021-05-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec
@@ -136,20 +136,20 @@ dependencies:
136
136
  requirements:
137
137
  - - ">="
138
138
  - !ruby/object:Gem::Version
139
- version: 1.14.0
139
+ version: 1.15.0
140
140
  - - "<"
141
141
  - !ruby/object:Gem::Version
142
- version: 1.15.0
142
+ version: 1.16.0
143
143
  type: :development
144
144
  prerelease: false
145
145
  version_requirements: !ruby/object:Gem::Requirement
146
146
  requirements:
147
147
  - - ">="
148
148
  - !ruby/object:Gem::Version
149
- version: 1.14.0
149
+ version: 1.15.0
150
150
  - - "<"
151
151
  - !ruby/object:Gem::Version
152
- version: 1.15.0
152
+ version: 1.16.0
153
153
  - !ruby/object:Gem::Dependency
154
154
  name: rubocop-rake
155
155
  requirement: !ruby/object:Gem::Requirement
@@ -213,7 +213,7 @@ executables: []
213
213
  extensions: []
214
214
  extra_rdoc_files: []
215
215
  files:
216
- - LICENSE
216
+ - LICENSE.txt
217
217
  - README.md
218
218
  - lib/rspec/matchers/power_assert_matchers.rb
219
219
  - lib/rspec/matchers/power_assert_matchers/version.rb