VOZ logo

Publicado framework para testear nuestro sistema Asterisk

Leyendo la lista de Asterisk-DEV me entero que acaban de publicar un nuevo framework para realizar diversos test al sistema Asterisk.

El sistema de testeo llamado (Unit Test Framework) añade una serie de herramientas para crear y ejecutar tests internos a través de la consola CLI de Asterisk, lo que nos permitirá detectar si hay alguna incidencia.

Como todo framework, lo que nos ofrece son las herramientas necesarias para desarrollar el resto de utilidades que podemos necesitar, por lo tanto habrá que investigar qué engloba estas herramientas y qué podemos hacer con ellas.

El mensaje original, a continuación…

Our hopes are that by introducing this framework, test verification will be
implemented along side all new development efforts.  This will not only further
enhance the quality of our code in general, but also facilitate the creation of
more maintainable and verifiable code in the future.  In addition to new
development, any efforts to write unit tests for existing code is more than
welcome!

For detailed information on how to define and register unit tests please refer
to the documentation included within the include/asterisk/test.h header file.
If you are interested in viewing an example, tests/test_heap.c has been
converted to use this framework.

Feature Overview:
- Define Unit Tests anywhere in the code using the AST_TEST_DEFINE macro
- Register Unit Tests to a central test manager using AST_TEST_REGISTER macro
- Unregister Unit Tests from the test manager using AST_TEST_UNREGISTER macro
- Execute test from CLI
- Generate xml and txt test result reports from CLI

New CLI Commands
-'test execute all'
-'test execute category'
-'test generate results xml'
-'test generate results txt'
-'test show results all'
-'test show results failed'
-'test show results passed'
-'test show registered'

Enabling TEST_FRAMEWORK
- Configure Asterisk using dev mode, './configure –enable-dev-mode'
- In 'make menuselect' under the 'Compiler Flags' option enable the
'TEST_FRAMEWORK' flag.
- Recompile Asterisk and the test CLI options will be made available.

If you have any questions please feel free to contact me via email.  I'm also
available in #asterisk-dev as The_Boy_Wonder.

~Vossel

Enlace: http://www.mail-archive.com/asterisk-dev@lists.digium.com/msg40545.html

Anterior artículoEl 2010 podría ser el año de la VoIP Global
Siguiente artículo 2880-2876SinoLogic os desea una Feliz Navidad