mbrao 1.4.3 → 1.4.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/doc/ActionView/Template/Handlers.html +4 -4
- data/doc/ActionView/Template/Handlers/MbraoTemplate.html +4 -4
- data/doc/HTML.html +4 -4
- data/doc/HTML/Pipeline.html +4 -4
- data/doc/HTML/Pipeline/KramdownFilter.html +4 -4
- data/doc/Mbrao.html +4 -4
- data/doc/Mbrao/Author.html +4 -4
- data/doc/Mbrao/Content.html +152 -68
- data/doc/Mbrao/ContentPublicInterface.html +4 -4
- data/doc/Mbrao/Exceptions.html +4 -4
- data/doc/Mbrao/Exceptions/InvalidDate.html +4 -4
- data/doc/Mbrao/Exceptions/InvalidMetadata.html +4 -4
- data/doc/Mbrao/Exceptions/Parsing.html +4 -4
- data/doc/Mbrao/Exceptions/Rendering.html +4 -4
- data/doc/Mbrao/Exceptions/UnavailableLocalization.html +4 -4
- data/doc/Mbrao/Exceptions/Unimplemented.html +4 -4
- data/doc/Mbrao/Exceptions/UnknownEngine.html +4 -4
- data/doc/Mbrao/Parser.html +4 -4
- data/doc/Mbrao/ParsingEngines.html +4 -4
- data/doc/Mbrao/ParsingEngines/Base.html +4 -4
- data/doc/Mbrao/ParsingEngines/PlainText.html +4 -4
- data/doc/Mbrao/PublicInterface.html +4 -4
- data/doc/Mbrao/PublicInterface/ClassMethods.html +4 -4
- data/doc/Mbrao/RenderingEngines.html +4 -4
- data/doc/Mbrao/RenderingEngines/Base.html +4 -4
- data/doc/Mbrao/RenderingEngines/HtmlPipeline.html +4 -4
- data/doc/Mbrao/Validations.html +4 -4
- data/doc/Mbrao/Validations/ClassMethods.html +4 -4
- data/doc/Mbrao/Version.html +5 -5
- data/doc/_index.html +5 -5
- data/doc/css/style.css +1 -0
- data/doc/file.README.html +4 -4
- data/doc/frames.html +1 -1
- data/doc/index.html +4 -4
- data/doc/top-level-namespace.html +4 -4
- data/lib/mbrao/content.rb +7 -3
- data/lib/mbrao/version.rb +1 -1
- data/spec/mbrao/content_spec.rb +29 -4
- metadata +2 -2
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Module: Mbrao::RenderingEngines
|
8
8
|
|
9
|
-
— Documentation by YARD 0.8.7.
|
9
|
+
— Documentation by YARD 0.8.7.4
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -17,7 +17,7 @@
|
|
17
17
|
<script type="text/javascript" charset="utf-8">
|
18
18
|
hasFrames = window.top.frames.main ? true : false;
|
19
19
|
relpath = '../';
|
20
|
-
framesUrl = "../frames.html#!"
|
20
|
+
framesUrl = "../frames.html#!Mbrao/RenderingEngines.html";
|
21
21
|
</script>
|
22
22
|
|
23
23
|
|
@@ -118,9 +118,9 @@
|
|
118
118
|
</div>
|
119
119
|
|
120
120
|
<div id="footer">
|
121
|
-
Generated on
|
121
|
+
Generated on Wed Apr 9 21:36:00 2014 by
|
122
122
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
123
|
-
0.8.7.
|
123
|
+
0.8.7.4 (ruby-2.1.0).
|
124
124
|
</div>
|
125
125
|
|
126
126
|
</body>
|
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Class: Mbrao::RenderingEngines::Base
|
8
8
|
|
9
|
-
— Documentation by YARD 0.8.7.
|
9
|
+
— Documentation by YARD 0.8.7.4
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -17,7 +17,7 @@
|
|
17
17
|
<script type="text/javascript" charset="utf-8">
|
18
18
|
hasFrames = window.top.frames.main ? true : false;
|
19
19
|
relpath = '../../';
|
20
|
-
framesUrl = "../../frames.html#!"
|
20
|
+
framesUrl = "../../frames.html#!Mbrao/RenderingEngines/Base.html";
|
21
21
|
</script>
|
22
22
|
|
23
23
|
|
@@ -271,9 +271,9 @@
|
|
271
271
|
</div>
|
272
272
|
|
273
273
|
<div id="footer">
|
274
|
-
Generated on
|
274
|
+
Generated on Wed Apr 9 21:36:01 2014 by
|
275
275
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
276
|
-
0.8.7.
|
276
|
+
0.8.7.4 (ruby-2.1.0).
|
277
277
|
</div>
|
278
278
|
|
279
279
|
</body>
|
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Class: Mbrao::RenderingEngines::HtmlPipeline
|
8
8
|
|
9
|
-
— Documentation by YARD 0.8.7.
|
9
|
+
— Documentation by YARD 0.8.7.4
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -17,7 +17,7 @@
|
|
17
17
|
<script type="text/javascript" charset="utf-8">
|
18
18
|
hasFrames = window.top.frames.main ? true : false;
|
19
19
|
relpath = '../../';
|
20
|
-
framesUrl = "../../frames.html#!"
|
20
|
+
framesUrl = "../../frames.html#!Mbrao/RenderingEngines/HtmlPipeline.html";
|
21
21
|
</script>
|
22
22
|
|
23
23
|
|
@@ -876,9 +876,9 @@
|
|
876
876
|
</div>
|
877
877
|
|
878
878
|
<div id="footer">
|
879
|
-
Generated on
|
879
|
+
Generated on Wed Apr 9 21:36:01 2014 by
|
880
880
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
881
|
-
0.8.7.
|
881
|
+
0.8.7.4 (ruby-2.1.0).
|
882
882
|
</div>
|
883
883
|
|
884
884
|
</body>
|
data/doc/Mbrao/Validations.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Module: Mbrao::Validations
|
8
8
|
|
9
|
-
— Documentation by YARD 0.8.7.
|
9
|
+
— Documentation by YARD 0.8.7.4
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -17,7 +17,7 @@
|
|
17
17
|
<script type="text/javascript" charset="utf-8">
|
18
18
|
hasFrames = window.top.frames.main ? true : false;
|
19
19
|
relpath = '../';
|
20
|
-
framesUrl = "../frames.html#!"
|
20
|
+
framesUrl = "../frames.html#!Mbrao/Validations.html";
|
21
21
|
</script>
|
22
22
|
|
23
23
|
|
@@ -125,9 +125,9 @@
|
|
125
125
|
</div>
|
126
126
|
|
127
127
|
<div id="footer">
|
128
|
-
Generated on
|
128
|
+
Generated on Wed Apr 9 21:36:00 2014 by
|
129
129
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
130
|
-
0.8.7.
|
130
|
+
0.8.7.4 (ruby-2.1.0).
|
131
131
|
</div>
|
132
132
|
|
133
133
|
</body>
|
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Module: Mbrao::Validations::ClassMethods
|
8
8
|
|
9
|
-
— Documentation by YARD 0.8.7.
|
9
|
+
— Documentation by YARD 0.8.7.4
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -17,7 +17,7 @@
|
|
17
17
|
<script type="text/javascript" charset="utf-8">
|
18
18
|
hasFrames = window.top.frames.main ? true : false;
|
19
19
|
relpath = '../../';
|
20
|
-
framesUrl = "../../frames.html#!"
|
20
|
+
framesUrl = "../../frames.html#!Mbrao/Validations/ClassMethods.html";
|
21
21
|
</script>
|
22
22
|
|
23
23
|
|
@@ -345,9 +345,9 @@
|
|
345
345
|
</div>
|
346
346
|
|
347
347
|
<div id="footer">
|
348
|
-
Generated on
|
348
|
+
Generated on Wed Apr 9 21:36:00 2014 by
|
349
349
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
350
|
-
0.8.7.
|
350
|
+
0.8.7.4 (ruby-2.1.0).
|
351
351
|
</div>
|
352
352
|
|
353
353
|
</body>
|
data/doc/Mbrao/Version.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Module: Mbrao::Version
|
8
8
|
|
9
|
-
— Documentation by YARD 0.8.7.
|
9
|
+
— Documentation by YARD 0.8.7.4
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -17,7 +17,7 @@
|
|
17
17
|
<script type="text/javascript" charset="utf-8">
|
18
18
|
hasFrames = window.top.frames.main ? true : false;
|
19
19
|
relpath = '../';
|
20
|
-
framesUrl = "../frames.html#!"
|
20
|
+
framesUrl = "../frames.html#!Mbrao/Version.html";
|
21
21
|
</script>
|
22
22
|
|
23
23
|
|
@@ -149,7 +149,7 @@
|
|
149
149
|
|
150
150
|
</div>
|
151
151
|
</dt>
|
152
|
-
<dd><pre class="code"><span class='int'>
|
152
|
+
<dd><pre class="code"><span class='int'>4</span></pre></dd>
|
153
153
|
|
154
154
|
<dt id="STRING-constant" class="">STRING =
|
155
155
|
<div class="docstring">
|
@@ -180,9 +180,9 @@
|
|
180
180
|
</div>
|
181
181
|
|
182
182
|
<div id="footer">
|
183
|
-
Generated on
|
183
|
+
Generated on Wed Apr 9 21:36:00 2014 by
|
184
184
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
185
|
-
0.8.7.
|
185
|
+
0.8.7.4 (ruby-2.1.0).
|
186
186
|
</div>
|
187
187
|
|
188
188
|
</body>
|
data/doc/_index.html
CHANGED
@@ -4,7 +4,7 @@
|
|
4
4
|
<head>
|
5
5
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
6
6
|
<title>
|
7
|
-
Documentation by YARD 0.8.7.
|
7
|
+
Documentation by YARD 0.8.7.4
|
8
8
|
|
9
9
|
</title>
|
10
10
|
|
@@ -15,7 +15,7 @@
|
|
15
15
|
<script type="text/javascript" charset="utf-8">
|
16
16
|
hasFrames = window.top.frames.main ? true : false;
|
17
17
|
relpath = '';
|
18
|
-
framesUrl = "frames.html#!"
|
18
|
+
framesUrl = "frames.html#!_index.html";
|
19
19
|
</script>
|
20
20
|
|
21
21
|
|
@@ -56,7 +56,7 @@
|
|
56
56
|
|
57
57
|
<iframe id="search_frame"></iframe>
|
58
58
|
|
59
|
-
<div id="content"><h1 class="noborder title">Documentation by YARD 0.8.7.
|
59
|
+
<div id="content"><h1 class="noborder title">Documentation by YARD 0.8.7.4</h1>
|
60
60
|
<div id="listing">
|
61
61
|
<h1 class="alphaindex">Alphabetic Index</h1>
|
62
62
|
|
@@ -386,9 +386,9 @@
|
|
386
386
|
</div>
|
387
387
|
|
388
388
|
<div id="footer">
|
389
|
-
Generated on
|
389
|
+
Generated on Wed Apr 9 21:35:59 2014 by
|
390
390
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
391
|
-
0.8.7.
|
391
|
+
0.8.7.4 (ruby-2.1.0).
|
392
392
|
</div>
|
393
393
|
|
394
394
|
</body>
|
data/doc/css/style.css
CHANGED
@@ -291,6 +291,7 @@ li.r2 { background: #fafafa; }
|
|
291
291
|
-moz-box-shadow: -2px 2px 6px #bbb;
|
292
292
|
z-index: 5000;
|
293
293
|
position: relative;
|
294
|
+
overflow-x: auto;
|
294
295
|
}
|
295
296
|
#toc.nofloat { float: none; max-width: none; border: none; padding: 0; margin: 20px 0; -webkit-box-shadow: none; -moz-box-shadow: none; }
|
296
297
|
#toc.nofloat.hidden { padding: 0; background: 0; margin-bottom: 5px; }
|
data/doc/file.README.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
File: README
|
8
8
|
|
9
|
-
— Documentation by YARD 0.8.7.
|
9
|
+
— Documentation by YARD 0.8.7.4
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -17,7 +17,7 @@
|
|
17
17
|
<script type="text/javascript" charset="utf-8">
|
18
18
|
hasFrames = window.top.frames.main ? true : false;
|
19
19
|
relpath = '';
|
20
|
-
framesUrl = "frames.html#!
|
20
|
+
framesUrl = "frames.html#!file.README.html";
|
21
21
|
</script>
|
22
22
|
|
23
23
|
|
@@ -130,9 +130,9 @@ Mbrao::Parser.render(content)
|
|
130
130
|
</div></div>
|
131
131
|
|
132
132
|
<div id="footer">
|
133
|
-
Generated on
|
133
|
+
Generated on Wed Apr 9 21:36:00 2014 by
|
134
134
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
135
|
-
0.8.7.
|
135
|
+
0.8.7.4 (ruby-2.1.0).
|
136
136
|
</div>
|
137
137
|
|
138
138
|
</body>
|
data/doc/frames.html
CHANGED
@@ -4,7 +4,7 @@
|
|
4
4
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
5
5
|
<head>
|
6
6
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
7
|
-
<title>Documentation by YARD 0.8.7.
|
7
|
+
<title>Documentation by YARD 0.8.7.4</title>
|
8
8
|
</head>
|
9
9
|
<script type="text/javascript" charset="utf-8">
|
10
10
|
window.onload = function() {
|
data/doc/index.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
File: README
|
8
8
|
|
9
|
-
— Documentation by YARD 0.8.7.
|
9
|
+
— Documentation by YARD 0.8.7.4
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -17,7 +17,7 @@
|
|
17
17
|
<script type="text/javascript" charset="utf-8">
|
18
18
|
hasFrames = window.top.frames.main ? true : false;
|
19
19
|
relpath = '';
|
20
|
-
framesUrl = "frames.html#!
|
20
|
+
framesUrl = "frames.html#!file.README.html";
|
21
21
|
</script>
|
22
22
|
|
23
23
|
|
@@ -130,9 +130,9 @@ Mbrao::Parser.render(content)
|
|
130
130
|
</div></div>
|
131
131
|
|
132
132
|
<div id="footer">
|
133
|
-
Generated on
|
133
|
+
Generated on Wed Apr 9 21:36:00 2014 by
|
134
134
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
135
|
-
0.8.7.
|
135
|
+
0.8.7.4 (ruby-2.1.0).
|
136
136
|
</div>
|
137
137
|
|
138
138
|
</body>
|
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Top Level Namespace
|
8
8
|
|
9
|
-
— Documentation by YARD 0.8.7.
|
9
|
+
— Documentation by YARD 0.8.7.4
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -17,7 +17,7 @@
|
|
17
17
|
<script type="text/javascript" charset="utf-8">
|
18
18
|
hasFrames = window.top.frames.main ? true : false;
|
19
19
|
relpath = '';
|
20
|
-
framesUrl = "frames.html#!"
|
20
|
+
framesUrl = "frames.html#!top-level-namespace.html";
|
21
21
|
</script>
|
22
22
|
|
23
23
|
|
@@ -103,9 +103,9 @@
|
|
103
103
|
</div>
|
104
104
|
|
105
105
|
<div id="footer">
|
106
|
-
Generated on
|
106
|
+
Generated on Wed Apr 9 21:36:00 2014 by
|
107
107
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
108
|
-
0.8.7.
|
108
|
+
0.8.7.4 (ruby-2.1.0).
|
109
109
|
</div>
|
110
110
|
|
111
111
|
</body>
|
data/lib/mbrao/content.rb
CHANGED
@@ -134,9 +134,13 @@ module Mbrao
|
|
134
134
|
# The allowed string format for a datetime.
|
135
135
|
ALLOWED_DATETIME_FORMATS = [
|
136
136
|
"%Y%m%dT%H%M%S%z", "%Y%m%dT%H%M%S%Z",
|
137
|
-
"%FT%T.%L
|
138
|
-
"%
|
139
|
-
"%
|
137
|
+
"%FT%T.%L%z", "%FT%T.%L%Z",
|
138
|
+
"%FT%T%z", "%FT%T%Z",
|
139
|
+
"%F %T %z", "%F %T %Z",
|
140
|
+
"%F %T.%L %z", "%F %T.%L %Z",
|
141
|
+
|
142
|
+
"%F %T.%L", "%F %T", "%F %H:%M", "%F",
|
143
|
+
"%d/%m/%Y %T.%L", "%d/%m/%Y %T", "%d/%m/%Y %H:%M", "%d/%m/%Y"
|
140
144
|
]
|
141
145
|
|
142
146
|
# Creates a new content.
|
data/lib/mbrao/version.rb
CHANGED
data/spec/mbrao/content_spec.rb
CHANGED
@@ -116,6 +116,7 @@ describe Mbrao::Content do
|
|
116
116
|
end
|
117
117
|
|
118
118
|
it "should try to parse everything else as a ISO8601 format" do
|
119
|
+
# "%Y%m%dT%H%M%S%z", "%Y%m%dT%H%M%S%Z"
|
119
120
|
subject.send("#{attribute}=", "20120808T083045-0200")
|
120
121
|
value = subject.send(attribute)
|
121
122
|
expect(value).to be_a(DateTime)
|
@@ -124,20 +125,37 @@ describe Mbrao::Content do
|
|
124
125
|
subject.send("#{attribute}=", "20120808T083045-02:00")
|
125
126
|
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120808T103045+0000")
|
126
127
|
|
128
|
+
# "%FT%T.%L%z", "%FT%T.%L%Z"
|
129
|
+
subject.send("#{attribute}=", "2012-08-08T08:30:45.123-0200")
|
130
|
+
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%L%z")).to eq("20120808T103045123+0000")
|
131
|
+
|
132
|
+
subject.send("#{attribute}=", "2012-08-08T08:30:45.123-02:00")
|
133
|
+
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%L%z")).to eq("20120808T103045123+0000")
|
134
|
+
|
135
|
+
# "%FT%T%z", "%FT%T%Z"
|
127
136
|
subject.send("#{attribute}=", "2012-08-08T08:30:45-0200")
|
128
137
|
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120808T103045+0000")
|
129
138
|
|
130
139
|
subject.send("#{attribute}=", "2012-08-08T08:30:45-02:00")
|
131
140
|
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120808T103045+0000")
|
132
141
|
|
142
|
+
# "%F %T %z", "%F %T %Z"
|
133
143
|
subject.send("#{attribute}=", "2012-08-08 08:30:45 -0200")
|
134
144
|
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120808T103045+0000")
|
135
145
|
|
136
146
|
subject.send("#{attribute}=", "2012-08-08 08:30:45 -02:00")
|
137
147
|
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120808T103045+0000")
|
138
148
|
|
139
|
-
|
140
|
-
|
149
|
+
# "%F %T.%L %z", "%F %T.%L %Z"
|
150
|
+
subject.send("#{attribute}=", "2012-08-08 08:30:45.123 -0200")
|
151
|
+
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%L%z")).to eq("20120808T103045123+0000")
|
152
|
+
|
153
|
+
subject.send("#{attribute}=", "2012-08-08 08:30:45.123 -02:00")
|
154
|
+
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%L%z")).to eq("20120808T103045123+0000")
|
155
|
+
|
156
|
+
# "%F %T%.L", "%F %T", "%F %H:%M", "%F"
|
157
|
+
subject.send("#{attribute}=", "2012-08-08 08:30:45.123")
|
158
|
+
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%L%z")).to eq("20120808T083045123+0000")
|
141
159
|
|
142
160
|
subject.send("#{attribute}=", "2012-08-08 08:30:45")
|
143
161
|
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120808T083045+0000")
|
@@ -145,8 +163,12 @@ describe Mbrao::Content do
|
|
145
163
|
subject.send("#{attribute}=", "2012-08-08 08:30")
|
146
164
|
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120808T083000+0000")
|
147
165
|
|
148
|
-
subject.send("#{attribute}=", "08
|
149
|
-
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("
|
166
|
+
subject.send("#{attribute}=", "2012-08-08")
|
167
|
+
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120808T000000+0000")
|
168
|
+
|
169
|
+
# "%d/%m/%Y %T.%L", "%d/%m/%Y %T", "%d/%m/%Y %H:%M", "%d/%m/%Y"
|
170
|
+
subject.send("#{attribute}=", "08/09/2012 08:30:45.123")
|
171
|
+
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%L%z")).to eq("20120908T083045123+0000")
|
150
172
|
|
151
173
|
subject.send("#{attribute}=", "08/09/2012 08:30:45")
|
152
174
|
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120908T083045+0000")
|
@@ -154,6 +176,9 @@ describe Mbrao::Content do
|
|
154
176
|
subject.send("#{attribute}=", "08/09/2012 08:30")
|
155
177
|
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120908T083000+0000")
|
156
178
|
|
179
|
+
subject.send("#{attribute}=", "08/09/2012")
|
180
|
+
expect(subject.send(attribute).strftime("%Y%m%dT%H%M%S%z")).to eq("20120908T000000+0000")
|
181
|
+
|
157
182
|
expect { subject.send("#{attribute}=", "ABC") }.to raise_error(Mbrao::Exceptions::InvalidDate)
|
158
183
|
expect { subject.send("#{attribute}=", []) }.to raise_error(Mbrao::Exceptions::InvalidDate)
|
159
184
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mbrao
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.4.
|
4
|
+
version: 1.4.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shogun
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-04-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: lazier
|