Test a RYS with RYSPEC¶
RYSPEC (gems/ryspec) provides the RSpec setup for RYS engines. The easy_engines/ directory loads it in the test group of its Gemfile. Specs of Easy plugins are described below.
Run specs from the application¶
Specs of an engine live in its spec/ directory. Use these frameworks:
- rspec-rails
- factory_bot: put factories into
spec/factoriesand shared helpers intospec/support. Files inspec/supportare loaded automatically.
Run the specs of all RYS engines, or only the RYSPEC ones, from the application root:
Easy plugins, including your modification_<name> plugin, keep their specs in test/spec/ and start them with require "easy_extensions/spec_helper":
Run specs directly from a RYS¶
Running rspec inside a RYS directory needs a dummy Rails application that RYSPEC finds in the directory given by the DUMMY_PATH environment variable or in test/dummy. The dummy application is internal to Easy8 and is not available to customers.