rspec-match_ruby 0.1.1 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +4 -1
- data/lib/rspec/match_ruby.rb +2 -2
- data/rspec-match_ruby.gemspec +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9314614cb0cdeb5add657806c70ab86508fbef9e
|
|
4
|
+
data.tar.gz: 0c5ceff59d1131e8c4eb1131d735a9248ae29fc5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: a7ac6d5c51d7b309e396753373f457bab4b43404e3bbafb6129598dd1141ea343349a87966e6f2d88cc2cf6f61af6465b646f2e1df1773fb8f8ffcd93555af27
|
|
7
|
+
data.tar.gz: 2cc69a89909ca988dbc610339767c18179f404d205451d85153e5ca95caa5ea6aad23ade066e80bb28d8057e6beed8c146fc3a86b1f1030cc49fe12cc69798e1
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# rspec-
|
|
1
|
+
# rspec-match_ruby
|
|
2
2
|
|
|
3
3
|
It is Ruby code matcher.
|
|
4
4
|
|
|
@@ -50,7 +50,9 @@ RSpec.describe do
|
|
|
50
50
|
#=> Failure/Error: expect(code1).to match_ruby code2
|
|
51
51
|
# expected: "create_table :products, force: :cascade, id: true do |t|\nt.string :name, limit: 4, null: true\nt.text :description\n# Comment\nt.timestamps\nend"
|
|
52
52
|
# got: "create_table :products, id: true, force: :cascade do |t|\nt.string :name, null: false, limit: 4\nt.text :description\nt.timestamps\nend"
|
|
53
|
+
#
|
|
53
54
|
# Diff:
|
|
55
|
+
#
|
|
54
56
|
# @@ -1,7 +1,6 @@
|
|
55
57
|
# -create_table :products, force: :cascade, id: true do |t|
|
|
56
58
|
# -t.string :name, limit: 4, null: true
|
|
@@ -60,6 +62,7 @@ RSpec.describe do
|
|
|
60
62
|
# -# Comment
|
|
61
63
|
# t.timestamps
|
|
62
64
|
# end
|
|
65
|
+
#
|
|
63
66
|
# @@ -14,7 +14,7 @@
|
|
64
67
|
# [:sym, :name],
|
|
65
68
|
# [:hash,
|
data/lib/rspec/match_ruby.rb
CHANGED
|
@@ -9,8 +9,8 @@ RSpec::Matchers.define :match_ruby do |expected|
|
|
|
9
9
|
end
|
|
10
10
|
|
|
11
11
|
match do |actual|
|
|
12
|
-
unless
|
|
13
|
-
raise TypeError, "wrong actual type #{
|
|
12
|
+
unless actual.is_a?(String)
|
|
13
|
+
raise TypeError, "wrong actual type #{actual.class} (expected String)"
|
|
14
14
|
end
|
|
15
15
|
|
|
16
16
|
RSpecMatchRuby.match(expected, actual)
|
data/rspec-match_ruby.gemspec
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: rspec-match_ruby
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- winebarrel
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2017-12-
|
|
11
|
+
date: 2017-12-15 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rspec
|