summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Allen <dan.j.allen@gmail.com>2022-05-02 17:33:02 -0600
committerDan Allen <dan.j.allen@gmail.com>2022-05-02 17:33:02 -0600
commiteb992d7d83dcc11a1396dbc52c9a160efb675559 (patch)
tree3c63dcd78cc001d93ab645f11f3a2193891f566a
parentb630e68b47ab812d8ef9b39f0fd4647e28e34a90 (diff)
protect against committing test with debug flag on
-rw-r--r--spec/spec_helper.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index a8593815..8cb50b30 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -396,7 +396,9 @@ RSpec.configure do |config|
def to_pdf input, opts = {}
analyze = opts.delete :analyze
- debug = opts.delete :debug
+ if (debug = opts.delete :debug) && ENV['CI']
+ raise ArgumentError, 'debug flag not permitted in CI'
+ end
enable_footer = opts.delete :enable_footer
safe_mode = opts.fetch :safe, :safe
opts[:attributes] = { 'imagesdir' => fixtures_dir } unless opts.key? :attributes