minitest-matchers 1.1.0.rc3 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/History.txt +7 -0
  2. data/README.txt +3 -0
  3. data/lib/minitest/matchers.rb +6 -4
  4. metadata +17 -12
data/History.txt CHANGED
@@ -1,3 +1,10 @@
1
+ === 1.1.0 / 2011-11-18
2
+
3
+ * 1 major enhancement
4
+
5
+ * Refactored to only support instance level `it` and dropped class level
6
+ `must` and `wont`. It's better that way.
7
+
1
8
  === 1.0.3 / 2011-09-05
2
9
 
3
10
  * 1 minor enhancement
data/README.txt CHANGED
@@ -11,6 +11,9 @@ More information about matchers can be found here:
11
11
  * https://www.relishapp.com/rspec/rspec-expectations
12
12
  * http://railscasts.com/episodes/157-rspec-matchers-macros
13
13
 
14
+ For use with Rails check out (ValidAttribute + Capybara):
15
+ * https://github.com/wojtekmach/minitest-rails-example
16
+
14
17
  == FEATURES/PROBLEMS:
15
18
 
16
19
  * Enables you to use existing matcher classes from projects like
@@ -1,7 +1,7 @@
1
1
  require "minitest/spec"
2
2
 
3
3
  module MiniTest::Matchers
4
- VERSION = "1.1.0.rc3" # :nodoc:
4
+ VERSION = "1.1.0" # :nodoc:
5
5
  end
6
6
 
7
7
  module MiniTest
@@ -39,8 +39,6 @@ module MiniTest
39
39
  # end
40
40
 
41
41
  def assert_wont matcher, subject, msg = nil
42
- result = matcher.matches? subject
43
-
44
42
  msg = message(msg) do
45
43
  if matcher.respond_to? :negative_failure_message
46
44
  matcher.negative_failure_message
@@ -49,7 +47,11 @@ module MiniTest
49
47
  end
50
48
  end
51
49
 
52
- refute result, msg
50
+ if matcher.respond_to? :does_not_match?
51
+ assert matcher.does_not_match?(subject), msg
52
+ else
53
+ refute matcher.matches?(subject), msg
54
+ end
53
55
  end
54
56
  end
55
57
 
metadata CHANGED
@@ -1,8 +1,8 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: minitest-matchers
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0.rc3
5
- prerelease: 6
4
+ version: 1.1.0
5
+ prerelease:
6
6
  platform: ruby
7
7
  authors:
8
8
  - Ryan Davis
@@ -10,11 +10,11 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2011-11-12 00:00:00.000000000 Z
13
+ date: 2011-11-18 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: minitest
17
- requirement: &70336486719080 !ruby/object:Gem::Requirement
17
+ requirement: &70111943842540 !ruby/object:Gem::Requirement
18
18
  none: false
19
19
  requirements:
20
20
  - - ! '>='
@@ -22,10 +22,10 @@ dependencies:
22
22
  version: 2.5.0
23
23
  type: :runtime
24
24
  prerelease: false
25
- version_requirements: *70336486719080
25
+ version_requirements: *70111943842540
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: minitest
28
- requirement: &70336486718660 !ruby/object:Gem::Requirement
28
+ requirement: &70111943841900 !ruby/object:Gem::Requirement
29
29
  none: false
30
30
  requirements:
31
31
  - - ~>
@@ -33,10 +33,10 @@ dependencies:
33
33
  version: '2.8'
34
34
  type: :development
35
35
  prerelease: false
36
- version_requirements: *70336486718660
36
+ version_requirements: *70111943841900
37
37
  - !ruby/object:Gem::Dependency
38
38
  name: hoe
39
- requirement: &70336486718240 !ruby/object:Gem::Requirement
39
+ requirement: &70111943841260 !ruby/object:Gem::Requirement
40
40
  none: false
41
41
  requirements:
42
42
  - - ~>
@@ -44,7 +44,7 @@ dependencies:
44
44
  version: '2.12'
45
45
  type: :development
46
46
  prerelease: false
47
- version_requirements: *70336486718240
47
+ version_requirements: *70111943841260
48
48
  description: ! 'minitest-matchers adds support for RSpec/Shoulda-style matchers to
49
49
 
50
50
  minitest/unit and minitest/spec.
@@ -54,7 +54,12 @@ description: ! 'minitest-matchers adds support for RSpec/Shoulda-style matchers
54
54
 
55
55
  * https://www.relishapp.com/rspec/rspec-expectations
56
56
 
57
- * http://railscasts.com/episodes/157-rspec-matchers-macros'
57
+ * http://railscasts.com/episodes/157-rspec-matchers-macros
58
+
59
+
60
+ For use with Rails check out (ValidAttribute + Capybara):
61
+
62
+ * https://github.com/wojtekmach/minitest-rails-example'
58
63
  email:
59
64
  - ryand-ruby@zenspider.com
60
65
  - wojtek@wojtekmach.pl
@@ -90,9 +95,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
90
95
  required_rubygems_version: !ruby/object:Gem::Requirement
91
96
  none: false
92
97
  requirements:
93
- - - ! '>'
98
+ - - ! '>='
94
99
  - !ruby/object:Gem::Version
95
- version: 1.3.1
100
+ version: '0'
96
101
  requirements: []
97
102
  rubyforge_project: minitest-matchers
98
103
  rubygems_version: 1.8.10