Unbreak build. Sorry.
authorCarl Hetherington <carl@carlh.net>
Fri, 2 Apr 2010 15:45:01 +0000 (15:45 +0000)
committerCarl Hetherington <carl@carlh.net>
Fri, 2 Apr 2010 15:45:01 +0000 (15:45 +0000)
git-svn-id: svn://localhost/ardour2/branches/3.0@6837 d708f5d6-7413-0410-9779-e7cbd77b26cf

libs/pbd/test/scalar_properties.cc
libs/pbd/test/scalar_properties.h

index f85b1081a40ded2e0bb47e064bb2e5107d611005..05d97a7ad10ebd09f393b01fc2a82db57276f7e6 100644 (file)
@@ -2,19 +2,30 @@
 
 using namespace PBD;
 
+namespace Properties {
+       PBD::PropertyDescriptor<int> fred;
+};
+
+ScalarPropertiesTest::ScalarPropertiesTest ()
+       : _fred (Properties::fred, 0)
+{
+
+}
+
+void
 ScalarPropertiesTest::testBasic ()
 {
-       CPPUNIT_ASSERT (_property.changed() == false);
+       CPPUNIT_ASSERT (_fred.changed() == false);
        
-       _property = 4;
-       CPPUNIT_ASSERT (_property == 4);
-       CPPUNIT_ASSERT (_property.changed() == true);
+       _fred = 4;
+       CPPUNIT_ASSERT (_fred == 4);
+       CPPUNIT_ASSERT (_fred.changed() == true);
 
-       _property = 5;
-       CPPUNIT_ASSERT (_property == 5);
-       CPPUNIT_ASSERT (_property.changed() == true);
+       _fred = 5;
+       CPPUNIT_ASSERT (_fred == 5);
+       CPPUNIT_ASSERT (_fred.changed() == true);
 
        PropertyList undo;
        PropertyList redo;
-       _property.diff (undo, redo);
+       _fred.diff (undo, redo);
 }
index a3719fbe130a556a4f206f80f2eba2baeb232ad3..04291e66e9b495566a2ddec9590bc886c2e56e21 100644 (file)
@@ -1,15 +1,17 @@
 #include <cppunit/TestFixture.h>
+#include <cppunit/extensions/HelperMacros.h>
 #include "pbd/properties.h"
 
 class ScalarPropertiesTest : public CppUnit::TestFixture
 {
-public:
        CPPUNIT_TEST_SUITE (ScalarPropertiesTest);
        CPPUNIT_TEST (testBasic);
        CPPUNIT_TEST_SUITE_END ();
 
+public:
+       ScalarPropertiesTest ();
        void testBasic ();
 
 private:
-       PBD::Property<int> _property;
+       PBD::Property<int> _fred;
 };