13
0
livetrax/libs/pbd/test/signals_test.cc
Carl Hetherington b20a139129 Missing files.
git-svn-id: svn://localhost/ardour2/branches/3.0@9075 d708f5d6-7413-0410-9779-e7cbd77b26cf
2011-03-04 17:35:39 +00:00

34 lines
430 B
C++

#include "signals_test.h"
#include "pbd/signals.h"
CPPUNIT_TEST_SUITE_REGISTRATION (SignalsTest);
class Emitter {
public:
void emit () {
Fred ();
}
PBD::Signal0<void> Fred;
};
void
receiver ()
{
}
void
SignalsTest::testDestruction ()
{
Emitter* e = new Emitter;
PBD::ScopedConnection c;
e->Fred.connect_same_thread (c, boost::bind (&receiver));
e->emit ();
delete e;
c.disconnect ();
CPPUNIT_ASSERT (true);
}