提交 ef71ac49 编写于 作者: J Justin Collins

Merge branch 'remove_timestamp_from_json'

......@@ -629,7 +629,6 @@ HEADER
:security_warnings => all_warnings.length,
:start_time => tracker.start_time.to_s,
:end_time => tracker.end_time.to_s,
:timestamp => tracker.end_time.to_s,
:duration => tracker.duration,
:checks_performed => checks.checks_run.sort,
:number_of_controllers => tracker.controllers.length,
......
......@@ -16,6 +16,14 @@ class JSONOutputTests < Test::Unit::TestCase
assert (@json.keys - ["warnings", "scan_info", "errors"]).empty?
end
def test_for_scan_info_keys
info_keys = ["app_path", "rails_version", "security_warnings", "start_time", "end_time", "duration",
"checks_performed", "number_of_controllers", "number_of_models", "number_of_templates",
"ruby_version", "brakeman_version"]
assert (@json["scan_info"].keys - info_keys).empty?
end
def test_for_expected_warning_keys
expected = ["warning_type", "message", "file", "link", "code", "location",
"render_path", "user_input", "confidence", "line", "warning_code", "fingerprint"]
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册