diff options
| author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-08-22 21:12:24 +0000 |
|---|---|---|
| committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-08-22 21:12:24 +0000 |
| commit | c4a9ca5ffca17bd874dd77014e9f2d607c94b06c (patch) | |
| tree | a4abbf721a24cc0c362d225ca52441124f56c00b /scripts/lib | |
| parent | a3ffaa242bb3b9b4c95a8223ca800126887e3a82 (diff) | |
| download | gitlab-ce-c4a9ca5ffca17bd874dd77014e9f2d607c94b06c.tar.gz | |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'scripts/lib')
| -rw-r--r-- | scripts/lib/glfm/update_example_snapshots.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/scripts/lib/glfm/update_example_snapshots.rb b/scripts/lib/glfm/update_example_snapshots.rb index 953e5cf851d..05a5c988a28 100644 --- a/scripts/lib/glfm/update_example_snapshots.rb +++ b/scripts/lib/glfm/update_example_snapshots.rb @@ -191,9 +191,7 @@ module Glfm # the scripts to read them, because the scripts are run in # separate subprocesses, and during unit testing we are unable to substitute the mock # StringIO when reading the input files in the subprocess. - [ - [ES_MARKDOWN_YML_PATH, MARKDOWN_TEMPFILE_BASENAME] - ].map do |original_file_path, tempfile_basename| + { ES_MARKDOWN_YML_PATH => MARKDOWN_TEMPFILE_BASENAME }.map do |original_file_path, tempfile_basename| Dir::Tmpname.create(tempfile_basename) do |path| io = File.open(original_file_path) io.seek(0) # rewind the file. This is necessary when testing with a mock StringIO |
