13
0
livetrax/libs/pbd/test/scalar_properties.cc
Carl Hetherington 69f135517a Unbreak build. Sorry.
git-svn-id: svn://localhost/ardour2/branches/3.0@6837 d708f5d6-7413-0410-9779-e7cbd77b26cf
2010-04-02 15:45:01 +00:00

32 lines
528 B
C++

#include "scalar_properties.h"
using namespace PBD;
namespace Properties {
PBD::PropertyDescriptor<int> fred;
};
ScalarPropertiesTest::ScalarPropertiesTest ()
: _fred (Properties::fred, 0)
{
}
void
ScalarPropertiesTest::testBasic ()
{
CPPUNIT_ASSERT (_fred.changed() == false);
_fred = 4;
CPPUNIT_ASSERT (_fred == 4);
CPPUNIT_ASSERT (_fred.changed() == true);
_fred = 5;
CPPUNIT_ASSERT (_fred == 5);
CPPUNIT_ASSERT (_fred.changed() == true);
PropertyList undo;
PropertyList redo;
_fred.diff (undo, redo);
}