spec/integration_spec.rb in mrjoy-bundler-audit-0.3.1 vs spec/integration_spec.rb in mrjoy-bundler-audit-0.3.2

- old
+ new

@@ -1,10 +1,8 @@ require 'spec_helper' describe "CLI" do - include Helpers - let(:directory) { File.join('spec','bundle',bundle) } context "when auditing a vulnerable bundle" do let(:bundle) { 'unpatched_gems' } @@ -14,11 +12,12 @@ # vulnerabilities we should match with the regex below. vuln_count = output.split(/Name:/).length - 1 # Less one for the # zero-width prefix before # the first match. - # Note the "{8,}" below indicates the minimum number of advisories that - # we should see matches for -- as a particular version of code will never + # Note the "{vuln_count}" below indicates the minimum number of + # advisories that we should see matches for -- as a particular version of + # code will never advisory_pattern = /(Name: [^\n]+ Version: \d+\.\d+\.\d+ Advisory: OSVDB-\d+ Criticality: (High|Medium) URL: http:\/\/(direct\.|www\.)?osvdb\.org\/show\/osvdb\/\d+