Commit cf92dfca authored by Kirill Smelkov's avatar Kirill Smelkov

t/tfault-run: Clear state from previous run before starting

Otherwise, if previous test.fault failed, tfault-run fails to start, e.g.

    >>> test.fault
    $ make test.fault # MAKEFLAGS=-j1
    x86_64-linux-gnu-gcc -pthread -g -Wall -D_GNU_SOURCE -std=gnu99 -fplan9-extensions -Wno-declaration-after-statement -Wno-error=declaration-after-statement  -Iinclude -I3rdparty/ccan -I3rdparty/include   bigfile/tests/tfault.c lib/bug.c lib/utils.c 3rdparty/ccan/ccan/tap/tap.c  -o bigfile/tests/tfault.t
    t/tfault-run bigfile/tests/tfault.t faultr on_pagefault
    mkdir: cannot create directory ‘t/tfault-run.faultr’: File exists
    Makefile:186: recipe for target 'faultr.tfault' failed
    make: *** [faultr.tfault] Error 1
    rm bigfile/tests/tfault.t
    error   test.fault      0.433s  # 1t 1e 0f 0s
parent 19de3fe2
......@@ -17,6 +17,7 @@ mustdie=$3
rm -rf "$workdir"
mkdir "$workdir"
cd "$workdir"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment