Sha256: ce69116e312e6a2f0d3f38089deb211bae580c425141416035f432bb048363d4

Contents?: true

Size: 784 Bytes

Versions: 11

Compression:

Stored size: 784 Bytes

Contents

require 'bundler'
require 'tmpdir'

tmpdir = Dir.mktmpdir
File.open(tmpdir + '/Gemfile', 'w') do |f|
  f << File.read('Gemfile')
  f << File.read('test/Gemfile')
end
Dir.chdir tmpdir do
  Bundler.setup
end

$LOAD_PATH.unshift 'lib'

require 'iron_worker_ng'
require_relative 'test/iron_io_config.rb'

client = IronWorkerNG::Client.new

code = IronWorkerNG::Code::Ruby.new do
  exec 'ng_tests_worker.rb'
  gemfile 'Gemfile'
  gemfile 'test/Gemfile'

  Dir.glob('*').each do |p|
    dir  p, 'iwng' if File.directory?  p
    file p, 'iwng' if File.file? p
  end

  iron_io_config 'iwng'
end

puts client.codes.create(code)

puts code.create_zip

task = client.tasks.create 'NgTestsWorker', args: $*.join(' ')

client.tasks.wait_for task.id

puts '-' * 80

puts client.tasks.log(task.id)

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
iron_worker_ng-0.7.4 remote_test.rb
iron_worker_ng-0.7.3 remote_test.rb
iron_worker_ng-0.7.2 remote_test.rb
iron_worker_ng-0.7.1 remote_test.rb
iron_worker_ng-0.7.0 remote_test.rb
iron_worker_ng-0.6.8 remote_test.rb
iron_worker_ng-0.6.7 remote_test.rb
iron_worker_ng-0.6.6 remote_test.rb
iron_worker_ng-0.6.5 remote_test.rb
iron_worker_ng-0.6.4 remote_test.rb
iron_worker_ng-0.6.3 remote_test.rb