From 59b1556ebd47f67303454a4b249fa63df41429dd Mon Sep 17 00:00:00 2001 From: Michael Ball Date: Thu, 15 Aug 2024 01:04:34 -0700 Subject: [PATCH] fix spec helper --- _includes/head_custom.html | 26 +++++++++++++++++++++++--- spec/spec_helper.rb | 2 +- 2 files changed, 24 insertions(+), 4 deletions(-) diff --git a/_includes/head_custom.html b/_includes/head_custom.html index 2e7aafa..5f734bf 100644 --- a/_includes/head_custom.html +++ b/_includes/head_custom.html @@ -5,21 +5,41 @@ + diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 8cd31a4..f7c94ab 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -57,7 +57,7 @@ end Capybara::Screenshot.register_filename_prefix_formatter(:rspec) do |example| - example.example_group.top_level_description.gsub(%r{^/}, '').gsub('/', '-').gsub(' is accessible', '') + page = example.example_group.top_level_description.gsub(%r{^/}, '').gsub('/', '-').gsub(' is accessible', '') standards = example.description.split.last "tmp/capybara/screenshot_#{page}_#{standards}" end