test: Auto-skip object-storage test cases if run from shell

In case an sstable unit test case is run individually, it would fail
with exception saying that S3_... environment is not set. It's better to
skip the test-case rather than fail. If someone wants to run it from
shell, it will have to prepare S3 server (minio/AWS public bucket) and
provide proper environment for the test-case.

refs: #13569

Signed-off-by: Pavel Emelyanov <xemul@scylladb.com>

Closes #13755
This commit is contained in:
Pavel Emelyanov
2023-05-03 11:46:02 +03:00
committed by Botond Dénes
parent e7c9ca560b
commit fe70333c19
6 changed files with 20 additions and 4 deletions

View File

@@ -1032,6 +1032,7 @@ async def run_test(test: Test, options: argparse.Namespace, gentle_kill=False, e
# TMPDIR env variable is used by any seastar/scylla
# test for directory to store test temporary data.
TMPDIR=os.path.join(options.tmpdir, test.mode),
SCYLLA_TEST_ENV='yes',
**env,
),
preexec_fn=os.setsid,