rake-funnel 0.8.0.pre → 0.9.0.pre
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/rake/funnel/support/trace.rb +15 -15
- data/lib/rake/funnel/support/version_info.rb +0 -1
- data/lib/rake/funnel/version.rb +1 -1
- data/spec/rake/funnel/support/assembly_version_writer_spec.rb +21 -5
- data/spec/rake/funnel/support/specs_remover/project/paket.references +3 -3
- data/spec/rake/funnel/support/specs_remover/project/uncompiled-code/paket.references +3 -3
- data/spec/rake/funnel/support/specs_remover/project-specific paket.references/Sample.csproj.paket.references +3 -3
- data/spec/rake/funnel/support/specs_remover/project-specific paket.references/paket.references +3 -3
- data/spec/rake/funnel/support/version_info_spec.rb +0 -10
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a24c43a1a9f0170bc60541024af1b0c7fba00bbe
|
4
|
+
data.tar.gz: 6781d9f355a322c4aa2a317466345d31e6c1df7c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 16ee74bb0cefd902f980df81fb4e685ae6446d8fb67e8e6f28d6677c4551f224919f9e9775d9e641e6633a7e12bb5df83a6cc9240dee07d438ba960a093054b9
|
7
|
+
data.tar.gz: a812455493c6c84e4187ae4376559f81834a1fd2a7f3de66e11f5c445ca5f587908b62dbe4bb7d54f16b87081e27e4ba2ec34281c7762c2cbc6eaba0252196f2
|
@@ -1,15 +1,15 @@
|
|
1
|
-
module Rake
|
2
|
-
module Funnel
|
3
|
-
module Support
|
4
|
-
class Trace
|
5
|
-
class << self
|
6
|
-
def message(message)
|
7
|
-
return unless Rake.application.options.trace
|
8
|
-
|
9
|
-
Rake.rake_output_message(message)
|
10
|
-
end
|
11
|
-
end
|
12
|
-
end
|
13
|
-
end
|
14
|
-
end
|
15
|
-
end
|
1
|
+
module Rake
|
2
|
+
module Funnel
|
3
|
+
module Support
|
4
|
+
class Trace
|
5
|
+
class << self
|
6
|
+
def message(message)
|
7
|
+
return unless Rake.application.options.trace
|
8
|
+
|
9
|
+
Rake.rake_output_message(message)
|
10
|
+
end
|
11
|
+
end
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
data/lib/rake/funnel/version.rb
CHANGED
@@ -56,7 +56,7 @@ describe Rake::Funnel::Support::AssemblyVersionWriter do
|
|
56
56
|
end
|
57
57
|
end
|
58
58
|
|
59
|
-
describe '
|
59
|
+
describe '#write' do
|
60
60
|
let(:source) {
|
61
61
|
[
|
62
62
|
{
|
@@ -82,7 +82,6 @@ describe Rake::Funnel::Support::AssemblyVersionWriter do
|
|
82
82
|
|
83
83
|
let(:target_path) { double(Proc).as_null_object }
|
84
84
|
let(:languages) { [:vb, :cs, :fs] }
|
85
|
-
let(:erb) { double(ERB).as_null_object }
|
86
85
|
|
87
86
|
subject {
|
88
87
|
described_class.new(source)
|
@@ -93,11 +92,11 @@ describe Rake::Funnel::Support::AssemblyVersionWriter do
|
|
93
92
|
}
|
94
93
|
|
95
94
|
before {
|
96
|
-
allow(ERB).to receive(:new).
|
95
|
+
allow(ERB).to receive(:new).and_call_original
|
97
96
|
}
|
98
97
|
|
99
98
|
before {
|
100
|
-
allow(File).to receive(:read).
|
99
|
+
allow(File).to receive(:read).and_call_original
|
101
100
|
allow(File).to receive(:write)
|
102
101
|
}
|
103
102
|
|
@@ -121,7 +120,7 @@ describe Rake::Funnel::Support::AssemblyVersionWriter do
|
|
121
120
|
end
|
122
121
|
|
123
122
|
it 'should run templates through ERb' do
|
124
|
-
expect(
|
123
|
+
expect(ERB).to have_received(:new).exactly(languages.length * source.length).times
|
125
124
|
end
|
126
125
|
|
127
126
|
it 'should write version info file for each language in source' do
|
@@ -136,5 +135,22 @@ describe Rake::Funnel::Support::AssemblyVersionWriter do
|
|
136
135
|
expect { subject.write(target_path, languages) }.to raise_error /Language is not supported: unsupported/
|
137
136
|
end
|
138
137
|
end
|
138
|
+
|
139
|
+
describe 'version modification' do
|
140
|
+
let(:target_path) {
|
141
|
+
proc { |_language, version_info, source|
|
142
|
+
version_info.assembly_informational_version = 'totally custom'
|
143
|
+
'file'
|
144
|
+
}
|
145
|
+
}
|
146
|
+
|
147
|
+
before {
|
148
|
+
subject.write(target_path, languages)
|
149
|
+
}
|
150
|
+
|
151
|
+
it 'should use modified version info to generate file' do
|
152
|
+
expect(File).to have_received(:write).with('file', /AssemblyInformationalVersion\("totally custom"\)/).at_least(:once)
|
153
|
+
end
|
154
|
+
end
|
139
155
|
end
|
140
156
|
end
|
@@ -1,3 +1,3 @@
|
|
1
|
-
Paket-Ref
|
2
|
-
Explicitly-Removed-Package
|
3
|
-
Untouched
|
1
|
+
Paket-Ref
|
2
|
+
Explicitly-Removed-Package
|
3
|
+
Untouched
|
@@ -1,3 +1,3 @@
|
|
1
|
-
Paket-Ref
|
2
|
-
Explicitly-Removed-Package
|
3
|
-
Untouched
|
1
|
+
Paket-Ref
|
2
|
+
Explicitly-Removed-Package
|
3
|
+
Untouched
|
@@ -1,3 +1,3 @@
|
|
1
|
-
Paket-Ref
|
2
|
-
Explicitly-Removed-Package
|
3
|
-
Untouched
|
1
|
+
Paket-Ref
|
2
|
+
Explicitly-Removed-Package
|
3
|
+
Untouched
|
data/spec/rake/funnel/support/specs_remover/project-specific paket.references/paket.references
CHANGED
@@ -1,3 +1,3 @@
|
|
1
|
-
Paket-Ref
|
2
|
-
Explicitly-Removed-Package
|
3
|
-
Untouched
|
1
|
+
Paket-Ref
|
2
|
+
Explicitly-Removed-Package
|
3
|
+
Untouched
|
@@ -300,16 +300,6 @@ describe Rake::Funnel::Support::VersionInfo do
|
|
300
300
|
it 'should be an OpenStruct' do
|
301
301
|
expect(described_class < OpenStruct).to eq(true)
|
302
302
|
end
|
303
|
-
|
304
|
-
describe 'immutability' do
|
305
|
-
let(:args) { { a: 42 } }
|
306
|
-
|
307
|
-
subject { described_class.new(args) }
|
308
|
-
|
309
|
-
it 'should be immutable' do
|
310
|
-
expect { subject.a = 23 }.to raise_error
|
311
|
-
end
|
312
|
-
end
|
313
303
|
end
|
314
304
|
|
315
305
|
describe '#read_version_from' do
|