Added tests for nested subprocesses