spec/support/fake_api.rb in travis-1.1.3 vs spec/support/fake_api.rb in travis-1.2.0
- old
+ new
@@ -645,12 +645,12 @@
get '/config' do
{"config" => {"host" => "travis-ci.org"}}.to_json
end
- get '/artifacts/3168318' do
- {"artifact"=>
+ get '/logs/3168318' do
+ {"log"=>
{"id"=>3168318,
"job_id"=>4125096,
"type"=>"Log",
"body"=>
"$ export GEM=railties\n"}}.to_json
@@ -681,9 +681,29 @@
"last_build_finished_at"=>nil}}.to_json
end
get '/repos/891/key' do
{"key"=>RAILS_KEY}.to_json
+ end
+
+ get '/workers/' do
+ {"workers"=>
+ [{'id' => 'foo',
+ 'name' => 'ruby-1',
+ 'host' => 'ruby-1.worker.travis-ci.org',
+ 'state' => 'ready',
+ 'payload' => {
+ "job"=>{"id"=>4125096},
+ "repo"=>{"id"=>891}}}]}.to_json
+ end
+
+ get '/workers/foo' do
+ {"worker"=>
+ {'id' => 'foo',
+ 'name' => 'ruby-1',
+ 'host' => 'ruby-1.worker.travis-ci.org',
+ 'state' => 'ready',
+ 'payload' => nil}}.to_json
end
post '/requests' do
$params = params
"{}"