Sha256: 7ceb2bb52787f8ed21bda76ce2f84426f2bdd31ae1b32e8603d15406faf0e56a
Contents?: true
Size: 715 Bytes
Versions: 2
Compression:
Stored size: 715 Bytes
Contents
require 'tempfile' require_relative '../../spec_helper' require_relative '../../../lib/reek/examiner' require_relative '../../../lib/reek/report/report' RSpec.describe Reek::Report::HTMLReport do let(:instance) { Reek::Report::HTMLReport.new } context 'with an empty source' do let(:examiner) { Reek::Examiner.new('') } before do instance.add_examiner examiner end it 'has the text 0 total warnings' do tempfile = Tempfile.new(['Reek::Report::HTMLReport.', '.html']) response = "HTML file saved\n" expect { instance.show(target_path: tempfile.path) }. to output(response).to_stdout expect(tempfile.read).to include('0 total warnings') end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
reek-3.4.0 | spec/reek/report/html_report_spec.rb |
reek-3.3.1 | spec/reek/report/html_report_spec.rb |