Skip to content

Instantly share code, notes, and snippets.

@mathewtrivett
Created January 11, 2021 08:16
Show Gist options
  • Save mathewtrivett/bd23dad719ea6a9b49e9b72f25a88a22 to your computer and use it in GitHub Desktop.
Save mathewtrivett/bd23dad719ea6a9b49e9b72f25a88a22 to your computer and use it in GitHub Desktop.
Testing Print CSS - spec/spec_helper.rb
RSpec.configure do |config|
.... # The rest of your Rspec configuration
# Here we are going to precompile our assets any time
# we encounter a feature spec group
config.before(:all) do |_config|
case self.class.metadata[:type]
when :feature
`bundle exec rake assets:precompile`
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment