13
0
livetrax/libs/evoral/test/CurveTest.h

36 lines
927 B
C
Raw Normal View History

#include <memory>
2015-01-19 16:14:58 -05:00
#include <cppunit/TestFixture.h>
#include <cppunit/extensions/HelperMacros.h>
#include "evoral/ControlList.h"
2015-01-19 16:14:58 -05:00
class CurveTest : public CppUnit::TestFixture
{
CPPUNIT_TEST_SUITE (CurveTest);
2016-12-04 15:17:08 -05:00
CPPUNIT_TEST (trivial);
CPPUNIT_TEST (rtGet);
CPPUNIT_TEST (twoPointLinear);
2015-01-19 18:46:58 -05:00
CPPUNIT_TEST (threePointLinear);
CPPUNIT_TEST (threePointDiscete);
CPPUNIT_TEST (constrainedCubic);
2015-01-19 18:46:58 -05:00
CPPUNIT_TEST (ctrlListEval);
2015-01-19 16:14:58 -05:00
CPPUNIT_TEST_SUITE_END ();
public:
2016-12-04 15:17:08 -05:00
void trivial ();
void rtGet ();
void twoPointLinear ();
2015-01-19 18:46:58 -05:00
void threePointLinear ();
void threePointDiscete ();
void constrainedCubic ();
2015-01-19 18:46:58 -05:00
void ctrlListEval ();
2015-01-19 16:14:58 -05:00
private:
std::shared_ptr<Evoral::ControlList> TestCtrlList() {
Evoral::Parameter param (Evoral::Parameter(0));
const Evoral::ParameterDescriptor desc;
return std::shared_ptr<Evoral::ControlList> (new Evoral::ControlList(param, desc, Temporal::TimeDomainProvider (Temporal::AudioTime)));
}
};