X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/2e437823d2d19edf5c6be392f3604a499308cd6e..d2bb622dce5e765e55942e4da6348f949883d9fc:/sdk/cli/test/test_crunch-job.rb diff --git a/sdk/cli/test/test_crunch-job.rb b/sdk/cli/test/test_crunch-job.rb index 0fbff2e6de..c1465d8d69 100644 --- a/sdk/cli/test/test_crunch-job.rb +++ b/sdk/cli/test/test_crunch-job.rb @@ -1,3 +1,7 @@ +# Copyright (C) The Arvados Authors. All rights reserved. +# +# SPDX-License-Identifier: Apache-2.0 + require 'minitest/autorun' class TestCrunchJob < Minitest::Test @@ -8,6 +12,7 @@ class TestCrunchJob < Minitest::Test JOBSPEC = { grep_local: { + owner_uuid: 'zzzzz-j7d0g-it30l961gq3t0oi', script: 'grep', script_version: 'master', repository: File.absolute_path('../../../..', __FILE__), @@ -91,10 +96,18 @@ class TestCrunchJob < Minitest::Test tryjobrecord j, binstubs: ['clean_fail'] end assert_match /Failing mount stub was called/, err - assert_match /clean work dirs: exit 44\n$/, err + assert_match /clean work dirs: exit 44\n.*Transient failure.* exiting 93\n(.*arv_put.*INFO.*\n)?$/, err assert_equal SPECIAL_EXIT[:EX_RETRY_UNLOCKED], $?.exitstatus end + def test_output_collection_owner_uuid + j = jobspec :grep_local + out, err = capture_subprocess_io do + tryjobrecord j, binstubs: ['arv-mount', 'output_coll_owner'] + end + assert_match /owner_uuid: #{j['owner_uuid']}/, err + end + def test_docker_image_missing skip 'API bug: it refuses to create this job in Running state' out, err = capture_subprocess_io do @@ -111,7 +124,7 @@ class TestCrunchJob < Minitest::Test out, err = capture_subprocess_io do j = jobspec :grep_local j[:script_version] = bogus_version - tryjobrecord j + tryjobrecord j, binstubs: ['arv-mount'] end assert_match /'#{bogus_version}' not found, giving up/, err assert_jobfail $?