From 9eb221b2d291fd40d9467517bb7995d8a09f44ce Mon Sep 17 00:00:00 2001 From: teor Date: Fri, 24 May 2019 12:06:07 +1000 Subject: Travis: make stem log a controller trace, and tail stem's tor log In Travis, make stem log a controller trace to the console. And tail stem's tor log after failure. Closes ticket 30591. --- .travis.yml | 4 ++-- changes/ticket30591 | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) create mode 100644 changes/ticket30591 diff --git a/.travis.yml b/.travis.yml index 1b04fa48fc..1d6c838bfc 100644 --- a/.travis.yml +++ b/.travis.yml @@ -211,7 +211,7 @@ script: ## We run `make check` because that's what https://jenkins.torproject.org does. - if [[ "$DISTCHECK" == "" && "$TEST_STEM" == "" ]]; then make check; fi ## Diagnostic for bug 29437: kill stem if it hangs for 15 minutes - - if [[ "$TEST_STEM" != "" ]]; then make src/app/tor; timelimit -p -t 540 -s USR1 -T 30 -S ABRT python3 "$STEM_SOURCE_DIR"/run_tests.py --tor src/app/tor --integ --log notice --target RUN_ALL; fi + - if [[ "$TEST_STEM" != "" ]]; then make src/app/tor; timelimit -p -t 540 -s USR1 -T 30 -S ABRT python3 "$STEM_SOURCE_DIR"/run_tests.py --tor src/app/tor --integ --log TRACE --target RUN_ALL; fi - if [[ "$DISTCHECK" != "" && "$TEST_STEM" == "" ]]; then make distcheck DISTCHECK_CONFIGURE_FLAGS="$CONFIGURE_FLAGS"; fi ## If this build was one that produced coverage, upload it. - if [[ "$COVERAGE_OPTIONS" != "" ]]; then coveralls -b . --exclude src/test --exclude src/trunnel --gcov-options '\-p' || echo "Coverage failed"; fi @@ -225,7 +225,7 @@ after_failure: ## `make distcheck` puts it somewhere different. - if [[ "$DISTCHECK" != "" ]]; then make show-distdir-testlog || echo "make failed"; fi - if [[ "$DISTCHECK" != "" ]]; then make show-distdir-core || echo "make failed"; fi - - if [[ "$TEST_STEM" != "" ]]; then cat "$STEM_SOURCE_DIR"/test/data/tor_log || echo "cat failed"; fi + - if [[ "$TEST_STEM" != "" ]]; then tail -1000 "$STEM_SOURCE_DIR"/test/data/tor_log || echo "tail failed"; fi before_cache: ## Delete all gcov files. diff --git a/changes/ticket30591 b/changes/ticket30591 new file mode 100644 index 0000000000..f97c024009 --- /dev/null +++ b/changes/ticket30591 @@ -0,0 +1,3 @@ + o Testing (continuous integration): + - In Travis, make stem log a controller trace to the console. And tail + stem's tor log after failure. Closes ticket 30591. -- cgit v1.2.3-54-g00ecf From cdda69ca8ac611802ef2dcf6e5cf60977ab49209 Mon Sep 17 00:00:00 2001 From: teor Date: Thu, 30 May 2019 20:05:03 +1000 Subject: Travis: only run the stem tests that use a tor binary Closes ticket 30694. --- .travis.yml | 2 +- changes/ticket30694 | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 changes/ticket30694 diff --git a/.travis.yml b/.travis.yml index 1d6c838bfc..01f155af26 100644 --- a/.travis.yml +++ b/.travis.yml @@ -211,7 +211,7 @@ script: ## We run `make check` because that's what https://jenkins.torproject.org does. - if [[ "$DISTCHECK" == "" && "$TEST_STEM" == "" ]]; then make check; fi ## Diagnostic for bug 29437: kill stem if it hangs for 15 minutes - - if [[ "$TEST_STEM" != "" ]]; then make src/app/tor; timelimit -p -t 540 -s USR1 -T 30 -S ABRT python3 "$STEM_SOURCE_DIR"/run_tests.py --tor src/app/tor --integ --log TRACE --target RUN_ALL; fi + - if [[ "$TEST_STEM" != "" ]]; then make src/app/tor; timelimit -p -t 540 -s USR1 -T 30 -S ABRT python3 "$STEM_SOURCE_DIR"/run_tests.py --tor src/app/tor --integ --test control.controller --test control.base_controller --test process --log TRACE; fi - if [[ "$DISTCHECK" != "" && "$TEST_STEM" == "" ]]; then make distcheck DISTCHECK_CONFIGURE_FLAGS="$CONFIGURE_FLAGS"; fi ## If this build was one that produced coverage, upload it. - if [[ "$COVERAGE_OPTIONS" != "" ]]; then coveralls -b . --exclude src/test --exclude src/trunnel --gcov-options '\-p' || echo "Coverage failed"; fi diff --git a/changes/ticket30694 b/changes/ticket30694 new file mode 100644 index 0000000000..70dbf6481a --- /dev/null +++ b/changes/ticket30694 @@ -0,0 +1,3 @@ + o Testing (continuous integration): + - In Travis, only run the stem tests that use a tor binary. + Closes ticket 30694. -- cgit v1.2.3-54-g00ecf From 1cad1f98045260c384c27afb7375ada2b00b4cb9 Mon Sep 17 00:00:00 2001 From: teor Date: Fri, 14 Jun 2019 12:13:28 +1000 Subject: Travis: Don't log stem's SocketClosed TRACE logs to the console And fix some nearby comments. Part of 30591. --- .travis.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 01f155af26..d5ef6dba2a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -210,8 +210,9 @@ script: - ./configure $CONFIGURE_FLAGS ## We run `make check` because that's what https://jenkins.torproject.org does. - if [[ "$DISTCHECK" == "" && "$TEST_STEM" == "" ]]; then make check; fi - ## Diagnostic for bug 29437: kill stem if it hangs for 15 minutes - - if [[ "$TEST_STEM" != "" ]]; then make src/app/tor; timelimit -p -t 540 -s USR1 -T 30 -S ABRT python3 "$STEM_SOURCE_DIR"/run_tests.py --tor src/app/tor --integ --test control.controller --test control.base_controller --test process --log TRACE; fi + ## Diagnostic for bug 29437: kill stem if it hangs for 9.5 minutes + ## Travis will kill the job after 10 minutes with no output + - if [[ "$TEST_STEM" != "" ]]; then make src/app/tor; timelimit -p -t 540 -s USR1 -T 30 -S ABRT python3 "$STEM_SOURCE_DIR"/run_tests.py --tor src/app/tor --integ --test control.controller --test control.base_controller --test process --log TRACE | grep -v SocketClosed; fi - if [[ "$DISTCHECK" != "" && "$TEST_STEM" == "" ]]; then make distcheck DISTCHECK_CONFIGURE_FLAGS="$CONFIGURE_FLAGS"; fi ## If this build was one that produced coverage, upload it. - if [[ "$COVERAGE_OPTIONS" != "" ]]; then coveralls -b . --exclude src/test --exclude src/trunnel --gcov-options '\-p' || echo "Coverage failed"; fi -- cgit v1.2.3-54-g00ecf From 5fda19030930d0609734191911f971e23aa5359c Mon Sep 17 00:00:00 2001 From: teor Date: Mon, 1 Jul 2019 13:01:52 +1000 Subject: Travis: Log stem's TRACE logs to a file, and tail it on failure Also filter out stem's SocketClosed logs, and fix some nearby comments. Part of 30591. --- .travis.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index d5ef6dba2a..5490984395 100644 --- a/.travis.yml +++ b/.travis.yml @@ -212,7 +212,7 @@ script: - if [[ "$DISTCHECK" == "" && "$TEST_STEM" == "" ]]; then make check; fi ## Diagnostic for bug 29437: kill stem if it hangs for 9.5 minutes ## Travis will kill the job after 10 minutes with no output - - if [[ "$TEST_STEM" != "" ]]; then make src/app/tor; timelimit -p -t 540 -s USR1 -T 30 -S ABRT python3 "$STEM_SOURCE_DIR"/run_tests.py --tor src/app/tor --integ --test control.controller --test control.base_controller --test process --log TRACE | grep -v SocketClosed; fi + - if [[ "$TEST_STEM" != "" ]]; then make src/app/tor; timelimit -p -t 540 -s USR1 -T 30 -S ABRT python3 "$STEM_SOURCE_DIR"/run_tests.py --tor src/app/tor --integ --test control.controller --test control.base_controller --test process --log TRACE --log-file stem.log; fi - if [[ "$DISTCHECK" != "" && "$TEST_STEM" == "" ]]; then make distcheck DISTCHECK_CONFIGURE_FLAGS="$CONFIGURE_FLAGS"; fi ## If this build was one that produced coverage, upload it. - if [[ "$COVERAGE_OPTIONS" != "" ]]; then coveralls -b . --exclude src/test --exclude src/trunnel --gcov-options '\-p' || echo "Coverage failed"; fi @@ -227,6 +227,7 @@ after_failure: - if [[ "$DISTCHECK" != "" ]]; then make show-distdir-testlog || echo "make failed"; fi - if [[ "$DISTCHECK" != "" ]]; then make show-distdir-core || echo "make failed"; fi - if [[ "$TEST_STEM" != "" ]]; then tail -1000 "$STEM_SOURCE_DIR"/test/data/tor_log || echo "tail failed"; fi + - if [[ "$TEST_STEM" != "" ]]; then grep -v "SocketClosed" stem.log | tail -1000 || echo "grep | tail failed"; fi before_cache: ## Delete all gcov files. -- cgit v1.2.3-54-g00ecf