spec/rake/funnel/support/specs_remover_spec.rb in rake-funnel-0.7.0.pre vs spec/rake/funnel/support/specs_remover_spec.rb in rake-funnel-0.8.0.pre
- old
+ new
@@ -1,6 +1,10 @@
describe Rake::Funnel::Support::SpecsRemover do
+ before {
+ allow(Rake::Funnel::Support::Trace).to receive(:message)
+ }
+
describe 'removal' do
let(:projects) {}
let(:references) {}
let(:specs) {}
let(:packages) {}
@@ -215,9 +219,34 @@
file = 'paket.references'
original_content = content(file, example_dir(example))
expect(content(file)).to eq(original_content)
end
+ end
+ end
+ end
+
+ context 'multiple projects' do
+ let(:example) { 'multiple projects' }
+
+ before {
+ Dir.chdir(temp_dir) do
+ described_class.remove(projects: projects,
+ references: references,
+ specs: specs,
+ packages: packages)
+ end
+ }
+
+ describe 'projects' do
+ it 'should remove references' do
+ expect(content('Sample1.csproj')).not_to include(*references)
+ expect(content('Sample2.csproj')).not_to include(*references)
+ end
+
+ it 'should remove compiled specs' do
+ expect(content('Sample1.csproj')).not_to include(*%w(Specs.cs))
+ expect(content('Sample2.csproj')).not_to include(*%w(Specs.cs))
end
end
end
end
end