Skip to content

Commit

Permalink
Merge pull request #4209 from RyanofWoods/fix/frontend-scss-font-url-…
Browse files Browse the repository at this point in the history
…import

Use SSL on fonts.googleapis.com scss import
  • Loading branch information
waiting-for-dev authored Nov 25, 2021
2 parents 5d8d110 + abd374e commit 76e2875
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
5 changes: 2 additions & 3 deletions backend/spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
require 'spree/testing_support/precompiled_assets'
require 'spree/testing_support/translations'
require 'spree/testing_support/job_helpers'
require 'spree/testing_support/blacklist_urls'

require 'capybara-screenshot/rspec'
Capybara.save_path = ENV['CIRCLE_ARTIFACTS'] if ENV['CIRCLE_ARTIFACTS']
Expand Down Expand Up @@ -96,9 +97,6 @@

config.before do
Rails.cache.clear
if RSpec.current_example.metadata[:js] && page.driver.browser.respond_to?(:url_blacklist)
page.driver.browser.url_blacklist = ['http://fonts.googleapis.com']
end
end

config.include BaseFeatureHelper, type: :feature
Expand All @@ -112,6 +110,7 @@
config.include Spree::TestingSupport::Flash
config.include Spree::TestingSupport::Translations
config.include Spree::TestingSupport::JobHelpers
config.include Spree::TestingSupport::BlacklistUrls

config.extend WithModel

Expand Down
2 changes: 1 addition & 1 deletion core/lib/spree/testing_support/blacklist_urls.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module TestingSupport
module BlacklistUrls
def setup_url_blacklist(browser)
if browser.respond_to?(:url_blacklist)
browser.url_blacklist = ['http://fonts.googleapis.com']
browser.url_blacklist = ['https://fonts.googleapis.com']
end
end
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ $cart_total_text_color: #FFFFFF !default;
/*--------------------------------------*/
/* Fonts import from remote
/*--------------------------------------*/
@import url(//fonts.googleapis.com/css?family=Ubuntu:400,700,400italic,700italic|&subset=latin,cyrillic,greek,greek-ext,latin-ext,cyrillic-ext);
@import url(https://fonts.googleapis.com/css?family=Ubuntu:400,700,400italic,700italic|&subset=latin,cyrillic,greek,greek-ext,latin-ext,cyrillic-ext);

/*--------------------------------------*/
/* Font families
Expand Down

0 comments on commit 76e2875

Please sign in to comment.