I want to test a Rails 4 Engine by using the dummy app, but I've no idea how to do that.
My engine only has one model named Event
. At first I decomment the code in the event_test.rb
:
test "the truth" do
assert true
end
Now I tried to launch the tests from the folder of the dummy application but I don't know which command I have to use. I tried rake test
(nothing happens) and rake test test/models/<engine-name>/event_test.rb
(Error: rake aborted! Don't know how to build task...).
How can I launch the tests of my engine?
Dummy
application only mounted point for you engine
. You don't need run test from dummy
dir. Your (controllers, views, ect.) from engine
should available in dummy
app and (controllers, views, ect.) from dummy
should available in engine
.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.