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:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-03-17 09:09:21 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-03-17 09:09:21 +0300
commitc8df22c555ab707a705e57c4257fd3ed1ce7c3b0 (patch)
tree009fb7c1ff12a6192921212cae404b790fd7d66b /spec/support/capybara.rb
parent9345f69894862e02f3491ea3136c3ed2b23fd5b8 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/support/capybara.rb')
-rw-r--r--spec/support/capybara.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/support/capybara.rb b/spec/support/capybara.rb
index 5d8779ec782..90adfb1a2ee 100644
--- a/spec/support/capybara.rb
+++ b/spec/support/capybara.rb
@@ -126,6 +126,12 @@ RSpec.configure do |config|
Capybara.raise_server_errors = false
example.run
+
+ if example.metadata[:screenshot]
+ screenshot = example.metadata[:screenshot][:image] || example.metadata[:screenshot][:html]
+ example.metadata[:stdout] = %{[[ATTACHMENT|#{screenshot}]]}
+ end
+
ensure
Capybara.raise_server_errors = true
end