From 2b171cff67ecf93f150ef1299282c515dfea8ec6 Mon Sep 17 00:00:00 2001 From: ZyX Date: Sat, 18 Jan 2014 01:59:19 +0400 Subject: [PATCH] Try to workaround problems with last line in travis --- tests/test_shells/bash.ok | 2 -- tests/test_shells/input.bash | 1 + tests/test_shells/input.zsh | 1 + tests/test_shells/postproc.py | 2 ++ tests/test_shells/zsh.ok | 1 - 5 files changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/test_shells/bash.ok b/tests/test_shells/bash.ok index 00824923..a88c8091 100644 --- a/tests/test_shells/bash.ok +++ b/tests/test_shells/bash.ok @@ -8,5 +8,3 @@   HOSTNAME  USER   BRANCH  ⋯  tests  shell  3rd  1  1  kill `cat pid` ; sleep 1s [1]+ Terminated bash -c "echo \$\$>pid ; while true ; do sleep 0.1s ; done"   HOSTNAME  USER   BRANCH  ⋯  tests  shell  3rd  false -  HOSTNAME  USER   BRANCH  ⋯  tests  shell  3rd  1  exit -exit diff --git a/tests/test_shells/input.bash b/tests/test_shells/input.bash index 9b97dac0..954d6e1a 100644 --- a/tests/test_shells/input.bash +++ b/tests/test_shells/input.bash @@ -11,4 +11,5 @@ bash -c "echo \$\$>pid ; while true ; do sleep 0.1s ; done" & false kill `cat pid` ; sleep 1s false +true is the last line exit diff --git a/tests/test_shells/input.zsh b/tests/test_shells/input.zsh index a19bdff4..bcd1a421 100644 --- a/tests/test_shells/input.zsh +++ b/tests/test_shells/input.zsh @@ -12,4 +12,5 @@ bash -c "echo \$\$>pid ; while true ; do sleep 0.1s ; done" & false kill `cat pid` ; sleep 1s false +true is the last line exit diff --git a/tests/test_shells/postproc.py b/tests/test_shells/postproc.py index 5ee721c9..ae2e887a 100755 --- a/tests/test_shells/postproc.py +++ b/tests/test_shells/postproc.py @@ -24,6 +24,8 @@ with codecs.open(fname, 'r', encoding='utf-8') as R: if not found_cd: found_cd = ('cd tests/shell/3rd' in line) continue + if 'true is the last line' in line: + break line = line.translate({ ord('\r'): None }) diff --git a/tests/test_shells/zsh.ok b/tests/test_shells/zsh.ok index 9a7b0502..47eda0f2 100644 --- a/tests/test_shells/zsh.ok +++ b/tests/test_shells/zsh.ok @@ -9,4 +9,3 @@   HOSTNAME  USER   BRANCH  ⋯  tests  shell  3rd  1  1  kill `cat pid` ; sleep 1s [1] + terminated bash -c "echo \$\$>pid ; while true ; do sleep 0.1s ; done"   HOSTNAME  USER   BRANCH  ⋯  tests  shell  3rd  false -  HOSTNAME  USER   BRANCH  ⋯  tests  shell  3rd  1  exit