From: anton Date: Tue, 22 Nov 2022 10:40:10 +0000 (+0000) Subject: Be more helpful and provide details on what the time conversion tests X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=e1da3696d0d476b9cc018f3bf48d62738cac858c;p=openbsd Be more helpful and provide details on what the time conversion tests need in order to run. Also, output the expected SKIPPED string as dictated by bsd.regress.mk. --- diff --git a/regress/lib/libc/time/time_conversion/timetest.c b/regress/lib/libc/time/time_conversion/timetest.c index 77a7cbe1151..075d7e4ad59 100644 --- a/regress/lib/libc/time/time_conversion/timetest.c +++ b/regress/lib/libc/time/time_conversion/timetest.c @@ -1,4 +1,4 @@ -/* $OpenBSD: timetest.c,v 1.2 2022/11/09 18:11:45 beck Exp $ */ +/* $OpenBSD: timetest.c,v 1.3 2022/11/22 10:40:10 anton Exp $ */ /* * Copyright (c) 2022 Bob Beck @@ -1826,14 +1826,11 @@ int main() { int verbose = 0; struct stat sb; - if (stat("/usr/share/zoneinfo/posix", &sb) == -1) { - fprintf(stderr, "WARNING: /usr/share/zoneinfo/posix not" - "present,\nCreate posix time zones to run this test.\n"); - exit(0); - } - if (stat("/usr/share/zoneinfo/right", &sb) == -1) { - fprintf(stderr, "WARNING: /usr/share/zoneinfo/right not" - "present,\nCreate right time zones to run this test.\n"); + if (stat("/usr/share/zoneinfo/posix", &sb) == -1 || + stat("/usr/share/zoneinfo/right", &sb) == -1) { + fprintf(stderr, "POSIX time zones missing, run the following command:\n\n" + "\tmake -C ../../../../../share/zoneinfo other_two\n\n" + "SKIPPED\n"); exit(0); }