Skip to content

Commit 5136048

Browse files
committed
extend skip section
The day light offset is calculated based on the system TZ, so with an unsuitable one there's no way to workaround the false positives.
1 parent f99bf70 commit 5136048

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

ext/openssl/tests/openssl_x509_parse_basic.phpt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,14 @@ openssl_x509_parse() tests
33
--SKIPIF--
44
<?php if (!extension_loaded("openssl")) print "skip";
55
if (OPENSSL_VERSION_NUMBER < 0x10000000) die("skip Output requires OpenSSL 1.0");
6+
if(substr(PHP_OS, 0, 3) == 'WIN') {
7+
$exp = "W. Europe Standard Time";
8+
$cmd = "powershell -command [System.TimeZoneInfo]::Local.Id";
9+
$r = trim(shell_exec($cmd));
10+
if ($exp !== $r) {
11+
die("skip expect '$exp', got '$r'");
12+
}
13+
}
614
?>
715
--FILE--
816
<?php

0 commit comments

Comments
 (0)