From 5bd97b923a403aebde166dca02d76b01686c5a42 Mon Sep 17 00:00:00 2001 From: Jacob Cody Wimer Date: Thu, 3 May 2018 17:17:38 +0000 Subject: [PATCH] Added brakeman to running tests and added a silencer for secret key --- bin/run-all-tests.sh | 1 + config/brakeman.ignore | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+) create mode 100644 config/brakeman.ignore diff --git a/bin/run-all-tests.sh b/bin/run-all-tests.sh index 961a6e7..266674c 100755 --- a/bin/run-all-tests.sh +++ b/bin/run-all-tests.sh @@ -3,4 +3,5 @@ project_dir="$(dirname $( dirname $(readlink -f ${BASH_SOURCE[0]})))" cd ${project_dir} rake db:migrate RAILS_ENV=test +brakeman rake test diff --git a/config/brakeman.ignore b/config/brakeman.ignore new file mode 100644 index 0000000..9cf104b --- /dev/null +++ b/config/brakeman.ignore @@ -0,0 +1,22 @@ +{ + "ignored_warnings": [ + { + "warning_type": "Session Setting", + "warning_code": 29, + "fingerprint": "715ad9c0d76f57a6a657192574d528b620176a80fec969e2f63c88eacab0b984", + "check_name": "SessionSettings", + "message": "Session secret should not be included in version control", + "file": "config/initializers/secret_token.rb", + "line": 15, + "link": "https://brakemanscanner.org/docs/warning_types/session_setting/", + "code": null, + "render_path": null, + "location": null, + "user_input": null, + "confidence": "High", + "note": "This is an environment variable for production and embedded for test and dev" + } + ], + "updated": "2018-05-03 17:15:51 +0000", + "brakeman_version": "4.2.1" +}