Skip to content

Commit

Permalink
Test case for disown.
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewchambers committed May 18, 2019
1 parent 8b1046f commit a74a820
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/cases/0013-disownjob/case.janet
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
(import sh)
(sh/disown-job (sh/$ sh -c "sleep 0.3 ; touch success.txt" &))
(os/exit 0)
12 changes: 12 additions & 0 deletions test/cases/0013-disownjob/run
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#! /bin/sh
set -eux

janetsh $TEST_CASE/case.janet
if test test -f success.txt
then
exit 1
fi
while ! test -f success.txt
do
sleep 0.1
done

0 comments on commit a74a820

Please sign in to comment.