confetti 0.8.0 → 0.8.1
Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile.lock
CHANGED
@@ -39,8 +39,10 @@ module Confetti
|
|
39
39
|
end
|
40
40
|
|
41
41
|
def version
|
42
|
-
|
43
|
-
|
42
|
+
v = normalize_version(@config.version_string).split('.')
|
43
|
+
|
44
|
+
# after the first one, each segment can only have one character
|
45
|
+
"#{ v[0] }.#{ v[1][0..0] }.#{ v[2][0..0] }.0"
|
44
46
|
end
|
45
47
|
|
46
48
|
def capabilities
|
data/lib/confetti/version.rb
CHANGED
@@ -141,4 +141,22 @@ describe Confetti::Template::WindowsPhone7Manifest do
|
|
141
141
|
@template.description.length.should be < 250
|
142
142
|
end
|
143
143
|
end
|
144
|
+
|
145
|
+
describe "version" do
|
146
|
+
before do
|
147
|
+
@config = Confetti::Config.new
|
148
|
+
@template = @template_class.new(@config)
|
149
|
+
end
|
150
|
+
|
151
|
+
it "should normalize the version to four parts" do
|
152
|
+
@config.version_string = "1.0.0"
|
153
|
+
@template.version.should == "1.0.0.0"
|
154
|
+
end
|
155
|
+
|
156
|
+
it "should ensure the non-initial numbers are one digit" do
|
157
|
+
# THIS IS STUPID
|
158
|
+
@config.version_string = "2012.05.20"
|
159
|
+
@template.version.should == "2012.0.2.0"
|
160
|
+
end
|
161
|
+
end
|
144
162
|
end
|
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 0
|
7
7
|
- 8
|
8
|
-
-
|
9
|
-
version: 0.8.
|
8
|
+
- 1
|
9
|
+
version: 0.8.1
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Andrew Lunny
|
@@ -16,7 +16,7 @@ autorequire:
|
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
18
|
|
19
|
-
date: 2012-06-
|
19
|
+
date: 2012-06-16 00:00:00 -07:00
|
20
20
|
default_executable:
|
21
21
|
dependencies:
|
22
22
|
- !ruby/object:Gem::Dependency
|