reapack-index 1.0 → 1.1beta1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +3 -1
- data/lib/reapack/index.rb +10 -13
- data/lib/reapack/index/cli.rb +6 -3
- data/lib/reapack/index/cli/options.rb +22 -12
- data/lib/reapack/index/gem_version.rb +1 -1
- data/lib/reapack/index/git.rb +1 -1
- data/lib/reapack/index/metadata.rb +46 -6
- data/lib/reapack/index/package.rb +31 -6
- data/lib/reapack/index/scanner.rb +54 -13
- data/lib/reapack/index/version.rb +3 -4
- data/reapack-index.gemspec +1 -1
- data/setup/reapack-index.nsi +2 -2
- data/test/cli/test_metadata.rb +13 -0
- data/test/cli/test_scan.rb +14 -0
- data/test/data/index.xml +1 -1
- data/test/index/test_metadata.rb +5 -5
- data/test/index/test_scan.rb +31 -103
- data/test/scanner/test_makeurl.rb +102 -0
- data/test/scanner/test_validation.rb +126 -0
- data/test/test_git.rb +10 -0
- data/test/test_index.rb +35 -25
- data/test/test_metadata.rb +115 -19
- data/test/test_package.rb +55 -5
- data/test/test_scanner.rb +113 -140
- data/test/test_source.rb +16 -0
- metadata +10 -6
data/test/test_source.rb
CHANGED
@@ -19,6 +19,22 @@ class TestSource < MiniTest::Test
|
|
19
19
|
assert_equal after.chomp, before.to_s
|
20
20
|
end
|
21
21
|
|
22
|
+
def test_escaped_url
|
23
|
+
before = make_node '<version name="1.0"/>'
|
24
|
+
after = <<-XML
|
25
|
+
<version name="1.0">
|
26
|
+
<source>http://files.cfillion.tk/hello%20world.lua</source>
|
27
|
+
</version>
|
28
|
+
XML
|
29
|
+
|
30
|
+
src = ReaPack::Index::Source.new 'http://files.cfillion.tk/./hello%20world.lua'
|
31
|
+
assert_equal 'http://files.cfillion.tk/./hello%20world.lua', src.url
|
32
|
+
|
33
|
+
src.make_node before
|
34
|
+
|
35
|
+
assert_equal after.chomp, before.to_s
|
36
|
+
end
|
37
|
+
|
22
38
|
def test_invalid_url
|
23
39
|
after = '<version name="1.0"/>'
|
24
40
|
before = make_node after
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: reapack-index
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 1.1beta1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- cfillion
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-07-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -128,14 +128,14 @@ dependencies:
|
|
128
128
|
requirements:
|
129
129
|
- - "~>"
|
130
130
|
- !ruby/object:Gem::Version
|
131
|
-
version: 1.
|
131
|
+
version: 1.3beta1
|
132
132
|
type: :runtime
|
133
133
|
prerelease: false
|
134
134
|
version_requirements: !ruby/object:Gem::Requirement
|
135
135
|
requirements:
|
136
136
|
- - "~>"
|
137
137
|
- !ruby/object:Gem::Version
|
138
|
-
version: 1.
|
138
|
+
version: 1.3beta1
|
139
139
|
- !ruby/object:Gem::Dependency
|
140
140
|
name: nokogiri
|
141
141
|
requirement: !ruby/object:Gem::Requirement
|
@@ -233,6 +233,8 @@ files:
|
|
233
233
|
- test/index/test_metadata.rb
|
234
234
|
- test/index/test_provides.rb
|
235
235
|
- test/index/test_scan.rb
|
236
|
+
- test/scanner/test_makeurl.rb
|
237
|
+
- test/scanner/test_validation.rb
|
236
238
|
- test/test_cdetector.rb
|
237
239
|
- test/test_changelog.rb
|
238
240
|
- test/test_cli.rb
|
@@ -261,9 +263,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
261
263
|
version: '2.3'
|
262
264
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
263
265
|
requirements:
|
264
|
-
- - "
|
266
|
+
- - ">"
|
265
267
|
- !ruby/object:Gem::Version
|
266
|
-
version:
|
268
|
+
version: 1.3.1
|
267
269
|
requirements: []
|
268
270
|
rubyforge_project:
|
269
271
|
rubygems_version: 2.5.1
|
@@ -279,6 +281,8 @@ test_files:
|
|
279
281
|
- test/index/test_metadata.rb
|
280
282
|
- test/index/test_provides.rb
|
281
283
|
- test/index/test_scan.rb
|
284
|
+
- test/scanner/test_makeurl.rb
|
285
|
+
- test/scanner/test_validation.rb
|
282
286
|
- test/test_cdetector.rb
|
283
287
|
- test/test_changelog.rb
|
284
288
|
- test/test_cli.rb
|