datacite-mapping 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGES.md +4 -0
- data/datacite-mapping.gemspec +1 -1
- data/lib/datacite/mapping/module_info.rb +1 -1
- data/spec/unit/datacite/mapping/log_spec.rb +23 -0
- metadata +6 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 930b87f0c713df87fdfb98ccec007a1b5bd12782
|
4
|
+
data.tar.gz: f8972ae87744fb2ecef07f3dcd150ecfdea875ac
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 48e367daa0194fdf95bec71d25809047c12fde35d112f31b84868a4598ac464585a2611f31a26350f6df280bc44ab1fc13b491a671ea51110aa6d867a7a78239
|
7
|
+
data.tar.gz: 787da05d0a22de31f66b6f1865bddee0a70656c817e129df5902cf5893c36d953b06b7a40267b1c82f3b74020cc49e6d47b431362b2b1936ff4214e42057f7f5
|
data/CHANGES.md
CHANGED
data/datacite-mapping.gemspec
CHANGED
@@ -23,7 +23,7 @@ Gem::Specification.new do |spec|
|
|
23
23
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
24
24
|
spec.require_paths = ['lib']
|
25
25
|
|
26
|
-
spec.add_dependency 'typesafe_enum', '~> 0.1', '>= 0.1.
|
26
|
+
spec.add_dependency 'typesafe_enum', '~> 0.1', '>= 0.1.4'
|
27
27
|
spec.add_dependency 'xml-mapping_extensions', '~> 0.3', '>= 0.3.2'
|
28
28
|
|
29
29
|
spec.add_development_dependency 'bundler', '~> 1.7'
|
@@ -0,0 +1,23 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
module Datacite
|
4
|
+
module Mapping
|
5
|
+
describe 'log' do
|
6
|
+
it 'logs to stdout in a timestamp-first format' do
|
7
|
+
out = StringIO.new
|
8
|
+
Mapping.log_device = out
|
9
|
+
begin
|
10
|
+
msg = 'I am a log message'
|
11
|
+
Mapping.log.warn(msg)
|
12
|
+
logged = out.string
|
13
|
+
expect(logged).to include(msg)
|
14
|
+
timestamp_str = logged.split[0]
|
15
|
+
timestamp = DateTime.parse(timestamp_str)
|
16
|
+
expect(timestamp.to_date).to eq(Time.now.utc.to_date)
|
17
|
+
ensure
|
18
|
+
Mapping.log_device = $stdout
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: datacite-mapping
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- David Moles
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-12-
|
11
|
+
date: 2015-12-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typesafe_enum
|
@@ -19,7 +19,7 @@ dependencies:
|
|
19
19
|
version: '0.1'
|
20
20
|
- - ">="
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version: 0.1.
|
22
|
+
version: 0.1.4
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
25
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -29,7 +29,7 @@ dependencies:
|
|
29
29
|
version: '0.1'
|
30
30
|
- - ">="
|
31
31
|
- !ruby/object:Gem::Version
|
32
|
-
version: 0.1.
|
32
|
+
version: 0.1.4
|
33
33
|
- !ruby/object:Gem::Dependency
|
34
34
|
name: xml-mapping_extensions
|
35
35
|
requirement: !ruby/object:Gem::Requirement
|
@@ -213,6 +213,7 @@ files:
|
|
213
213
|
- spec/unit/datacite/mapping/geo_location_point_spec.rb
|
214
214
|
- spec/unit/datacite/mapping/geo_location_spec.rb
|
215
215
|
- spec/unit/datacite/mapping/identifier_spec.rb
|
216
|
+
- spec/unit/datacite/mapping/log_spec.rb
|
216
217
|
- spec/unit/datacite/mapping/name_identifier_spec.rb
|
217
218
|
- spec/unit/datacite/mapping/related_identifier_spec.rb
|
218
219
|
- spec/unit/datacite/mapping/resource_spec.rb
|
@@ -258,6 +259,7 @@ test_files:
|
|
258
259
|
- spec/unit/datacite/mapping/geo_location_point_spec.rb
|
259
260
|
- spec/unit/datacite/mapping/geo_location_spec.rb
|
260
261
|
- spec/unit/datacite/mapping/identifier_spec.rb
|
262
|
+
- spec/unit/datacite/mapping/log_spec.rb
|
261
263
|
- spec/unit/datacite/mapping/name_identifier_spec.rb
|
262
264
|
- spec/unit/datacite/mapping/related_identifier_spec.rb
|
263
265
|
- spec/unit/datacite/mapping/resource_spec.rb
|