nutrasuite 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/nutrasuite/contexts.rb +4 -11
- data/lib/nutrasuite/version.rb +1 -1
- data/test/unit/contexts_test.rb +0 -1
- metadata +2 -2
data/lib/nutrasuite/contexts.rb
CHANGED
@@ -53,9 +53,10 @@ module Nutrasuite
|
|
53
53
|
end
|
54
54
|
else
|
55
55
|
define_method test_name do
|
56
|
-
|
57
|
-
|
58
|
-
|
56
|
+
test = MiniTest::Unit::TestCase.current
|
57
|
+
setups.each { |setup| test.instance_eval &setup }
|
58
|
+
test.instance_eval &block
|
59
|
+
teardowns.each { |teardown| test.instance_eval &teardown }
|
59
60
|
end
|
60
61
|
end
|
61
62
|
end
|
@@ -64,14 +65,6 @@ module Nutrasuite
|
|
64
65
|
puts " * Warning: #{message}"
|
65
66
|
end
|
66
67
|
|
67
|
-
# ugly, but we need to make sure that all assertions work as intended
|
68
|
-
def method_missing(name, *args, &block)
|
69
|
-
unless MiniTest::Unit::TestCase.current.nil?
|
70
|
-
MiniTest::Unit::TestCase.current.send(name, *args, &block)
|
71
|
-
else
|
72
|
-
super(name, *args, &block)
|
73
|
-
end
|
74
|
-
end
|
75
68
|
end
|
76
69
|
|
77
70
|
class Context
|
data/lib/nutrasuite/version.rb
CHANGED
data/test/unit/contexts_test.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: nutrasuite
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2012-02-
|
13
|
+
date: 2012-02-26 00:00:00.000000000 Z
|
14
14
|
dependencies: []
|
15
15
|
description: Nutrasuite is a low-calorie syntax sweetener for minitest
|
16
16
|
email:
|