@Test("Multi-argument test. Each argument is run in a different thread.",
arguments: [Log.Level.diagnostic, .verbose, .debug, .info])
func multiArgumentTest(level: Log.Level) async throws
{
for subsystem in Self.subsystems {
Subprocess.expect([
"usr/bin/log",
"config",
"--subsystem", subsystem
])
}
...
try Subprocess.verify()
}
This code will crash on
MockSubprocessDependencyBuilder.swift:123when separate threads try to add a new mock to themocksarray.