Skip to content

Commit a10b864

Browse files
committed
Tests: added has_feature check for build with sanitizers.
1 parent 32f98be commit a10b864

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

lib/Test/Nginx.pm

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -299,6 +299,13 @@ sub has_feature($) {
299299
return !$@;
300300
}
301301

302+
if ($feature eq 'sanitizer') {
303+
$self->{_configure_args} = `$NGINX -V 2>&1`
304+
if !defined $self->{_configure_args};
305+
306+
return $self->{_configure_args} =~ /[-\/]fsanitize=/;
307+
}
308+
302309
return 0;
303310
}
304311

ssl_provider_keys.t

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ my $t = Test::Nginx->new()->has(qw/http proxy http_ssl openssl:3/)
2929
->has_daemon('openssl')->has_daemon('softhsm2-util');
3030

3131
plan(skip_all => 'not yet') unless $t->has_version('1.29.0');
32+
plan(skip_all => 'not compatible with sanitizers')
33+
if $t->has_feature('sanitizer');
3234

3335
$t->write_file_expand('nginx.conf', <<'EOF');
3436

0 commit comments

Comments
 (0)