diff options
author | Yves Senn <yves.senn@gmail.com> | 2015-06-19 11:13:16 +0200 |
---|---|---|
committer | Yves Senn <yves.senn@gmail.com> | 2015-06-19 11:25:03 +0200 |
commit | e97b8cb15f59cff0943056772258ae16c7d9e7d8 (patch) | |
tree | d11963faaccee8c3bf226223a4d70bddc6871f28 /railties/lib | |
parent | ee066afd188edb4c30a40f736c5f9bd0e9960fb3 (diff) | |
parent | 6074d0f6d30bf3be8c6d73f336be6d21115c2f75 (diff) | |
download | rails-e97b8cb15f59cff0943056772258ae16c7d9e7d8.tar.gz rails-e97b8cb15f59cff0943056772258ae16c7d9e7d8.tar.bz2 rails-e97b8cb15f59cff0943056772258ae16c7d9e7d8.zip |
Merge pull request #20605 from dcrec1/assert_file
assert_file understands paths with special characters
Diffstat (limited to 'railties/lib')
-rw-r--r-- | railties/lib/rails/generators/testing/assertions.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/lib/rails/generators/testing/assertions.rb b/railties/lib/rails/generators/testing/assertions.rb index bd069e4bd0..17af6eddfa 100644 --- a/railties/lib/rails/generators/testing/assertions.rb +++ b/railties/lib/rails/generators/testing/assertions.rb @@ -23,7 +23,7 @@ module Rails # end # end def assert_file(relative, *contents) - absolute = File.expand_path(relative, destination_root).shellescape + absolute = File.expand_path(relative, destination_root) assert File.exist?(absolute), "Expected file #{relative.inspect} to exist, but does not" read = File.read(absolute) if block_given? || !contents.empty? |