csl 1.0.0.pre17 → 1.0.0.pre18

Sign up to get free protection for your applications and to get access to all the features.
@@ -29,7 +29,7 @@ module CSL
29
29
  end
30
30
 
31
31
  Schema.values[:date_part][:form].each do |type|
32
- pattern = Regexp.new("^#{type}", true)
32
+ pattern = Regexp.new("^#{type}$", true)
33
33
 
34
34
  define_method("#{type}?".tr('-', '_')) do
35
35
  form =~ pattern
@@ -1,3 +1,3 @@
1
1
  module CSL
2
- VERSION = '1.0.0.pre17'.freeze
2
+ VERSION = '1.0.0.pre18'.freeze
3
3
  end
@@ -6,6 +6,16 @@ module CSL
6
6
  end
7
7
 
8
8
  describe Style::DatePart do
9
-
9
+
10
+ describe '#numeric-leading-zeros?' do
11
+
12
+ it { should_not be_numeric_leading_zeros }
13
+
14
+ it 'returns true when the form is set accordingly' do
15
+ subject[:form] = 'numeric-leading-zeros'
16
+ subject.should be_numeric_leading_zeros
17
+ end
18
+ end
19
+
10
20
  end
11
21
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: csl
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.pre17
4
+ version: 1.0.0.pre18
5
5
  prerelease: 6
6
6
  platform: ruby
7
7
  authors:
@@ -183,7 +183,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
183
183
  version: '0'
184
184
  segments:
185
185
  - 0
186
- hash: -438810669519834613
186
+ hash: -4542727712575061360
187
187
  required_rubygems_version: !ruby/object:Gem::Requirement
188
188
  none: false
189
189
  requirements: