hudson 0.3.0.beta.13 → 0.3.0.beta.14

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- hudson (0.3.0.beta.13)
4
+ hudson (0.3.0.beta.14)
5
5
  builder (~> 2.1.2)
6
6
  hpricot
7
7
  httparty (~> 0.6.1)
data/Rakefile CHANGED
@@ -66,7 +66,7 @@ desc 'Alias for cucumber:ok'
66
66
  task :cucumber => 'cucumber:ok'
67
67
 
68
68
  desc "Start test server; Run cucumber:ok; Kill Test Server;"
69
- task :default => ["hudson:server:killtest", "hudson:server:test"] do
69
+ task :default => [:spec, "hudson:server:killtest", "hudson:server:test"] do
70
70
  require 'socket'
71
71
  print "waiting for at most 30 seconds for the server to start"
72
72
  tries = 1
data/bin/hudson CHANGED
@@ -7,5 +7,5 @@ require 'hudson/cli'
7
7
  begin
8
8
  Hudson::CLI.start
9
9
  rescue Errno::ECONNREFUSED, Errno::EAFNOSUPPORT
10
- Hudson::CLI.new.shell.say "No connection available to server.", :red
10
+ Hudson::CLI.new.shell.say "No connection available to the server.", :red
11
11
  end
@@ -3,13 +3,19 @@ Feature: Listing jobs
3
3
 
4
4
  Scenario: List jobs on a non-existent server (hudson list)
5
5
  When I run local executable "hudson" with arguments "list --host localhost --port 9999"
6
- Then I should see "localhost:9999 - no connection"
6
+ Then I should see exactly
7
+ """
8
+ No connection available to the server.
9
+ """
7
10
 
8
11
  Scenario: List jobs on a server with no jobs (hudson list)
9
12
  Given I have a Hudson server running
10
13
  And the Hudson server has no current jobs
11
14
  When I run local executable "hudson" with arguments "list --host localhost --port 3010"
12
- Then I should see "localhost:3010 - no jobs"
15
+ Then I should see exactly
16
+ """
17
+ http://localhost:3010: no jobs
18
+ """
13
19
 
14
20
  Scenario: List jobs on a server with jobs (hudson list)
15
21
  Given I have a Hudson server running
@@ -18,12 +24,11 @@ Feature: Listing jobs
18
24
  And the project uses "git" scm
19
25
  When I run local executable "hudson" with arguments "create . --host localhost --port 3010"
20
26
  When I run local executable "hudson" with arguments "list"
21
- Then I should see "localhost:3010 -"
22
- Then I should see "ruby"
23
- When I run local executable "hudson" with arguments "list --host localhost --port 3010"
24
- Then I should see "localhost:3010 -"
25
- Then I should see "ruby"
26
-
27
-
27
+ Then I should see exactly
28
+ """
29
+ http://localhost:3010:
30
+ * ruby
31
+
32
+ """
28
33
 
29
34
 
@@ -2,16 +2,16 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{hudson}
5
- s.version = "0.3.0.beta.13"
5
+ s.version = "0.3.0.beta.14"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new("> 1.3.1") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Charles Lowell", "Dr Nic Williams"]
9
- s.date = %q{2010-10-29}
9
+ s.date = %q{2010-11-01}
10
10
  s.default_executable = %q{hudson}
11
11
  s.description = %q{A suite of utilities for bringing continous integration to your projects (not the other way around) with hudson CI}
12
12
  s.email = ["cowboyd@thefrontside.net", "drnicwilliams@gmail.com"]
13
13
  s.executables = ["hudson"]
14
- s.files = ["bin", "bin/hudson", "features", "features/development.feature", "features/launch_server.feature", "features/listing_jobs.feature", "features/manage_jobs.feature", "features/manage_remote_servers.feature", "features/manage_slave_nodes.feature", "features/step_definitions", "features/step_definitions/common_steps.rb", "features/step_definitions/fixture_project_steps.rb", "features/step_definitions/hudson_steps.rb", "features/step_definitions/scm_steps.rb", "features/support", "features/support/common.rb", "features/support/env.rb", "features/support/hooks.rb", "features/support/matchers.rb", "fixtures", "fixtures/projects", "fixtures/projects/non-bundler", "fixtures/projects/non-bundler/Rakefile", "fixtures/projects/rails-3", "fixtures/projects/rails-3/app", "fixtures/projects/rails-3/app/controllers", "fixtures/projects/rails-3/app/controllers/application_controller.rb", "fixtures/projects/rails-3/app/helpers", "fixtures/projects/rails-3/app/helpers/application_helper.rb", "fixtures/projects/rails-3/app/mailers", "fixtures/projects/rails-3/app/models", "fixtures/projects/rails-3/app/views", "fixtures/projects/rails-3/app/views/layouts", "fixtures/projects/rails-3/app/views/layouts/application.html.erb", "fixtures/projects/rails-3/config", "fixtures/projects/rails-3/config/application.rb", "fixtures/projects/rails-3/config/boot.rb", "fixtures/projects/rails-3/config/database.yml", "fixtures/projects/rails-3/config/environment.rb", "fixtures/projects/rails-3/config/environments", "fixtures/projects/rails-3/config/environments/development.rb", "fixtures/projects/rails-3/config/environments/production.rb", "fixtures/projects/rails-3/config/environments/test.rb", "fixtures/projects/rails-3/config/initializers", "fixtures/projects/rails-3/config/initializers/backtrace_silencers.rb", "fixtures/projects/rails-3/config/initializers/inflections.rb", "fixtures/projects/rails-3/config/initializers/mime_types.rb", "fixtures/projects/rails-3/config/initializers/secret_token.rb", "fixtures/projects/rails-3/config/initializers/session_store.rb", "fixtures/projects/rails-3/config/locales", "fixtures/projects/rails-3/config/locales/en.yml", "fixtures/projects/rails-3/config/routes.rb", "fixtures/projects/rails-3/config.ru", "fixtures/projects/rails-3/db", "fixtures/projects/rails-3/db/seeds.rb", "fixtures/projects/rails-3/doc", "fixtures/projects/rails-3/doc/README_FOR_APP", "fixtures/projects/rails-3/Gemfile", "fixtures/projects/rails-3/Gemfile.lock", "fixtures/projects/rails-3/lib", "fixtures/projects/rails-3/lib/tasks", "fixtures/projects/rails-3/log", "fixtures/projects/rails-3/log/development.log", "fixtures/projects/rails-3/log/production.log", "fixtures/projects/rails-3/log/server.log", "fixtures/projects/rails-3/log/test.log", "fixtures/projects/rails-3/public", "fixtures/projects/rails-3/public/404.html", "fixtures/projects/rails-3/public/422.html", "fixtures/projects/rails-3/public/500.html", "fixtures/projects/rails-3/public/favicon.ico", "fixtures/projects/rails-3/public/images", "fixtures/projects/rails-3/public/images/rails.png", "fixtures/projects/rails-3/public/index.html", "fixtures/projects/rails-3/public/javascripts", "fixtures/projects/rails-3/public/javascripts/application.js", "fixtures/projects/rails-3/public/javascripts/controls.js", "fixtures/projects/rails-3/public/javascripts/dragdrop.js", "fixtures/projects/rails-3/public/javascripts/effects.js", "fixtures/projects/rails-3/public/javascripts/prototype.js", "fixtures/projects/rails-3/public/javascripts/rails.js", "fixtures/projects/rails-3/public/robots.txt", "fixtures/projects/rails-3/public/stylesheets", "fixtures/projects/rails-3/Rakefile", "fixtures/projects/rails-3/README", "fixtures/projects/rails-3/script", "fixtures/projects/rails-3/script/rails", "fixtures/projects/rails-3/test", "fixtures/projects/rails-3/test/fixtures", "fixtures/projects/rails-3/test/functional", "fixtures/projects/rails-3/test/integration", "fixtures/projects/rails-3/test/performance", "fixtures/projects/rails-3/test/performance/browsing_test.rb", "fixtures/projects/rails-3/test/test_helper.rb", "fixtures/projects/rails-3/test/unit", "fixtures/projects/rails-3/vendor", "fixtures/projects/rails-3/vendor/plugins", "fixtures/projects/ruby", "fixtures/projects/ruby/Gemfile", "fixtures/projects/ruby/Gemfile.lock", "fixtures/projects/ruby/Rakefile", "Gemfile", "Gemfile.lock", "hudson.gemspec", "lib", "lib/hudson", "lib/hudson/api.rb", "lib/hudson/cli", "lib/hudson/cli/formatting.rb", "lib/hudson/cli.rb", "lib/hudson/config.rb", "lib/hudson/core_ext", "lib/hudson/core_ext/object", "lib/hudson/core_ext/object/blank.rb", "lib/hudson/hudson-cli.jar", "lib/hudson/hudson.war", "lib/hudson/hudson_version.rb", "lib/hudson/job_config_builder.rb", "lib/hudson/plugins", "lib/hudson/plugins/git.hpi", "lib/hudson/plugins/github.hpi", "lib/hudson/plugins/greenballs.hpi", "lib/hudson/plugins/rake.hpi", "lib/hudson/plugins/ruby.hpi", "lib/hudson/project_scm.rb", "lib/hudson/remote.rb", "lib/hudson/version.rb", "lib/hudson.rb", "Rakefile", "README.md", "spec", "spec/fixtures", "spec/fixtures/ec2_global.config.xml", "spec/fixtures/rails.multi.config.xml", "spec/fixtures/rails.single.config.triggers.xml", "spec/fixtures/rails.single.config.xml", "spec/fixtures/rubygem.config.xml", "spec/fixtures/therubyracer.config.xml", "spec/job_config_builder_spec.rb", "spec/spec_helper.rb", "tasks", "tasks/upgrade.rake"]
14
+ s.files = ["bin", "bin/hudson", "features", "features/development.feature", "features/launch_server.feature", "features/listing_jobs.feature", "features/manage_jobs.feature", "features/manage_slave_nodes.feature", "features/step_definitions", "features/step_definitions/common_steps.rb", "features/step_definitions/fixture_project_steps.rb", "features/step_definitions/hudson_steps.rb", "features/step_definitions/scm_steps.rb", "features/support", "features/support/common.rb", "features/support/env.rb", "features/support/hooks.rb", "features/support/matchers.rb", "fixtures", "fixtures/projects", "fixtures/projects/non-bundler", "fixtures/projects/non-bundler/Rakefile", "fixtures/projects/rails-3", "fixtures/projects/rails-3/app", "fixtures/projects/rails-3/app/controllers", "fixtures/projects/rails-3/app/controllers/application_controller.rb", "fixtures/projects/rails-3/app/helpers", "fixtures/projects/rails-3/app/helpers/application_helper.rb", "fixtures/projects/rails-3/app/mailers", "fixtures/projects/rails-3/app/models", "fixtures/projects/rails-3/app/views", "fixtures/projects/rails-3/app/views/layouts", "fixtures/projects/rails-3/app/views/layouts/application.html.erb", "fixtures/projects/rails-3/config", "fixtures/projects/rails-3/config/application.rb", "fixtures/projects/rails-3/config/boot.rb", "fixtures/projects/rails-3/config/database.yml", "fixtures/projects/rails-3/config/environment.rb", "fixtures/projects/rails-3/config/environments", "fixtures/projects/rails-3/config/environments/development.rb", "fixtures/projects/rails-3/config/environments/production.rb", "fixtures/projects/rails-3/config/environments/test.rb", "fixtures/projects/rails-3/config/initializers", "fixtures/projects/rails-3/config/initializers/backtrace_silencers.rb", "fixtures/projects/rails-3/config/initializers/inflections.rb", "fixtures/projects/rails-3/config/initializers/mime_types.rb", "fixtures/projects/rails-3/config/initializers/secret_token.rb", "fixtures/projects/rails-3/config/initializers/session_store.rb", "fixtures/projects/rails-3/config/locales", "fixtures/projects/rails-3/config/locales/en.yml", "fixtures/projects/rails-3/config/routes.rb", "fixtures/projects/rails-3/config.ru", "fixtures/projects/rails-3/db", "fixtures/projects/rails-3/db/seeds.rb", "fixtures/projects/rails-3/doc", "fixtures/projects/rails-3/doc/README_FOR_APP", "fixtures/projects/rails-3/Gemfile", "fixtures/projects/rails-3/Gemfile.lock", "fixtures/projects/rails-3/lib", "fixtures/projects/rails-3/lib/tasks", "fixtures/projects/rails-3/log", "fixtures/projects/rails-3/log/development.log", "fixtures/projects/rails-3/log/production.log", "fixtures/projects/rails-3/log/server.log", "fixtures/projects/rails-3/log/test.log", "fixtures/projects/rails-3/public", "fixtures/projects/rails-3/public/404.html", "fixtures/projects/rails-3/public/422.html", "fixtures/projects/rails-3/public/500.html", "fixtures/projects/rails-3/public/favicon.ico", "fixtures/projects/rails-3/public/images", "fixtures/projects/rails-3/public/images/rails.png", "fixtures/projects/rails-3/public/index.html", "fixtures/projects/rails-3/public/javascripts", "fixtures/projects/rails-3/public/javascripts/application.js", "fixtures/projects/rails-3/public/javascripts/controls.js", "fixtures/projects/rails-3/public/javascripts/dragdrop.js", "fixtures/projects/rails-3/public/javascripts/effects.js", "fixtures/projects/rails-3/public/javascripts/prototype.js", "fixtures/projects/rails-3/public/javascripts/rails.js", "fixtures/projects/rails-3/public/robots.txt", "fixtures/projects/rails-3/public/stylesheets", "fixtures/projects/rails-3/Rakefile", "fixtures/projects/rails-3/README", "fixtures/projects/rails-3/script", "fixtures/projects/rails-3/script/rails", "fixtures/projects/rails-3/test", "fixtures/projects/rails-3/test/fixtures", "fixtures/projects/rails-3/test/functional", "fixtures/projects/rails-3/test/integration", "fixtures/projects/rails-3/test/performance", "fixtures/projects/rails-3/test/performance/browsing_test.rb", "fixtures/projects/rails-3/test/test_helper.rb", "fixtures/projects/rails-3/test/unit", "fixtures/projects/rails-3/vendor", "fixtures/projects/rails-3/vendor/plugins", "fixtures/projects/ruby", "fixtures/projects/ruby/Gemfile", "fixtures/projects/ruby/Gemfile.lock", "fixtures/projects/ruby/Rakefile", "Gemfile", "Gemfile.lock", "hudson.gemspec", "lib", "lib/hudson", "lib/hudson/api.rb", "lib/hudson/cli", "lib/hudson/cli/formatting.rb", "lib/hudson/cli.rb", "lib/hudson/config.rb", "lib/hudson/core_ext", "lib/hudson/core_ext/object", "lib/hudson/core_ext/object/blank.rb", "lib/hudson/hudson-cli.jar", "lib/hudson/hudson.war", "lib/hudson/hudson_version.rb", "lib/hudson/job_config_builder.rb", "lib/hudson/plugins", "lib/hudson/plugins/git.hpi", "lib/hudson/plugins/github.hpi", "lib/hudson/plugins/greenballs.hpi", "lib/hudson/plugins/rake.hpi", "lib/hudson/plugins/ruby.hpi", "lib/hudson/project_scm.rb", "lib/hudson/remote.rb", "lib/hudson/version.rb", "lib/hudson.rb", "Rakefile", "README.md", "spec", "spec/fixtures", "spec/fixtures/ec2_global.config.xml", "spec/fixtures/rails.multi.config.xml", "spec/fixtures/rails.single.config.triggers.xml", "spec/fixtures/rails.single.config.xml", "spec/fixtures/rubygem.config.xml", "spec/fixtures/therubyracer.config.xml", "spec/job_config_builder_spec.rb", "spec/spec_helper.rb", "tasks", "tasks/upgrade.rake"]
15
15
  s.homepage = %q{http://github.com/cowboyd/hudson.rb}
16
16
  s.require_paths = ["lib"]
17
17
  s.rubyforge_project = %q{hudson}
@@ -69,15 +69,13 @@ module Hudson
69
69
  end
70
70
 
71
71
  def self.summary
72
- begin
73
- json = get "/api/json"
74
- cache_base_uri
75
- json
76
- rescue Errno::ECONNREFUSED
77
- false
78
- rescue Errno::EAFNOSUPPORT
79
- false
80
- end
72
+ json = get "/api/json"
73
+ cache_base_uri
74
+ json
75
+ end
76
+
77
+ def self.job_names
78
+ summary["jobs"].map {|job| job["name"]}
81
79
  end
82
80
 
83
81
  # Return hash of job statuses
@@ -50,6 +50,7 @@ module Hudson
50
50
  common_options
51
51
  method_option :"no-build", :desc => "create job without initial build", :type => :boolean, :default => false
52
52
  method_option :override, :desc => "override if job exists", :type => :boolean, :default => false
53
+ method_option :public_scm, :desc => "use public scm URL", :type => :boolean, :default => false
53
54
  method_option :assigned_node, :desc => "only use slave nodes with this label"
54
55
  method_option :template, :desc => "template of job steps (available: #{JobConfigBuilder::VALID_JOB_TEMPLATES.join ','})", :default => 'ruby'
55
56
  def create(project_path)
@@ -66,6 +67,7 @@ module Hudson
66
67
  job_config = Hudson::JobConfigBuilder.new(template) do |c|
67
68
  c.scm = scm.url
68
69
  c.assigned_node = options[:assigned_node] if options[:assigned_node]
70
+ c.public_scm = options[:public_scm]
69
71
  end
70
72
  name = File.basename(FileUtils.pwd)
71
73
  if Hudson::Api.create_job(name, job_config, options)
@@ -123,22 +125,20 @@ module Hudson
123
125
  common_options
124
126
  def list
125
127
  select_hudson_server(options)
126
- if summary = Hudson::Api.summary
127
- unless summary["jobs"].blank?
128
- shell.say "#{@uri} -"
129
- summary["jobs"].each do |job|
130
- color = job['color']
131
- color = 'red' if color == 'red_anime'
132
- color = 'green' if color == 'blue' || color == 'blue_anime'
133
- color = 'yellow' if color == 'grey' || color == 'disabled'
134
- shell.say job['name'], color.to_sym, true
135
- end
136
- shell.say ""
137
- else
138
- display "#{@uri} - no jobs"
128
+ summary = Hudson::Api.summary
129
+ unless summary["jobs"].blank?
130
+ shell.say "#{@uri}:", :bold
131
+ summary["jobs"].each do |job|
132
+ color = job['color']
133
+ bold = color =~ /anime/
134
+ color = 'red' if color == 'red_anime'
135
+ color = 'green' if color == 'blue' || color == 'blue_anime'
136
+ color = 'yellow' if color == 'grey' || color == 'disabled'
137
+ shell.say "* "; shell.say(shell.set_color(job['name'], color.to_sym, bold), nil, true)
139
138
  end
139
+ shell.say ""
140
140
  else
141
- error "#{@uri} - no connection"
141
+ shell.say "#{@uri}: "; shell.say "no jobs", :yellow
142
142
  end
143
143
  end
144
144
 
@@ -153,29 +153,6 @@ module Hudson
153
153
  end
154
154
  end
155
155
 
156
- desc "job name [options]", "display job status"
157
- common_options
158
- def job(name)
159
- select_hudson_server(options)
160
- if job = Hudson::Api.job(name)
161
- require "ap"
162
- ap job
163
- else
164
- error "#{@uri} - no connection"
165
- end
166
- end
167
-
168
- # desc "add_remote name [options]", "manage remote servers (comming sometime to a theater near you)"
169
- # common_options
170
- # def add_remote(name)
171
- # select_hudson_server(options)
172
- # if Hudson::Remote.add_server(name, @uri)
173
- # display "Added remote server '#{name}' for #{@uri}"
174
- # else
175
- # error "Could not add remote server for '#{@uri}'"
176
- # end
177
- # end
178
-
179
156
  desc "help [command]", "show help for hudson or for a specific command"
180
157
  def help(*args)
181
158
  super(*args)
@@ -2,7 +2,7 @@ require "builder"
2
2
 
3
3
  module Hudson
4
4
  class JobConfigBuilder
5
- attr_accessor :scm, :git_branches
5
+ attr_accessor :scm, :git_branches, :public_scm
6
6
  attr_accessor :job_type, :matrix_project
7
7
  attr_accessor :assigned_node
8
8
 
@@ -10,18 +10,20 @@ module Hudson
10
10
 
11
11
  def initialize(options = nil, &block)
12
12
  if options.is_a?(String) || options.is_a?(Symbol)
13
- @job_type = options.to_s
13
+ self.job_type = options.to_s
14
14
  elsif options.is_a?(Hash)
15
- @job_type = options[:job_type].to_s
15
+ self.job_type = options[:job_type].to_s
16
16
  end
17
+
17
18
  yield self
18
- @git_branches ||= ["**"]
19
+
20
+ self.git_branches ||= ["master"]
19
21
  end
20
22
 
21
23
  def builder
22
24
  b = Builder::XmlMarkup.new :indent => 2
23
25
  b.instruct!
24
- b.tag!(matrix_project ? "matrix-project" : "project") do
26
+ b.tag!(matrix_project? ? "matrix-project" : "project") do
25
27
  b.actions
26
28
  b.description
27
29
  b.keepDependencies false
@@ -48,12 +50,14 @@ module Hudson
48
50
  protected
49
51
 
50
52
  def matrix_project?
51
- %w[ruby].include? job_type
53
+ matrix_project ||
54
+ %w[rubygem].include?(job_type)
52
55
  end
53
56
 
54
57
  # <scm class="hudson.plugins.git.GitSCM"> ... </scm>
55
58
  def build_scm(b)
56
59
  if scm && scm =~ /git/
60
+ scm_url = public_scm ? public_only_git_scm(scm) : scm
57
61
  b.scm :class => "hudson.plugins.git.GitSCM" do
58
62
  b.configVersion 1
59
63
  b.remoteRepositories do
@@ -67,7 +71,7 @@ module Hudson
67
71
  b.string "uploadpack"
68
72
  b.string "git-upload-pack"
69
73
  b.string "url"
70
- b.string public_only_git_scm(scm) # FIXME remove when we have deploy keys
74
+ b.string scm_url
71
75
  b.string "tagopt"
72
76
  b.string
73
77
  end
@@ -113,7 +117,8 @@ module Hudson
113
117
  end
114
118
  end
115
119
  end
116
-
120
+
121
+ # TODO
117
122
  def build_axes(b)
118
123
  b.axes
119
124
  end
@@ -124,7 +129,7 @@ module Hudson
124
129
  def build_steps(b)
125
130
  b.builders do
126
131
  raise InvalidTemplate unless VALID_JOB_TEMPLATES.include?(job_type)
127
- if job_type == "rails3"
132
+ if job_type == "rails" || job_type == "rails3"
128
133
  build_shell_step b, "bundle install"
129
134
  build_ruby_step b, <<-RUBY.gsub(/^ /, '')
130
135
  unless File.exist?("config/database.yml")
@@ -136,10 +141,7 @@ module Hudson
136
141
  RUBY
137
142
  build_shell_step b, "bundle exec rake db:schema:load"
138
143
  build_shell_step b, "bundle exec rake"
139
- elsif job_type == "ruby"
140
- build_shell_step b, "bundle install"
141
- build_shell_step b, "bundle exec rake"
142
- elsif job_type == "rubygem"
144
+ else
143
145
  build_shell_step b, "bundle install"
144
146
  build_shell_step b, "bundle exec rake"
145
147
  end
@@ -1,3 +1,3 @@
1
1
  module Hudson
2
- VERSION = "0.3.0.beta.13"
2
+ VERSION = "0.3.0.beta.14"
3
3
  end
@@ -24,7 +24,7 @@
24
24
  </remoteRepositories>
25
25
  <branches>
26
26
  <hudson.plugins.git.BranchSpec>
27
- <name>**</name>
27
+ <name>master</name>
28
28
  </hudson.plugins.git.BranchSpec>
29
29
  </branches>
30
30
  <localBranch/>
@@ -47,14 +47,12 @@
47
47
  <concurrentBuild>false</concurrentBuild>
48
48
  <axes/>
49
49
  <builders>
50
- <hudson.plugins.rake.Rake>
51
- <rakeInstallation>(Default)</rakeInstallation>
52
- <rakeFile/>
53
- <rakeLibDir/>
54
- <rakeWorkingDir/>
55
- <tasks>features</tasks>
56
- <silent>false</silent>
57
- </hudson.plugins.rake.Rake>
50
+ <hudson.tasks.Shell>
51
+ <command>bundle install</command>
52
+ </hudson.tasks.Shell>
53
+ <hudson.tasks.Shell>
54
+ <command>bundle exec rake</command>
55
+ </hudson.tasks.Shell>
58
56
  </builders>
59
57
  <publishers/>
60
58
  <buildWrappers/>
@@ -49,18 +49,17 @@ describe Hudson::JobConfigBuilder do
49
49
  end
50
50
  end
51
51
 
52
- describe "temporary:" do
53
- describe "convert git@ into git:// until we have deploy keys" do
54
- before do
55
- @config = Hudson::JobConfigBuilder.new(:rails) do |c|
56
- c.scm = "git@codebasehq.com:mocra/misc/mocra-web.git"
57
- c.git_branches = %w[master]
58
- end
59
- end
60
- it "builds config.xml" do
61
- config_xml("rails", "single").should == @config.to_xml
52
+ describe "public_scm = true => convert git@ into git:// until we have deploy keys" do
53
+ before do
54
+ @config = Hudson::JobConfigBuilder.new(:rails) do |c|
55
+ c.scm = "git@codebasehq.com:mocra/misc/mocra-web.git"
56
+ c.git_branches = %w[master]
57
+ c.public_scm = true
62
58
  end
63
59
  end
60
+ it "builds config.xml" do
61
+ config_xml("rails", "single").should == @config.to_xml
62
+ end
64
63
  end
65
64
 
66
65
  end
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hudson
3
3
  version: !ruby/object:Gem::Version
4
- hash: 62196361
4
+ hash: 62196367
5
5
  prerelease: true
6
6
  segments:
7
7
  - 0
8
8
  - 3
9
9
  - 0
10
10
  - beta
11
- - 13
12
- version: 0.3.0.beta.13
11
+ - 14
12
+ version: 0.3.0.beta.14
13
13
  platform: ruby
14
14
  authors:
15
15
  - Charles Lowell
@@ -18,7 +18,7 @@ autorequire:
18
18
  bindir: bin
19
19
  cert_chain: []
20
20
 
21
- date: 2010-10-29 00:00:00 -07:00
21
+ date: 2010-11-01 00:00:00 -07:00
22
22
  default_executable:
23
23
  dependencies:
24
24
  - !ruby/object:Gem::Dependency
@@ -209,7 +209,6 @@ files:
209
209
  - features/launch_server.feature
210
210
  - features/listing_jobs.feature
211
211
  - features/manage_jobs.feature
212
- - features/manage_remote_servers.feature
213
212
  - features/manage_slave_nodes.feature
214
213
  - features/step_definitions/common_steps.rb
215
214
  - features/step_definitions/fixture_project_steps.rb
@@ -1,36 +0,0 @@
1
- @wip
2
- Feature: Managing remote servers
3
- In order to reduce cost of referencing remote servers by explicit --host/--port options
4
- As a user
5
- I want a directory of remote servers I frequently use
6
-
7
- Background:
8
- Given I have a Hudson server running
9
- And the Hudson server has no current jobs
10
-
11
- Scenario: No remote servers
12
- When I run local executable "hudson" with arguments "list"
13
- Then I should see "Either use --host or add remote servers."
14
-
15
- Scenario: Add a remote server
16
- When I run local executable "hudson" with arguments "add_remote test --host localhost --port 3010"
17
- And I run local executable "hudson" with arguments "list"
18
- Then I should not see "Either use --host or add remote servers."
19
- And I should see "test [localhost:3010] - no jobs"
20
-
21
- Scenario: Add a few remote servers
22
- When I run local executable "hudson" with arguments "add_remote test --host localhost --port 3010"
23
- And I run local executable "hudson" with arguments "add_remote another --host localhost --port 4000"
24
- And I run local executable "hudson" with arguments "list"
25
- Then I should not see "Either use --host or add remote servers."
26
- And I should see "test [localhost:3010] - no jobs"
27
- And I should see "another [localhost:3011] - no connection"
28
-
29
- Scenario: Add a remote server and access by abbreviation
30
- When I run local executable "hudson" with arguments "add_remote test --host localhost --port 3010"
31
- And I run local executable "hudson" with arguments "add_remote another --host another.host"
32
- And I run local executable "hudson" with arguments "list --server local"
33
- Then I should not see "Either use --host or add remote servers."
34
- And I should see "test [localhost:3010] - no jobs"
35
- And I should not see "another"
36
-