Skip to content

Commit a129b00

Browse files
committedAug 19, 2019
Use a wrapper script to make sure things still get printed while kcov is runing, to keep travis from bailing
1 parent 2d43cfd commit a129b00

File tree

2 files changed

+17
-2
lines changed

2 files changed

+17
-2
lines changed
 

‎.travis.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ matrix:
2424
before_install:
2525
- sudo add-apt-repository ppa:sivakov512/kcov -y
2626
- sudo apt-get update -q
27-
- sudo apt-get install kcov
27+
- sudo apt-get install kcov nodejs
2828

2929
script: |
3030
cargo install cargo-kcov -f
31-
cargo kcov -v
31+
node keepalive.js cargo kcov -v
3232
bash <(curl -s https://codecov.io/bash)
3333
3434
- language: node_js

‎keepalive.js

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
const { spawn } = require('child_process');
2+
3+
const toRun = process.argv.slice(2);
4+
if (toRun.length) {
5+
const cmd = toRun[0];
6+
const args = toRun.slice(1);
7+
8+
const proc = spawn(cmd, args);
9+
10+
proc.stdout.on('data', (data) => process.stdout.write(data));
11+
proc.stderr.on('data', (data) => process.stderr.write(data));
12+
proc.on('close', (code) => process.exit(code));
13+
14+
setInterval(() => console.log('Still running...'), 30000);
15+
}

0 commit comments

Comments
 (0)
Please sign in to comment.