Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'qa/qa/runtime/fixtures.rb')
-rw-r--r--qa/qa/runtime/fixtures.rb9
1 files changed, 3 insertions, 6 deletions
diff --git a/qa/qa/runtime/fixtures.rb b/qa/qa/runtime/fixtures.rb
index d56af9b4872..201cf7f0fcb 100644
--- a/qa/qa/runtime/fixtures.rb
+++ b/qa/qa/runtime/fixtures.rb
@@ -14,7 +14,8 @@ module QA
response = get(request.url)
unless response.code == HTTP_STATUS_OK
- raise TemplateNotFoundError, "Template at #{request.mask_url} could not be found (#{response.code}): `#{response}`."
+ raise TemplateNotFoundError,
+ "Template at #{request.mask_url} could not be found (#{response.code}): `#{response}`."
end
parse_body(response)[:content]
@@ -34,11 +35,7 @@ module QA
end
def read_fixture(fixture_path, file_name)
- file_path = Pathname
- .new(__dir__)
- .join("../fixtures/#{fixture_path}/#{file_name}")
-
- File.read(file_path)
+ File.read(File.join(Runtime::Path.fixtures_path, fixture_path, file_name))
end
private