Sha256: 7c35e7407324129022f5ccab3b51963ae97eeb5f5a23ed9e54f74149a18c6f32
Contents?: true
Size: 822 Bytes
Versions: 3
Compression:
Stored size: 822 Bytes
Contents
require "test_helper" require "rubycritic/adapters/smell/reek" describe Rubycritic::SmellAdapter::Reek do context "when analysing a smelly file" do before do sample_paths = ["test/samples/reek/smelly.rb"] @adapter = Rubycritic::SmellAdapter::Reek.new(sample_paths) end it "detects smells" do @adapter.smells.wont_be_empty end it "has smells with messages" do smell = @adapter.smells.first smell.message.must_equal "has boolean parameter 'reek'" end end context "when analysing a file with smells ignored in config.reek" do before do sample_paths = ["test/samples/reek/not_smelly.rb"] @adapter = Rubycritic::SmellAdapter::Reek.new(sample_paths) end it "does not detect smells" do @adapter.smells.must_be_empty end end end
Version data entries
3 entries across 3 versions & 1 rubygems