rnexus 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +2 -4
- data/VERSION +1 -1
- data/lib/repository.rb +2 -2
- data/rnexus.gemspec +5 -6
- data/test/repository_test.rb +3 -3
- metadata +6 -6
data/Rakefile
CHANGED
@@ -9,13 +9,11 @@ begin
|
|
9
9
|
gem.email = "darrinholst@gmail.com"
|
10
10
|
gem.homepage = "http://github.com/darrinholst/rnexus"
|
11
11
|
gem.authors = ["Darrin Holst"]
|
12
|
-
gem.
|
13
|
-
gem.add_dependency("rest-client", ">= 1.0.3")
|
12
|
+
gem.add_dependency("rest-client", ">= 1.4.0")
|
14
13
|
gem.add_dependency("crack", ">= 0.1.3")
|
15
|
-
# gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
|
16
14
|
end
|
17
15
|
|
18
|
-
Jeweler::
|
16
|
+
Jeweler::GemcutterTasks.new
|
19
17
|
rescue LoadError
|
20
18
|
puts "Jeweler (or a dependency) not available. Install it with: sudo gem install jeweler"
|
21
19
|
end
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.4
|
data/lib/repository.rb
CHANGED
@@ -22,7 +22,7 @@ class Nexus::Repository
|
|
22
22
|
end
|
23
23
|
|
24
24
|
def download(artifact)
|
25
|
-
RestClient.get(artifact.uri)
|
25
|
+
RestClient.get(artifact.uri).body
|
26
26
|
end
|
27
27
|
|
28
28
|
def delete(artifact)
|
@@ -51,7 +51,7 @@ class Nexus::Repository
|
|
51
51
|
end
|
52
52
|
|
53
53
|
def nexus_parameters_to_s
|
54
|
-
"(#{NEXUS_PARAMETERS.keys.join(', ')})"
|
54
|
+
"(#{NEXUS_PARAMETERS.keys.map{|k| k.to_s}.sort.join(', ')})"
|
55
55
|
end
|
56
56
|
end
|
57
57
|
|
data/rnexus.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{rnexus}
|
8
|
-
s.version = "0.0.
|
8
|
+
s.version = "0.0.4"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Darrin Holst"]
|
12
|
-
s.date = %q{2010-05-
|
12
|
+
s.date = %q{2010-05-28}
|
13
13
|
s.email = %q{darrinholst@gmail.com}
|
14
14
|
s.extra_rdoc_files = [
|
15
15
|
"LICENSE",
|
@@ -33,7 +33,6 @@ Gem::Specification.new do |s|
|
|
33
33
|
s.homepage = %q{http://github.com/darrinholst/rnexus}
|
34
34
|
s.rdoc_options = ["--charset=UTF-8"]
|
35
35
|
s.require_paths = ["lib"]
|
36
|
-
s.rubyforge_project = %q{rnexus}
|
37
36
|
s.rubygems_version = %q{1.3.6}
|
38
37
|
s.summary = %q{a ruby wrapper to interact with a nexus maven repository}
|
39
38
|
s.test_files = [
|
@@ -47,14 +46,14 @@ Gem::Specification.new do |s|
|
|
47
46
|
s.specification_version = 3
|
48
47
|
|
49
48
|
if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
|
50
|
-
s.add_runtime_dependency(%q<rest-client>, [">= 1.0
|
49
|
+
s.add_runtime_dependency(%q<rest-client>, [">= 1.4.0"])
|
51
50
|
s.add_runtime_dependency(%q<crack>, [">= 0.1.3"])
|
52
51
|
else
|
53
|
-
s.add_dependency(%q<rest-client>, [">= 1.0
|
52
|
+
s.add_dependency(%q<rest-client>, [">= 1.4.0"])
|
54
53
|
s.add_dependency(%q<crack>, [">= 0.1.3"])
|
55
54
|
end
|
56
55
|
else
|
57
|
-
s.add_dependency(%q<rest-client>, [">= 1.0
|
56
|
+
s.add_dependency(%q<rest-client>, [">= 1.4.0"])
|
58
57
|
s.add_dependency(%q<crack>, [">= 0.1.3"])
|
59
58
|
end
|
60
59
|
end
|
data/test/repository_test.rb
CHANGED
@@ -51,7 +51,7 @@ class RepositoryTest < Test::Unit::TestCase
|
|
51
51
|
@repository.find_artifacts(:a => 'foo', :b => 'bar')
|
52
52
|
end
|
53
53
|
|
54
|
-
assert_equal("invalid argument passed, valid arguments are (
|
54
|
+
assert_equal("invalid argument passed, valid arguments are (group, name, type)", exception.message)
|
55
55
|
end
|
56
56
|
|
57
57
|
def test_find_artifacts_when_empty_arguments_passed
|
@@ -59,7 +59,7 @@ class RepositoryTest < Test::Unit::TestCase
|
|
59
59
|
@repository.find_artifacts({})
|
60
60
|
end
|
61
61
|
|
62
|
-
assert_equal("must pass at least one argument (
|
62
|
+
assert_equal("must pass at least one argument (group, name, type)", exception.message)
|
63
63
|
end
|
64
64
|
|
65
65
|
def test_delete
|
@@ -73,7 +73,7 @@ class RepositoryTest < Test::Unit::TestCase
|
|
73
73
|
artifact = Nexus::Artifact.new('resourceURI' => 'http://nexus/artifact')
|
74
74
|
FakeWeb.register_uri(:get, "http://nexus/artifact", :body => 'file content')
|
75
75
|
file = @repository.download(artifact)
|
76
|
-
assert_equal('file content', file
|
76
|
+
assert_equal('file content', file)
|
77
77
|
end
|
78
78
|
|
79
79
|
def assert_artifacts(artifacts)
|
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 0
|
7
7
|
- 0
|
8
|
-
-
|
9
|
-
version: 0.0.
|
8
|
+
- 4
|
9
|
+
version: 0.0.4
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Darrin Holst
|
@@ -14,7 +14,7 @@ autorequire:
|
|
14
14
|
bindir: bin
|
15
15
|
cert_chain: []
|
16
16
|
|
17
|
-
date: 2010-05-
|
17
|
+
date: 2010-05-28 00:00:00 -05:00
|
18
18
|
default_executable:
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
@@ -26,9 +26,9 @@ dependencies:
|
|
26
26
|
- !ruby/object:Gem::Version
|
27
27
|
segments:
|
28
28
|
- 1
|
29
|
+
- 4
|
29
30
|
- 0
|
30
|
-
|
31
|
-
version: 1.0.3
|
31
|
+
version: 1.4.0
|
32
32
|
type: :runtime
|
33
33
|
version_requirements: *id001
|
34
34
|
- !ruby/object:Gem::Dependency
|
@@ -93,7 +93,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
93
93
|
version: "0"
|
94
94
|
requirements: []
|
95
95
|
|
96
|
-
rubyforge_project:
|
96
|
+
rubyforge_project:
|
97
97
|
rubygems_version: 1.3.6
|
98
98
|
signing_key:
|
99
99
|
specification_version: 3
|