Skip to content

Commit fc977a4

Browse files
committed
travis: generate/show coredumps from pytests.
1 parent 8cdda23 commit fc977a4

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

test/pyhttpd/env.py

+1
Original file line numberDiff line numberDiff line change
@@ -443,6 +443,7 @@ def install_test_conf(self, lines: List[str]):
443443
with open(self._test_conf, 'w') as fd:
444444
fd.write('\n'.join(self._httpd_base_conf))
445445
fd.write('\n')
446+
fd.write(f"CoreDumpDirectory {self._server_dir}\n")
446447
if self._verbosity >= 2:
447448
fd.write(f"LogLevel core:trace5 {self.mpm_module}:trace5\n")
448449
if self._log_interesting:

test/travis_run_linux.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,7 @@ if ! test -v SKIP_TESTING; then
114114

115115
# Try to keep all potential coredumps from all processes
116116
sudo sysctl -w kernel.core_uses_pid=1 2>/dev/null || true
117+
ulimit -c unlimited 2>/dev/null || true
117118

118119
if ! test -v NO_TEST_FRAMEWORK; then
119120
if test -v WITH_TEST_SUITE; then
@@ -266,7 +267,7 @@ if ! test -v SKIP_TESTING; then
266267
fi
267268
fi
268269

269-
for core in `ls test/perl-framework/t/core{,.*} 2>/dev/null`; do
270+
for core in `ls test/perl-framework/t/core{,.*} test/gen/apache/core{,.*} 2>/dev/null`; do
270271
gdb -ex 'thread apply all backtrace full' -batch ./httpd "$core"
271272
RV=5
272273
done

0 commit comments

Comments
 (0)