Skip to content

Commit 54c4cdc

Browse files
committed
travis: use VM for now
Attaching even to a children process is broken in travis's Docker. Use VM until travis-ci/travis-ci#9033 is fixed. Signed-off-by: Pavel Boldin <[email protected]>
1 parent 20d7b04 commit 54c4cdc

File tree

3 files changed

+19
-3
lines changed

3 files changed

+19
-3
lines changed

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ script: make tests
33
language: c
44

55
dist: trusty
6-
sudo: false
6+
sudo: required
77

88
addons:
99
apt:

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
1+
#dummy
22

33
all: src
44

tests/run_tests.sh

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,23 @@
33
set -e
44

55
wait_file() {
6-
while ! test -s $1; do sleep ${2-1}; done
6+
local file="$1"
7+
local pause="${2-1}"
8+
local i=0
9+
local timeout=60
10+
11+
while test $i -lt $timeout; do
12+
if test -s $file; then
13+
break
14+
fi
15+
sleep $pause
16+
i=$((i + 1))
17+
done
18+
19+
if test $i -eq $timeout; then
20+
return 1
21+
fi
22+
723
return 0
824
}
925

0 commit comments

Comments
 (0)