[asterisk-dev] [Code Review] 4267: Testsuite: Add blind transfer tests for Stasis application interaction.
Matt Jordan
reviewboard at asterisk.org
Tue Dec 23 09:27:39 CST 2014
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/4267/#review14034
-----------------------------------------------------------
/asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/blind_transfer.py
<https://reviewboard.asterisk.org/r/4267/#comment24545>
There is no guaranteed order between alice and bob. When starting two SIPpScenario objects, alice may completely start and complete before bob has started, and vice versa.
As it is, this test feels like it would be prone to failure, as:
(a) There is no coordination (3pcc) between the referee and referer scenarios
(b) The referer scenario has a hard wait of 1 second to let Bob join the bridge, which has no coordination with Asterisk
I'm concerned that we'd be introducing another bouncy test without having better coordination between the SIPp scenarios and/or the transfer scenarios with Asterisk.
One solution would be to drop SIPp (as we don't need the level of granularity it provides for SIP messages for this scenario) and leverage the Python PJSUA bindings. We already have Python code written that performs various SIP transfers (see tests/channels/pjsip/transfers/blind_transfer/[callee_refer_only|caller_refer_only]) using the PJSUA bindings - that could be leveraged here to make sure that the transfers are successful.
Note that we recently cleaned those tests up such that they only initiate a transfer once the parties are in their respective bridges; this has made the tests very reliable (or at least, I haven't seen them fail since).
As an aside, if you do use that, you'll probably want to refactor that code into a shared Python library, as having generic code that performs a SIP level blind transfer is pretty useful.
- Matt Jordan
On Dec. 19, 2014, 1:54 p.m., jbigelow wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/4267/
> -----------------------------------------------------------
>
> (Updated Dec. 19, 2014, 1:54 p.m.)
>
>
> Review request for Asterisk Developers and Mark Michelson.
>
>
> Bugs: ASTERISK-24581
> https://issues.asterisk.org/jira/browse/ASTERISK-24581
>
>
> Repository: testsuite
>
>
> Description
> -------
>
> This adds the remaining blind transfer tests 1.9 & 1.10 as described on the StasisStart/StasisEnd Test Plan at: https://wiki.asterisk.org/wiki/pages/viewpage.action?pageId=30279826
>
> This additionally updates the existing test 'stasis_bridge_to_non_stasis_app' (1.8) to verify the StasisEnd events of the channels per the test plan. An additional (dummy) channel was added for the test to prevent the test from ending when the channels involved in the test are hung up. This allows the StasisEnd events of all the other channels to be verified before the test has ended. The test description has also been updated to include more details about the test.
>
>
> Diffs
> -----
>
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/tests.yaml 6105
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_same_stasis_app/test-config.yaml PRE-CREATION
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_same_stasis_app/sipp/referer.xml PRE-CREATION
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_same_stasis_app/sipp/referee.xml PRE-CREATION
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_same_stasis_app/configs/ast1/pjsip.conf PRE-CREATION
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_same_stasis_app/configs/ast1/extensions.conf PRE-CREATION
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_non_stasis_app/test-config.yaml 6105
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_non_stasis_app/configs/ast1/extensions.conf 6105
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_non_stasis_app/blind_transfer.py 6105
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_different_stasis_app/test-config.yaml PRE-CREATION
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_different_stasis_app/sipp/referer.xml PRE-CREATION
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_different_stasis_app/sipp/referee.xml PRE-CREATION
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_different_stasis_app/configs/ast1/pjsip.conf PRE-CREATION
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/stasis_bridge_to_different_stasis_app/configs/ast1/extensions.conf PRE-CREATION
> /asterisk/trunk/tests/rest_api/external_interaction/blind_transfer/blind_transfer.py PRE-CREATION
>
> Diff: https://reviewboard.asterisk.org/r/4267/diff/
>
>
> Testing
> -------
>
> * Executed tests multiple times
> * Reviewed logs to manually verify StasisStart/StasisEnd events occurred.
>
>
> Thanks,
>
> jbigelow
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20141223/bb9a2d34/attachment-0001.html>
More information about the asterisk-dev
mailing list