diff options
author | Matthew Draper <matthew@trebex.net> | 2019-02-06 01:20:06 +1030 |
---|---|---|
committer | Matthew Draper <matthew@trebex.net> | 2019-02-06 01:20:06 +1030 |
commit | 287920ca7d06c8f51198ec750d65ba703835b257 (patch) | |
tree | fa38811f965fa873d02bc7df3317583ada076ff1 /railties/test/application/rake | |
parent | 44232b485485634d681c60868c619323f882e59f (diff) | |
download | rails-287920ca7d06c8f51198ec750d65ba703835b257.tar.gz rails-287920ca7d06c8f51198ec750d65ba703835b257.tar.bz2 rails-287920ca7d06c8f51198ec750d65ba703835b257.zip |
Respect ENV variables when finding DBs etc for the test suite
If they're not set we'll still fall back to localhost, but this makes it
possible to run the tests against a remote Postgres / Redis / whatever.
Diffstat (limited to 'railties/test/application/rake')
-rw-r--r-- | railties/test/application/rake/dbs_test.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/railties/test/application/rake/dbs_test.rb b/railties/test/application/rake/dbs_test.rb index 84ac2f057e..5879949b61 100644 --- a/railties/test/application/rake/dbs_test.rb +++ b/railties/test/application/rake/dbs_test.rb @@ -93,6 +93,8 @@ module ApplicationTests def with_bad_permissions Dir.chdir(app_path) do + skip "Can't avoid permissions as root" if Process.uid.zero? + set_database_url FileUtils.chmod("-w", "db") yield |