mirror of
https://github.com/troglobit/libite.git
synced 2026-10-01 05:22:34 +07:00
Running the tests in a Debian container seem to be taking way too long. Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
24 lines
407 B
C
24 lines
407 B
C
#include "check.h"
|
|
|
|
#define file "/tmp/runbg.txt"
|
|
|
|
int main(void)
|
|
{
|
|
char *cmd[] = {
|
|
"sh", "-c", "echo 'hello world' > " file, NULL
|
|
};
|
|
|
|
erase(file);
|
|
test(runbg(cmd, 100000), "Calling runbg");
|
|
|
|
if (test(fexist(file), "Verifying %s does not yet exist", file))
|
|
return 1;
|
|
|
|
test(sleep(1), "Waiting for runbg");
|
|
|
|
if (test(!fexist(file), "Verifying %s has been created", file))
|
|
return 1;
|
|
|
|
return 0;
|
|
}
|