<html>
<body>
<div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
<table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
<tr>
<td>
This is an automatically generated e-mail. To reply, visit:
<a href="https://reviewboard.asterisk.org/r/2131/">https://reviewboard.asterisk.org/r/2131/</a>
</td>
</tr>
</table>
<br />
<div>
<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
<thead>
<tr>
<th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
<a href="https://reviewboard.asterisk.org/r/2131/diff/2/?file=31418#file31418line56" style="color: black; font-weight: bold; text-decoration: underline;">/asterisk/trunk/tests/channels/SIP/sip_outbound_address/originator.py</a>
<span style="font-weight: normal;">
(Diff revision 2)
</span>
</th>
</tr>
</thead>
<tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
<tr>
<td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
<td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">def scenario_started(self, result):</pre></td>
</tr>
</tbody>
<tbody>
<tr>
<th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
<th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">56</font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "> <span class="k">def</span> <span class="nf">failure</span><span class="p">(</span><span class="n">result</span><span class="p">):</span></pre></td>
</tr>
<tr>
<th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
<th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">57</font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "> <span class="bp">self</span><span class="o">.</span><span class="n">test_object</span><span class="o">.</span><span class="n">set_passed</span><span class="p">(</span><span class="bp">False</span><span class="p">)</span></pre></td>
</tr>
<tr>
<th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
<th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">58</font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "> <span class="k">return</span> <span class="n">result</span></pre></td>
</tr>
</tbody>
</table>
<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">This doesn't appear to be used. Should it be the errback handler for the AMI originate?</pre>
</div>
<br />
<p>- Matt</p>
<br />
<p>On September 25th, 2012, 11:39 a.m., Mark Michelson wrote:</p>
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('https://reviewboard.asterisk.org/media/rb/images/review_request_box_top_bg.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
<tr>
<td>
<div>Review request for Asterisk Developers.</div>
<div>By Mark Michelson.</div>
<p style="color: grey;"><i>Updated Sept. 25, 2012, 11:39 a.m.</i></p>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">This is a rewrite of the sip_outbound_address test. This test had a "skip" flag set on it in apparently because the test was bouncing. Unfortunately, not having this test enabled resulted in the issue ASTERISK-19677.
The test was likely bouncing due to some odd timing being used (combination of Wait() dialplan app plus some sleep() calls in the test code). I've rewritten the test to no longer use Lua and instead use Python. It uses the SIPpTestCase. This test becomes either the second or third to have an "originator" module used alongside the SIPpTestCase. Perhaps it's time to consider making this a module central to the test suite?
As far as the test details are concerned, the test mostly is the same. The same extensions.conf is used and the same destinations are dialed. Now, instead of having the SIPp scenario that answers send back DTMF, the SIPp scenario simply answers and then hangs up. The test can be determined to pass or fail based on whether the SIPp scenario succeeds or fails. It will fail if Asterisk were to route the request to the wrong destination. This has made the test much simpler than it previously was.</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Test passes with current 1.8 version of Asterisk.</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/configs/ast1/extensions.conf <span style="color: grey">(3480)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/configs/ast1/sip.conf <span style="color: grey">(3480)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/originator.py <span style="color: grey">(PRE-CREATION)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/run-test <span style="color: grey">(3480)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/sipp/dtmf_2833_1.pcap <span style="color: grey">(UNKNOWN)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/sipp/dtmf_2833_2.pcap <span style="color: grey">(UNKNOWN)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/sipp/dtmf_2833_pound.pcap <span style="color: grey">(UNKNOWN)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/sipp/uas.xml <span style="color: grey">(PRE-CREATION)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/sipp/uas1.xml <span style="color: grey">(3480)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/sipp/uas2.xml <span style="color: grey">(3480)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/test-config.yaml <span style="color: grey">(3480)</span></li>
<li>/asterisk/trunk/tests/channels/SIP/sip_outbound_address/test.lua <span style="color: grey">(3480)</span></li>
</ul>
<p><a href="https://reviewboard.asterisk.org/r/2131/diff/" style="margin-left: 3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>