summaryrefslogtreecommitdiff
path: root/spec/support
diff options
context:
space:
mode:
authorMike Greiling <mike@pixelcog.com>2017-01-03 15:26:14 -0600
committerMike Greiling <mike@pixelcog.com>2017-01-05 14:01:16 -0600
commit8cee3b1d36afdb95934e8867fb60c23565c2d330 (patch)
tree0e8eda79169a4f8a2a8fec529722dd67bcec6f7a /spec/support
parentca404170f0173f180b530fbc331fc73e122a4317 (diff)
downloadgitlab-ce-8cee3b1d36afdb95934e8867fb60c23565c2d330.tar.gz
force utf-8 encoding for prior to fixture parsing to prevent nokogiri issues
Diffstat (limited to 'spec/support')
-rw-r--r--spec/support/javascript_fixtures_helpers.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/spec/support/javascript_fixtures_helpers.rb b/spec/support/javascript_fixtures_helpers.rb
index 7cf0e29db34..d15aac61b18 100644
--- a/spec/support/javascript_fixtures_helpers.rb
+++ b/spec/support/javascript_fixtures_helpers.rb
@@ -26,6 +26,7 @@ module JavaScriptFixturesHelpers
def store_frontend_fixture(response, fixture_file_name)
fixture_file_name = File.expand_path(fixture_file_name, FIXTURE_PATH)
fixture = response.body
+ fixture.force_encoding("utf-8")
response_mime_type = Mime::Type.lookup(response.content_type)
if response_mime_type.html?