Last active
January 28, 2020 20:53
-
-
Save cfitz/016ea06748fa40f14125ebe80d16fd7e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# config/initializers/e2e_test.rb | |
# For some situations, we need to have the e2e | |
# test to behave different in order to speed up the tests. | |
# rubocop:disable Style/ClassVars | |
if ENV.fetch('E2E_TEST', 'false') == 'true' | |
require_relative '../../lib/util/az_list_controller_util' | |
module Util | |
class AzListControllerUtil | |
class << self | |
@@solr_json = JSON.parse( | |
IO.read( | |
Rails.root.join('test/fixtures/files/e2e_all_products.json') | |
) | |
).collect(&:with_indifferent_access) | |
def solr_results_in_alphabetical_order | |
Rails.logger.info('WARNING: USING E2E PATCH OF Util::AzListControllerUtil ') | |
@@solr_json | |
end | |
end | |
end | |
end | |
end | |
# rubocop:enable Style/ClassVars |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment