Class: GitlabQuality::TestTooling::Report::UpdateScreenshotPath
- Inherits:
-
Object
- Object
- GitlabQuality::TestTooling::Report::UpdateScreenshotPath
- Defined in:
- lib/gitlab_quality/test_tooling/report/update_screenshot_path.rb
Constant Summary collapse
- CONTAINER_PATH =
File.join('/home', 'gitlab', 'qa', 'tmp').freeze
Instance Method Summary collapse
-
#initialize(input_files:) ⇒ UpdateScreenshotPath
constructor
A new instance of UpdateScreenshotPath.
- #invoke! ⇒ Object
Constructor Details
#initialize(input_files:) ⇒ UpdateScreenshotPath
Returns a new instance of UpdateScreenshotPath.
11 12 13 |
# File 'lib/gitlab_quality/test_tooling/report/update_screenshot_path.rb', line 11 def initialize(input_files:) @input_files = input_files end |
Instance Method Details
#invoke! ⇒ Object
17 18 19 20 21 22 |
# File 'lib/gitlab_quality/test_tooling/report/update_screenshot_path.rb', line 17 def invoke! Dir.glob(input_files).each do |input_file| rewrite_screenshot_paths_in_junit_file(input_file) if input_file.end_with?('.xml') rewrite_screenshot_paths_in_json_file(input_file) if input_file.end_with?('.json') end end |