Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

test fixes #51

Merged
merged 3 commits into from

1 participant

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on May 24, 2012
  1. @romand

    fixing test_java_worker

    romand authored
  2. @romand

    fixing test_basic

    romand authored
  3. @romand

    fix test_quick_run

    romand authored
This page is out of date. Refresh to see the latest.
View
1  test/test_basic.rb
@@ -3,6 +3,7 @@
class BasicTest < IWNGTest
def test_basic
code = IronWorkerNG::Code::Ruby.new
+ code.name('test_basic')
code.merge_exec(File.dirname(__FILE__) + '/hello.rb')
client.codes_create(code)
task_id = client.tasks_create('test_basic').id
View
3  test/test_java_worker.rb
@@ -3,8 +3,7 @@
class JavaWorkerTest < IWNGTest
def test_hello
- code = IronWorkerNG::Code.create do
- runtime 'java'
+ code = IronWorkerNG::Code::Java.new do
name 'JavaHello'
exec 'test/hello.jar'
end
View
7 test/test_quick_run.rb
@@ -30,11 +30,12 @@ def test_scheduler_quick
start = (Time.now + 10).utc
- id = client.schedules.create('scheduler_quick', :start_at => start).id
- sleep 5 until client.schedules.get(id).status == 'complete'
+ id = client.schedules.create('test_schedule', :start_at => start).id
+ sleep 5 while client.schedules.get(id).status == 'scheduled'
+ assert_equal 'complete', client.schedules.get(id).status
task = get_all_tasks.
- keep_if{ |t| t.code_name == 'scheduler_quick' }.
+ keep_if{ |t| t.code_name == 'test_schedule' }.
max_by{ |t| Time.parse t.start_time }
client.tasks.wait_for task.id
Something went wrong with that request. Please try again.