fixture_background 0.9.0.1 → 0.9.0.2

Sign up to get free protection for your applications and to get access to all the features.
data/README.rdoc CHANGED
@@ -11,8 +11,6 @@ thies@tmp8.de 20110207
11
11
 
12
12
  in test_helper.rb:
13
13
 
14
- require 'fixture_background'
15
-
16
14
  class ActiveSupport::TestCase
17
15
  include ::FixtureBackground::ActiveSupport::TestCase
18
16
  end
@@ -17,11 +17,10 @@ module FixtureBackground
17
17
 
18
18
  def background_valid?
19
19
  (IO.read("#{fixture_path}/.version") rescue nil) == background_signature
20
- false
21
20
  end
22
21
 
23
22
  def background_signature
24
- stack = caller.reject { |line| line =~ Regexp.new(__FILE__) }
23
+ stack = caller.reject { |line| line =~ Regexp.new(File.dirname(__FILE__)) }
25
24
  test_file_path = File.expand_path(stack.first.match(/^(.+\.rb):/)[1])
26
25
  block_syntax = ''
27
26
  IO.read(test_file_path).scan(/(?:\A|\n)([ \t]*)background\s(?:do|{)(.*?)\n\1end/m) do |match|
@@ -1,4 +1,4 @@
1
1
  module FixtureBackground
2
- VERSION = "0.9.0.1"
2
+ VERSION = "0.9.0.2"
3
3
  end
4
4
 
metadata CHANGED
@@ -6,8 +6,8 @@ version: !ruby/object:Gem::Version
6
6
  - 0
7
7
  - 9
8
8
  - 0
9
- - 1
10
- version: 0.9.0.1
9
+ - 2
10
+ version: 0.9.0.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - Thies C. Arntzen