xref: /PHP-8.1/ext/com_dotnet/tests/bug77578.phpt (revision 139a73b5)
1--TEST--
2Bug #77578 (Crash when php unload)
3--EXTENSIONS--
4com_dotnet
5--FILE--
6<?php
7// To actually be able to verify the crash during shutdown on Windows, we have
8// to execute a PHP subprocess, and check its exit status.
9$php = PHP_BINARY;
10$ini = php_ini_loaded_file();
11$iniopt = $ini ? "-c $ini" : '';
12$command = "$php $iniopt -d extension=com_dotnet -d com.autoregister_typelib=1 -r \"new COM('WbemScripting.SWbemLocator');\"";
13exec($command, $output, $status);
14var_dump($output, $status);
15?>
16--EXPECT--
17array(0) {
18}
19int(0)
20