mirror of
https://github.com/openssl/openssl.git
synced 2024-12-21 06:09:35 +08:00
a7da4d488d
When using `HARNESS_JOBS` to run the tests in parallel, no matter the level of parallelism that can be used, the monolithic `test_fuzz` takes a long time to run, conditioning the duration of the whole build. This commit splits the single `test_fuzz` recipe into separate recipes for each fuzzer. The previous mechanism to select individual fuzz tests using the `FUZZ_TESTS` environment variable is also dropped (and documentation updated). Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/13307)
27 lines
678 B
Perl
27 lines
678 B
Perl
# Copyright 2016-2020 The OpenSSL Project Authors. All Rights Reserved.
|
|
#
|
|
# Licensed under the Apache License 2.0 (the "License"). You may not use
|
|
# this file except in compliance with the License. You can obtain a copy
|
|
# in the file LICENSE in the source distribution or at
|
|
# https://www.openssl.org/source/license.html
|
|
|
|
use strict;
|
|
use warnings;
|
|
|
|
use OpenSSL::Glob;
|
|
use OpenSSL::Test qw/:DEFAULT srctop_dir/;
|
|
|
|
sub fuzz_ok {
|
|
die "Only one argument accepted" if scalar @_ != 1;
|
|
|
|
my $f = $_[0];
|
|
my $d = srctop_dir('fuzz', 'corpora', $f);
|
|
|
|
SKIP: {
|
|
skip "No directory $d", 1 unless -d $d;
|
|
ok(run(fuzz(["$f-test", $d])), "Fuzzing $f");
|
|
}
|
|
}
|
|
|
|
1;
|