Skip to content

Instantly share code, notes, and snippets.

@jeremy
Created October 12, 2016 06:03
Show Gist options
  • Save jeremy/89ef4d0b569a85e6d493aeafdf85b261 to your computer and use it in GitHub Desktop.
Save jeremy/89ef4d0b569a85e6d493aeafdf85b261 to your computer and use it in GitHub Desktop.
Sprockets 4 asset loader for Percy.io
class PercyRails5Loader < Percy::Capybara::Loaders::SprocketsLoader
def initialize(options = {})
super
@sprockets_environment = Rails.application.assets
@sprockets_options = Rails.application.config.assets
end
def _asset_logical_paths
Rails.application.precompiled_assets
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment