Skip to content

Commit 7311d07

Browse files
committed
Avoid new process in CI regression test
1 parent 005bb58 commit 7311d07

3 files changed

Lines changed: 4 additions & 17 deletions

File tree

tests/only_connect/only_connect.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ if ($ExitCode -ne 0) {
6161
if (Test-Path $OutputFile -PathType Leaf) {
6262
Write-Host "Found output file: $OutputFile"
6363
} else {
64-
Write-Host "Output file doesn't exist: $OutputFile"
64+
Write-Error "FAILED: output file doesn't exist: $OutputFile"
6565
}
6666

6767
# Compare the output file to the expected output.

tests/prove_fuzzing_capability_cmp_inline_1/prove_fuzzing_capability_cmp_inline_1.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ if ($ExitCode -ne 0) {
6767
if (Test-Path $OutputFile -PathType Leaf) {
6868
Write-Host "Found output file: $OutputFile"
6969
} else {
70-
Write-Host "Output file doesn't exist: $OutputFile"
70+
Write-Error "FAILED: output file doesn't exist: $OutputFile"
7171
}
7272

7373
# Read the output file produced.

tests/prove_fuzzing_capability_memcmp_1/prove_fuzzing_capability_memcmp_1.ps1

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -56,26 +56,13 @@ if (Test-Path $TargetPath -PathType Leaf) {
5656
$OutputFile = "digraph.txt"
5757
Remove-Item $OutputFile -ErrorAction Ignore
5858

59-
# Run navigator.exe, and get the process ID.
6059
Write-Host "Executing navigator..."
61-
$process = Start-Process ".\target\debug\navigator.exe" -ArgumentList "--dynamorio-bin-dir=$DynamoBin --mutator-lib=$MutatorLib --coverage-module=$Target --target-module=$Target --nargs=2 --target-path=$TargetPath --target-opts=$TargetOpts --fuzz-iterations=$FuzzIterations --parallel=$Parallel --protocol=$Protocol" -RedirectStandardOutput "stdout.log" -RedirectStandardError "stderr.log" -PassThru -Wait
62-
63-
# Stream output live
64-
Get-Content "stdout.log" -Wait &
65-
Get-Content "stderr.log" -Wait &
66-
67-
$process.WaitForExit()
68-
69-
$ExitCode = $process.ExitCode
70-
71-
if ($ExitCode -ne 0) {
72-
Write-Error "Test app failed with exit code: $ExitCode"
73-
}
60+
.\target\debug\navigator.exe --dynamorio-bin-dir=$DynamoBin --mutator-lib=$MutatorLib --coverage-module=$Target --target-module=$Target --nargs=2 --target-path=$TargetPath --target-opts=$TargetOpts --fuzz-iterations=$FuzzIterations --parallel=$Parallel --protocol=$Protocol
7461

7562
if (Test-Path $OutputFile -PathType Leaf) {
7663
Write-Host "Found output file: $OutputFile"
7764
} else {
78-
Write-Host "Output file doesn't exist: $OutputFile"
65+
Write-Error "FAILED: output file doesn't exist: $OutputFile"
7966
}
8067

8168
# Read the output file produced.

0 commit comments

Comments
 (0)