flexmock 0.8.10 → 0.8.11
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.
- data/README.rdoc +1 -1
- data/Rakefile +1 -1
- data/lib/flexmock/partial_mock.rb +3 -3
- metadata +3 -3
data/README.rdoc
CHANGED
data/Rakefile
CHANGED
@@ -16,7 +16,7 @@ class FlexMock
|
|
16
16
|
# #########################################################################
|
17
17
|
# PartialMockProxy is used to mate the mock framework to an existing
|
18
18
|
# object. The object is "enhanced" with a reference to a mock
|
19
|
-
# object (stored in <tt>@
|
19
|
+
# object (stored in <tt>@flexmock_proxy</tt>). When the
|
20
20
|
# +should_receive+ method is sent to the proxy, it overrides the
|
21
21
|
# existing object's method by creating singleton method that
|
22
22
|
# forwards to the mock. When testing is complete, PartialMockProxy
|
@@ -249,14 +249,14 @@ class FlexMock
|
|
249
249
|
eval_line = __LINE__ + 1
|
250
250
|
sclass.class_eval %{
|
251
251
|
def #{method_name}(*args, &block)
|
252
|
-
@flexmock_proxy.mock.__send__(:#{method_name}, *args, &block)
|
252
|
+
instance_variable_get('@flexmock_proxy').mock.__send__(:#{method_name}, *args, &block)
|
253
253
|
end
|
254
254
|
}, __FILE__, eval_line
|
255
255
|
else
|
256
256
|
eval_line = __LINE__ + 1
|
257
257
|
sclass.class_eval %{
|
258
258
|
def #{method_name}(*args, &block)
|
259
|
-
@flexmock_proxy.mock.#{method_name}(*args, &block)
|
259
|
+
instance_variable_get('@flexmock_proxy').mock.#{method_name}(*args, &block)
|
260
260
|
end
|
261
261
|
}, __FILE__, eval_line
|
262
262
|
make_rcov_recognize_the_above_eval_is_covered = true
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: flexmock
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 41
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 8
|
9
|
-
-
|
10
|
-
version: 0.8.
|
9
|
+
- 11
|
10
|
+
version: 0.8.11
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Jim Weirich
|