remove examples (moved to exampleCPP) ; test is now a regresion test (make runtests)

This commit is contained in:
mrkraimer
2016-01-21 14:39:23 -05:00
parent 4ac867ec0f
commit 102174913c
225 changed files with 425 additions and 37853 deletions

View File

@@ -9,6 +9,8 @@
*/
/* Author: Marty Kraimer */
#include <epicsUnitTest.h>
#include <testMain.h>
#include <cstddef>
#include <cstdlib>
@@ -36,6 +38,8 @@ using namespace epics::pvData;
using namespace epics::pvDatabase;
using std::string;
static bool debug = false;
static PVRecordPtr createScalar(
string const & recordName,
ScalarType scalarType,
@@ -58,31 +62,44 @@ static PVRecordPtr createScalarArray(
static void scalarTest()
{
cout << endl << endl << "****scalarTest****" << endl;
if(debug) {cout << endl << endl << "****scalarTest****" << endl; }
PVRecordPtr pvRecord;
pvRecord = createScalar("doubleRecord",pvDouble,"alarm,timeStamp.display");
testOk1(pvRecord.get()!=0);
if(pvRecord && debug) {
cout << pvRecord << endl;
}
pvRecord->destroy();
}
static void arrayTest()
{
cout << endl << endl << "****arrayTest****" << endl;
if(debug) {cout << endl << endl << "****arrayTest****" << endl; }
PVRecordPtr pvRecord;
pvRecord = createScalarArray("doubleArrayRecord",pvDouble,"alarm,timeStamp");
testOk1(pvRecord.get()!=0);
if(pvRecord && debug) {
cout << pvRecord << endl;
}
pvRecord->destroy();
}
static void powerSupplyTest()
{
cout << endl << endl << "****powerSupplyTest****" << endl;
if(debug) {cout << endl << endl << "****powerSupplyTest****" << endl; }
PVRecordPtr pvRecord;
PVStructurePtr pv = createPowerSupply();
pvRecord = PowerSupply::create("powerSupply",pv);
testOk1(pvRecord.get()!=0);
if(pvRecord && debug) {
cout << pvRecord << endl;
}
pvRecord->destroy();
}
int main(int argc,char *argv[])
MAIN(testPVRecord)
{
testPlan(3);
scalarTest();
arrayTest();
powerSupplyTest();