<p>George Joseph <strong>merged</strong> this change.</p><p><a href="https://gerrit.asterisk.org/10410">View Change</a></p><div style="white-space:pre-wrap">Approvals:
Corey Farrell: Looks good to me, but someone else must approve
George Joseph: Looks good to me, approved; Approved for Submit
</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">CI: Look up configured kernel.core_pattern sysctl<br><br>Change-Id: I8246a0147df8d821fbbcabc1db1887104b8bedc4<br>---<br>M tests/CI/runUnittests.sh<br>1 file changed, 22 insertions(+), 5 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/tests/CI/runUnittests.sh b/tests/CI/runUnittests.sh</span><br><span>index 7cb750b..2fb365d 100755</span><br><span>--- a/tests/CI/runUnittests.sh</span><br><span>+++ b/tests/CI/runUnittests.sh</span><br><span>@@ -3,6 +3,17 @@</span><br><span> source $CIDIR/ci.functions</span><br><span> ASTETCDIR=$DESTDIR/etc/asterisk</span><br><span> </span><br><span style="color: hsl(120, 100%, 40%);">+asterisk_corefile_glob() {</span><br><span style="color: hsl(120, 100%, 40%);">+ local pattern=$(/sbin/sysctl -n kernel.core_pattern)</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+ # If core_pattern is a pipe there isn't much we can do</span><br><span style="color: hsl(120, 100%, 40%);">+ if [[ ${pattern:0:1} == "|" ]] ; then</span><br><span style="color: hsl(120, 100%, 40%);">+ echo "core*"</span><br><span style="color: hsl(120, 100%, 40%);">+ else</span><br><span style="color: hsl(120, 100%, 40%);">+ echo "${pattern%%%*}*"</span><br><span style="color: hsl(120, 100%, 40%);">+ fi</span><br><span style="color: hsl(120, 100%, 40%);">+}</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span> cat <<-EOF > "$ASTETCDIR/logger.conf"</span><br><span> [logfiles]</span><br><span> full => notice,warning,error,debug,verbose</span><br><span>@@ -69,8 +80,14 @@</span><br><span> set +x</span><br><span> </span><br><span> [ x"$USER_GROUP" != x ] && sudo chown -R $USER_GROUP $OUTPUTDIR</span><br><span style="color: hsl(0, 100%, 40%);">-if [ -f core* ] ; then</span><br><span style="color: hsl(0, 100%, 40%);">- echo "*** Found a core file after running unit tests ***"</span><br><span style="color: hsl(0, 100%, 40%);">- $DESTDIR/var/lib/asterisk/scripts/ast_coredumper --no-default-search core*</span><br><span style="color: hsl(0, 100%, 40%);">- exit 1</span><br><span style="color: hsl(0, 100%, 40%);">-fi</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+for core in $(asterisk_corefile_glob)</span><br><span style="color: hsl(120, 100%, 40%);">+do</span><br><span style="color: hsl(120, 100%, 40%);">+ if [ -f $core ]</span><br><span style="color: hsl(120, 100%, 40%);">+ then</span><br><span style="color: hsl(120, 100%, 40%);">+ echo "*** Found a core file ($core) after running unit tests ***"</span><br><span style="color: hsl(120, 100%, 40%);">+ sudo OUTPUTDIR=$OUTPUTDIR $DESTDIR/var/lib/asterisk/scripts/ast_coredumper --no-default-search $core</span><br><span style="color: hsl(120, 100%, 40%);">+ fi</span><br><span style="color: hsl(120, 100%, 40%);">+done</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+exit 0</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/10410">change 10410</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/10410"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-MessageType: merged </div>
<div style="display:none"> Gerrit-Change-Id: I8246a0147df8d821fbbcabc1db1887104b8bedc4 </div>
<div style="display:none"> Gerrit-Change-Number: 10410 </div>
<div style="display:none"> Gerrit-PatchSet: 9 </div>
<div style="display:none"> Gerrit-Owner: Sean Bright <sean.bright@gmail.com> </div>
<div style="display:none"> Gerrit-Reviewer: Corey Farrell <git@cfware.com> </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins2 (1000185) </div>