ro-bundle 0.2.2 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 71fc78c61c900fe8b5ae9dcdda3fcee7fea98950
4
- data.tar.gz: 30ba191ae5fffa92a7021de13f651c69eb90a73e
2
+ SHA256:
3
+ metadata.gz: 6ed1daf47820e3dd172cd7a5f6f63c57645005ee2ef6544988634d3023930b4f
4
+ data.tar.gz: 5b46dc689ce0e2ec3cbf1ba732a04bda58149fdb68da44f5866f070c1df7048b
5
5
  SHA512:
6
- metadata.gz: 231f3166eb997af23bd5262ffe392ac58eeb4faf1006485079207a0fe522302b7f06483b18faa3743bea5da88ff8b3daf7b69e5e7d303375bfbdea8f5b54cd9c
7
- data.tar.gz: 4adf5c5333319ce8b11d959fab6bb887ef404f83ecc1993865abedeca5047f4f9adc604731cc65a9eb23e24df1e2072e86b1fe41b20daf9ffd772a98227d994c
6
+ metadata.gz: b55a356f46bb9c1fc2dde5f0ebb3dcd9f510d590901349cccf4a74eefc61e5faa086906dc1404931809e41b0a13800db658c09296655e6edb1fcc89c3f507007
7
+ data.tar.gz: 0e443aac1f88b96ed2002f95e6898fc805e8b655d4bb3bf5fb0b6b46d847ccdec12b9c73aa4e185f0d255b933aa92a533507fa3de325d90090bd12972ce5dd57
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- ruby-2.2.8
1
+ ruby-2.6.6
data/Changes.rdoc CHANGED
@@ -1,5 +1,9 @@
1
1
  = Changes log for the RO Bundle Ruby Gem
2
2
 
3
+ == Version 0.2.3
4
+
5
+ * Re-added missing `manifest` reader to ROBundle::File.
6
+
3
7
  == Version 0.2.2
4
8
 
5
9
  * Update ucf dependency to fix rubyzip security vulnerability.
data/Rakefile CHANGED
@@ -15,7 +15,7 @@ task :default => [:test]
15
15
  Rake::TestTask.new do |t|
16
16
  t.libs << "test"
17
17
  t.test_files = FileList['test/ts_ro_bundle.rb']
18
- t.verbose = true
18
+ t.verbose = false
19
19
  end
20
20
 
21
21
  RDoc::Task.new do |r|
@@ -26,6 +26,8 @@ module ROBundle
26
26
 
27
27
  private_class_method :new
28
28
 
29
+ attr_reader :manifest
30
+
29
31
  # :stopdoc:
30
32
  MIMETYPE = "application/vnd.wf4ever.robundle+zip"
31
33
 
@@ -33,7 +33,7 @@ module ROBundle
33
33
  @structure[:uri] = if Util.is_absolute_uri?(object)
34
34
  object.to_s
35
35
  else
36
- URI.encode(object.start_with?("/") ? object : "/#{object}")
36
+ Addressable::URI.encode(object.start_with?("/") ? object : "/#{object}")
37
37
  end
38
38
  @structure[:mediatype] = mediatype
39
39
  end
@@ -52,7 +52,7 @@ module ROBundle
52
52
  #
53
53
  # The path of this aggregate in "rubyzip" format, i.e. no leading '/'.
54
54
  def file_entry
55
- URI.decode(Util.strip_leading_slash(uri)) unless Util.is_absolute_uri?(uri)
55
+ Addressable::URI.unencode(Util.strip_leading_slash(uri)) unless Util.is_absolute_uri?(uri)
56
56
  end
57
57
 
58
58
  # :call-seq:
@@ -9,5 +9,5 @@
9
9
  #
10
10
  module ROBundle
11
11
  # The version number of this library as a String.
12
- VERSION = "0.2.2"
12
+ VERSION = "0.3.0"
13
13
  end
data/lib/ro-bundle.rb CHANGED
@@ -13,6 +13,7 @@ require "time"
13
13
  require "ucf"
14
14
  require "uri"
15
15
  require "uuid"
16
+ require "addressable"
16
17
 
17
18
  require "ro-bundle/version"
18
19
  require "ro-bundle/util"
data/ro-bundle.gemspec CHANGED
@@ -21,24 +21,23 @@ Gem::Specification.new do |spec|
21
21
  "Research Object (RO) bundles. The RO bundle specification can be found "\
22
22
  "at https://w3id.org/bundle/."
23
23
  spec.homepage = "http://www.researchobject.org/"
24
- spec.license = "BSD"
24
+ spec.license = "BSD-3-Clause"
25
25
 
26
26
  spec.files = `git ls-files`.split($/)
27
27
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
28
28
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
29
29
  spec.require_paths = ["lib"]
30
30
 
31
- spec.has_rdoc = true
32
31
  spec.extra_rdoc_files = [ "Changes.rdoc", "Licence.rdoc", "ReadMe.rdoc" ]
33
32
  spec.rdoc_options = [ "-N", "--tab-width=2", "--main=ReadMe.rdoc" ]
34
33
 
35
- spec.required_ruby_version = ">= 1.9.3"
36
- spec.add_development_dependency "bundler", "~> 1.5"
37
- spec.add_development_dependency "rake", "~> 10.1"
38
- spec.add_development_dependency "rdoc", "~> 4.1"
34
+ spec.required_ruby_version = ">= 2.6.0"
35
+ spec.add_development_dependency "rake", "~> 12.3.3"
36
+ spec.add_development_dependency "rdoc", "~> 6.3.1"
39
37
  spec.add_development_dependency "test-unit", "~> 3.0"
40
- spec.add_development_dependency "coveralls"
41
- spec.add_runtime_dependency "ucf", "~> 2.0.1"
42
- spec.add_runtime_dependency "json", "~> 1.8"
38
+ spec.add_development_dependency "coveralls", "~> 0.8.23"
39
+ spec.add_runtime_dependency "ucf", "~> 2.0.2"
40
+ spec.add_runtime_dependency "json", "~> 2.3.0"
43
41
  spec.add_runtime_dependency "uuid", "~> 2.3"
42
+ spec.add_runtime_dependency "addressable", "~> 2.8.0"
44
43
  end
data/test/tc_create.rb CHANGED
@@ -185,4 +185,18 @@ class TestCreation < Test::Unit::TestCase
185
185
  end
186
186
  end
187
187
 
188
+ def test_get_manifest
189
+ Dir.mktmpdir do |dir|
190
+ filename = File.join(dir, "test.bundle")
191
+
192
+ assert_nothing_raised do
193
+ ROBundle::File.create(filename) do |b|
194
+ assert_nothing_raised do
195
+ b.manifest
196
+ end
197
+ end
198
+ end
199
+ end
200
+ end
201
+
188
202
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ro-bundle
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robert Haines
@@ -10,50 +10,36 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2018-01-19 00:00:00.000000000 Z
13
+ date: 2022-01-24 00:00:00.000000000 Z
14
14
  dependencies:
15
- - !ruby/object:Gem::Dependency
16
- name: bundler
17
- requirement: !ruby/object:Gem::Requirement
18
- requirements:
19
- - - "~>"
20
- - !ruby/object:Gem::Version
21
- version: '1.5'
22
- type: :development
23
- prerelease: false
24
- version_requirements: !ruby/object:Gem::Requirement
25
- requirements:
26
- - - "~>"
27
- - !ruby/object:Gem::Version
28
- version: '1.5'
29
15
  - !ruby/object:Gem::Dependency
30
16
  name: rake
31
17
  requirement: !ruby/object:Gem::Requirement
32
18
  requirements:
33
19
  - - "~>"
34
20
  - !ruby/object:Gem::Version
35
- version: '10.1'
21
+ version: 12.3.3
36
22
  type: :development
37
23
  prerelease: false
38
24
  version_requirements: !ruby/object:Gem::Requirement
39
25
  requirements:
40
26
  - - "~>"
41
27
  - !ruby/object:Gem::Version
42
- version: '10.1'
28
+ version: 12.3.3
43
29
  - !ruby/object:Gem::Dependency
44
30
  name: rdoc
45
31
  requirement: !ruby/object:Gem::Requirement
46
32
  requirements:
47
33
  - - "~>"
48
34
  - !ruby/object:Gem::Version
49
- version: '4.1'
35
+ version: 6.3.1
50
36
  type: :development
51
37
  prerelease: false
52
38
  version_requirements: !ruby/object:Gem::Requirement
53
39
  requirements:
54
40
  - - "~>"
55
41
  - !ruby/object:Gem::Version
56
- version: '4.1'
42
+ version: 6.3.1
57
43
  - !ruby/object:Gem::Dependency
58
44
  name: test-unit
59
45
  requirement: !ruby/object:Gem::Requirement
@@ -72,44 +58,44 @@ dependencies:
72
58
  name: coveralls
73
59
  requirement: !ruby/object:Gem::Requirement
74
60
  requirements:
75
- - - ">="
61
+ - - "~>"
76
62
  - !ruby/object:Gem::Version
77
- version: '0'
63
+ version: 0.8.23
78
64
  type: :development
79
65
  prerelease: false
80
66
  version_requirements: !ruby/object:Gem::Requirement
81
67
  requirements:
82
- - - ">="
68
+ - - "~>"
83
69
  - !ruby/object:Gem::Version
84
- version: '0'
70
+ version: 0.8.23
85
71
  - !ruby/object:Gem::Dependency
86
72
  name: ucf
87
73
  requirement: !ruby/object:Gem::Requirement
88
74
  requirements:
89
75
  - - "~>"
90
76
  - !ruby/object:Gem::Version
91
- version: 2.0.1
77
+ version: 2.0.2
92
78
  type: :runtime
93
79
  prerelease: false
94
80
  version_requirements: !ruby/object:Gem::Requirement
95
81
  requirements:
96
82
  - - "~>"
97
83
  - !ruby/object:Gem::Version
98
- version: 2.0.1
84
+ version: 2.0.2
99
85
  - !ruby/object:Gem::Dependency
100
86
  name: json
101
87
  requirement: !ruby/object:Gem::Requirement
102
88
  requirements:
103
89
  - - "~>"
104
90
  - !ruby/object:Gem::Version
105
- version: '1.8'
91
+ version: 2.3.0
106
92
  type: :runtime
107
93
  prerelease: false
108
94
  version_requirements: !ruby/object:Gem::Requirement
109
95
  requirements:
110
96
  - - "~>"
111
97
  - !ruby/object:Gem::Version
112
- version: '1.8'
98
+ version: 2.3.0
113
99
  - !ruby/object:Gem::Dependency
114
100
  name: uuid
115
101
  requirement: !ruby/object:Gem::Requirement
@@ -124,6 +110,20 @@ dependencies:
124
110
  - - "~>"
125
111
  - !ruby/object:Gem::Version
126
112
  version: '2.3'
113
+ - !ruby/object:Gem::Dependency
114
+ name: addressable
115
+ requirement: !ruby/object:Gem::Requirement
116
+ requirements:
117
+ - - "~>"
118
+ - !ruby/object:Gem::Version
119
+ version: 2.8.0
120
+ type: :runtime
121
+ prerelease: false
122
+ version_requirements: !ruby/object:Gem::Requirement
123
+ requirements:
124
+ - - "~>"
125
+ - !ruby/object:Gem::Version
126
+ version: 2.8.0
127
127
  description: This library provides an API for manipulating Research Object (RO) bundles.
128
128
  The RO bundle specification can be found at https://w3id.org/bundle/.
129
129
  email:
@@ -190,7 +190,7 @@ files:
190
190
  - test/ts_ro_bundle.rb
191
191
  homepage: http://www.researchobject.org/
192
192
  licenses:
193
- - BSD
193
+ - BSD-3-Clause
194
194
  metadata: {}
195
195
  post_install_message:
196
196
  rdoc_options:
@@ -203,15 +203,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
203
203
  requirements:
204
204
  - - ">="
205
205
  - !ruby/object:Gem::Version
206
- version: 1.9.3
206
+ version: 2.6.0
207
207
  required_rubygems_version: !ruby/object:Gem::Requirement
208
208
  requirements:
209
209
  - - ">="
210
210
  - !ruby/object:Gem::Version
211
211
  version: '0'
212
212
  requirements: []
213
- rubyforge_project:
214
- rubygems_version: 2.4.8
213
+ rubygems_version: 3.0.8
215
214
  signing_key:
216
215
  specification_version: 4
217
216
  summary: This library provides an API for manipulating Research Object (RO) bundles.