Skip to content
Snippets Groups Projects
Commit 3d2e80d9 authored by Matthew Jordan's avatar Matthew Jordan
Browse files

Add a test event that reports changes in ConfBridge state

This patch adds a test event to ConfBridge that reports transitions between
states in ConfBridge.  This is used by tests in the Asterisk Test Suite
that verify state changes based on the entering/leaving of conference
participants.
........

Merged revisions 376414 from http://svn.asterisk.org/svn/asterisk/branches/10


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/11@376415 65c4cc65-6c06-0410-ace0-fbb531ad65f3
parent c0c552de
Branches
Tags
No related merge requests found
...@@ -38,6 +38,7 @@ ...@@ -38,6 +38,7 @@
#include "asterisk.h" #include "asterisk.h"
#include "asterisk/logger.h" #include "asterisk/logger.h"
#include "asterisk/test.h"
#include "include/conf_state.h" #include "include/conf_state.h"
#include "include/confbridge.h" #include "include/confbridge.h"
...@@ -60,6 +61,10 @@ void conf_default_leave_waitmarked(struct conference_bridge_user *cbu) ...@@ -60,6 +61,10 @@ void conf_default_leave_waitmarked(struct conference_bridge_user *cbu)
void conf_change_state(struct conference_bridge_user *cbu, struct conference_state *newstate) void conf_change_state(struct conference_bridge_user *cbu, struct conference_state *newstate)
{ {
ast_debug(1, "Changing conference '%s' state from %s to %s\n", cbu->conference_bridge->name, cbu->conference_bridge->state->name, newstate->name); ast_debug(1, "Changing conference '%s' state from %s to %s\n", cbu->conference_bridge->name, cbu->conference_bridge->state->name, newstate->name);
ast_test_suite_event_notify("CONF_CHANGE_STATE", "Conference: %s\r\nOldState: %s\r\nNewState: %s\r\n",
cbu->conference_bridge->name,
cbu->conference_bridge->state->name,
newstate->name);
if (cbu->conference_bridge->state->exit) { if (cbu->conference_bridge->state->exit) {
cbu->conference_bridge->state->exit(cbu); cbu->conference_bridge->state->exit(cbu);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment