Fixtures
Rails fixtures work well for stable baseline data in E2E browser tests.
Install the current 1.x gem as cypress-on-rails:
group :test, :development do
gem 'cypress-on-rails', '~> 1.0'
end
Use fixtures when many tests need the same known records. Use scenarios or app commands when a test needs custom state for one flow.
Typical pattern:
- Load baseline fixture data in Rails.
- Reset state between browser tests.
- Use app commands for test-specific data.
Related docs: