[svn-commits] mnicholson: branch mnicholson/asttest r193324 - /team/mnicholson/asttest/astt...
SVN commits to the Digium repositories
svn-commits at lists.digium.com
Fri May 8 10:31:33 CDT 2009
Author: mnicholson
Date: Fri May 8 10:31:20 2009
New Revision: 193324
URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=193324
Log:
Added README. Currently it is not 100% accurate, but it will become more accurate as features are added to asttest.
Added:
team/mnicholson/asttest/asttest/README (with props)
Added: team/mnicholson/asttest/asttest/README
URL: http://svn.asterisk.org/svn-view/asterisk/team/mnicholson/asttest/asttest/README?view=auto&rev=193324
==============================================================================
--- team/mnicholson/asttest/asttest/README (added)
+++ team/mnicholson/asttest/asttest/README Fri May 8 10:31:20 2009
@@ -1,0 +1,63 @@
+Asttest Readme
+==============
+
+Asttest is a framework for doing automated testing of asterisk. It can be used
+to test asterisk channels, asterisk applications, asterisk cdr, the manager
+interface, asterisk dialplans, and other parts of asterisk.
+
+Asttest Structure
+=================
+
+Asttest is broken up into two main parts: the asttest test driver and the
+res_asttest asterisk module. The test driver controls the execution of tests
+and collects the results. The res_asttest asterisk module provides access to
+internal asterisk APIs and can emulate a channel driver if necessary.
+
+Writing Tests
+=============
+
+The structure of a test will be different depending on what is being tested.
+All tests require a test.lua file in the given test directory and most tests
+will also include one or res_asttest test scripts. The directory layout for
+tests is as follows:
+
+main_test_dir/
+ test1/
+ test.lua
+ test2/
+ test.lua
+ test3/
+ test.lua
+
+The test.lua file will be executed by asttest when the test is run. The
+test.lua file is responsible for coordinating execution of the test. This file
+may generate config files, start asterisk, interact with asterisk via the
+manager interface, parse log files, etc. Test.lua is also responsible for
+notifiying asttest of the test result.
+
+res_asttest
+===========
+
+The res_asttest module can be used for tests that need access to the internals
+of asterisk. This module can execute tests via the manager interface. The
+tests have the ability to create asterisk channels and access internal asterisk
+API calls. Tests executed via the RunTest manager action should have the
+folloing function signature:
+
+tests.test_name(args)
+
+Res_asttest also has the ability to terminate calls from the Dial applcation.
+For example:
+
+; dial res_asttest
+exten s,1,Dial(asttest/test_name)
+
+This will execute the given test name using the following fuction call:
+
+tests.test_name(channel, data)
+
+The test can then read and write data to and from the channel and initiate
+transfers and other events.
+
+
+vim: set fo=tqwal:
Propchange: team/mnicholson/asttest/asttest/README
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: team/mnicholson/asttest/asttest/README
------------------------------------------------------------------------------
svn:keywords = Author Date Id Revision
Propchange: team/mnicholson/asttest/asttest/README
------------------------------------------------------------------------------
svn:mime-type = text/plain
More information about the svn-commits
mailing list