testTrapSubprocessWithEnvp

fun testTrapSubprocessWithEnvp(testPath: String? = null, envp: List<String>? = null, usecTimeout: <Error class: unknown class>, testFlags: TestSubprocessFlags)

Respawns the test program to run only @test_path in a subprocess with the given @envp environment.

This can be used for a test case that might not return, or that might abort.

If @test_path is null then the same test is re-run in a subprocess. You can use g_test_subprocess() to determine whether the test is in a subprocess or not.

Since

2.80

Parameters

testPath

Test to run in a subprocess

envp

Environment to run the test in, or null to inherit the parent’s environment. This must be in the GLib filename encoding.

usecTimeout

Timeout for the subprocess test in micro seconds.

testFlags

Flags to modify subprocess behaviour.