Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use dynamic path for dummy app location in plugin's test_helper.rb #16914

Merged
merged 1 commit into from
Sep 16, 2014
Merged

Use dynamic path for dummy app location in plugin's test_helper.rb #16914

merged 1 commit into from
Sep 16, 2014

Conversation

untidy-hair
Copy link
Contributor

Currently if you specify a dummy-path options when you create a plugin, the test for the plugin doesn't work.

> rails plugin new my_plugin --dummy-path=my/dummy/app
> cd my_plugin
> bundle exec rake test
/home/yukio/experiments/rails_gem/tmp/my_plugin/test/test_helper.rb:4:in `require': cannot load such file --
 /home/yukio/experiments/rails_gem/tmp/my_plugin/test/dummy/config/environment.rb (LoadError)

This patch will fix the cases like this. Even if you specify your own dummy_path, the test will work correctly.

rafaelfranca added a commit that referenced this pull request Sep 16, 2014
Use dynamic path for dummy app location in plugin's test_helper.rb
@rafaelfranca rafaelfranca merged commit 6e4aa9d into rails:master Sep 16, 2014
rafaelfranca added a commit that referenced this pull request Sep 16, 2014
Use dynamic path for dummy app location in plugin's test_helper.rb
Conflicts:
	railties/CHANGELOG.md
@untidy-hair untidy-hair deleted the fix_plugin_dummy_path_error branch September 16, 2014 18:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants