Sha256: 7dc24a601a6fc8a64a89c4c96a695d129e346b7f25c29db3111a796b32aeacfa
Contents?: true
Size: 881 Bytes
Versions: 3
Compression:
Stored size: 881 Bytes
Contents
require 'spec_helper' describe LintTrap::Linter::GoLint do let(:container){LintTrap::Container::Fake.new} let(:options){{}} let(:files){%w(good.go bad.go)} subject(:linter){described_class.new} let(:command){instance_double(LintTrap::Command)} it_behaves_like 'linter' its(:languages){is_expected.to eq([LintTrap::Language::Go.new])} its(:version){is_expected.to eq(LintTrap::VERSION)} its(:image){is_expected.to eq('lintci/golint')} its(:image_version){is_expected.to eq('lintci/golint:' + LintTrap::VERSION)} describe '#lint' do it 'runs the lint command with the correct arguments' do expect(LintTrap::Command).to receive(:new).with( 'golint', [], files ).and_return(command) expect(command).to receive(:run).with(container).and_return(true) linter.lint(files, container, options) end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
lint_trap-0.0.15 | spec/linter/golint_spec.rb |
lint_trap-0.0.14 | spec/linter/golint_spec.rb |
lint_trap-0.0.13 | spec/linter/golint_spec.rb |