Sha256: 611f03a1e4a05dcbfe7244cd14aced2bf9a0f7386c7d2ca8141cc46a11c4c49c
Contents?: true
Size: 878 Bytes
Versions: 1
Compression:
Stored size: 878 Bytes
Contents
require File.expand_path("../spec_helper", __FILE__) module Danger describe Danger::DangerCodenarc do it "should be a plugin" do expect(Danger::DangerCodenarc.new(nil)).to be_a Danger::Plugin end # TODO: Add more ... ya know... tests. describe "with Dangerfile" do before do @dangerfile = testing_dangerfile @my_plugin = @dangerfile.codenarc end it "Counts p2 and p3 as warnings" do report_path = File.expand_path('../support/example.xml', __FILE__) @my_plugin.report(report_path) expect(@dangerfile.status_report[:warnings].size).to eq(78) end it "Counts p1 as errors" do report_path = File.expand_path('../support/example.xml', __FILE__) @my_plugin.report(report_path) expect(@dangerfile.status_report[:errors].size).to eq(0) end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
danger-codenarc-0.1.0 | spec/codenarc_spec.rb |