Skip to content

Commit c740160

Browse files
committed
Merge pull request rails#25625 from voxik/fix-rails-test-git-layout
Do not depend on Rails git repository layout in ActiveSupport tests.
1 parent 9cbf3b3 commit c740160

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

activesupport/test/testing/file_fixtures_test.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ class FileFixturesTest < ActiveSupport::TestCase
66
test "#file_fixture returns Pathname to file fixture" do
77
path = file_fixture("sample.txt")
88
assert_kind_of Pathname, path
9-
assert_match %r{activesupport/test/file_fixtures/sample.txt$}, path.to_s
9+
assert_match %r{.*/test/file_fixtures/sample.txt$}, path.to_s
1010
end
1111

1212
test "raises an exception when the fixture file does not exist" do
@@ -23,6 +23,6 @@ class FileFixturesPathnameDirectoryTest < ActiveSupport::TestCase
2323
test "#file_fixture_path returns Pathname to file fixture" do
2424
path = file_fixture("sample.txt")
2525
assert_kind_of Pathname, path
26-
assert_match %r{activesupport/test/file_fixtures/sample.txt$}, path.to_s
26+
assert_match %r{.*/test/file_fixtures/sample.txt$}, path.to_s
2727
end
2828
end

0 commit comments

Comments
 (0)