Fix travis build: on travis “Terminated…” message is truncated

This commit is contained in:
ZyX 2014-07-20 02:00:56 +04:00
parent 5425c06476
commit 855e33274e
2 changed files with 6 additions and 1 deletions

View File

@ -7,7 +7,7 @@
[1] PID
  HOSTNAME  USER   BRANCH  ⋯  tests  shell  3rd  1  false
  HOSTNAME  USER   BRANCH  ⋯  tests  shell  3rd  1  1  kill `cat pid` ; sleep 1
[1] + Terminated bash -c "echo \$\$>pid ; while true ; do sleep 0.1s ; done"
[1] + Terminated bash -c ...
  HOSTNAME  USER   BRANCH  ⋯  tests  shell  3rd  cd "$DIR1"
  HOSTNAME  USER   BRANCH  ⋯  shell  3rd  ^[[32m  cd ../"$DIR2"
  HOSTNAME  USER   BRANCH  ⋯  shell  3rd  ^H  cd ../'\[\]'

View File

@ -48,4 +48,9 @@ with codecs.open(fname, 'r', encoding='utf-8') as R:
line = line[start:end] + '\033[0m\n'
except ValueError:
line = ''
elif shell == 'mksh':
# Output is different in travis: on my machine I see full
# command, in travis it is truncated just after `true`.
if line.startswith('[1] + Terminated'):
line = '[1] + Terminated bash -c ...\n'
W.write(line)