eventual 0.5.7 → 0.5.8

Sign up to get free protection for your applications and to get access to all the features.
data/.gitignore CHANGED
@@ -12,6 +12,7 @@ tmtags
12
12
 
13
13
  ## VIM
14
14
  *.swp
15
+ *.swo
15
16
 
16
17
  ## PROJECT::GENERAL
17
18
  coverage
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.5.7
1
+ 0.5.8
@@ -101,6 +101,6 @@ grammar EsDates
101
101
  end
102
102
 
103
103
  rule newline
104
- space* "\n" space*
104
+ space* ("\n" / "\r" )+ space*
105
105
  end
106
106
  end
@@ -419,16 +419,36 @@ describe Eventual, 'Es' do
419
419
  it_should_behave_like 'correctly parses dates'
420
420
  it_should_behave_like 'includes corresponding dates'
421
421
  end
422
-
423
- describe 'compound dates list separated by new line' do
424
- before do
425
- @result = Eventual.parse "31 de diciembre de 1998 \n 1 de enero de 1999"
426
- @dates = [Date.parse('1998-12-31'), Date.parse('1999-1-1')]
422
+
423
+ describe 'compound dates' do
424
+ describe 'compound dates list separated by \n' do
425
+ before do
426
+ @result = Eventual.parse "31 de diciembre de 1998\n1 de enero de 1999"
427
+ @dates = [Date.parse('1998-12-31'), Date.parse('1999-1-1')]
428
+ end
429
+ it_should_behave_like 'correctly parses dates'
430
+ it_should_behave_like 'includes corresponding dates'
431
+ end
432
+
433
+ describe 'compound dates list separated by \r' do
434
+ before do
435
+ @result = Eventual.parse "31 de diciembre de 1998\r1 de enero de 1999"
436
+ @dates = [Date.parse('1998-12-31'), Date.parse('1999-1-1')]
437
+ end
438
+ it_should_behave_like 'correctly parses dates'
439
+ it_should_behave_like 'includes corresponding dates'
427
440
  end
428
- it_should_behave_like 'correctly parses dates'
429
- it_should_behave_like 'includes corresponding dates'
430
- end
431
441
 
442
+ describe 'compound dates list separated by \r\n' do
443
+ before do
444
+ @result = Eventual.parse "31 de diciembre de 1998\r\n1 de enero de 1999"
445
+ @dates = [Date.parse('1998-12-31'), Date.parse('1999-1-1')]
446
+ end
447
+ it_should_behave_like 'correctly parses dates'
448
+ it_should_behave_like 'includes corresponding dates'
449
+ end
450
+ end
451
+
432
452
  describe 'with time constrain' do
433
453
  shared_examples_for 'outputs DateTime' do
434
454
  it "should all be DateTime" do
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: eventual
3
3
  version: !ruby/object:Gem::Version
4
- hash: 5
4
+ hash: 27
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 5
9
- - 7
10
- version: 0.5.7
9
+ - 8
10
+ version: 0.5.8
11
11
  platform: ruby
12
12
  authors:
13
13
  - Macario Ortega