Skip to content
Snippets Groups Projects
Commit 409324a1 authored by Martin Killenberg's avatar Martin Killenberg
Browse files

renamed server based tests to serverTest* to allow easyer handling with wildcards

parent f9b4ce63
No related branches found
No related tags found
No related merge requests found
File moved
......@@ -7,7 +7,7 @@
#include <doocs-server-test-helper/doocsServerTestHelper.h>
#include <thread>
ReferenceTestApplication referenceTestApplication("testPlainVariableCreation");
ReferenceTestApplication referenceTestApplication("serverTestPlainVariableCreation");
// declare that we have some thing like a doocs server. is is linked from the doocs lib, but there is no header.
extern int eq_server(int, char **);
......@@ -62,6 +62,6 @@ protected:
test_suite*
init_unit_test_suite( int argc, char* argv[] )
{
framework::master_test_suite().p_name.value = "PlainVariableCreation test suite";
framework::master_test_suite().p_name.value = "PlainVariableCreation server test suite";
return new PlainVariableCreationTestSuite(argc, argv);
}
......@@ -7,7 +7,7 @@
#include <doocs-server-test-helper/doocsServerTestHelper.h>
#include <thread>
ReferenceTestApplication referenceTestApplication("testRenameImport");
ReferenceTestApplication referenceTestApplication("serverTestRenameImport");
// declare that we have some thing like a doocs server. is is linked from the doocs lib, but there is no header.
extern int eq_server(int, char **);
......@@ -45,7 +45,7 @@ void testVariableExistence(){
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGetArray<int>("//DOUBLE/CONSTANT_ARRAY") );
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGetArray<int>("//DOUBLE/FROM_DEVICE_ARRAY") );
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGetArray<int>("//DOUBLE/TO_DEVICE_ARRAY") );
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGet<int>("//DOUBLE/RENAMED_CONSTANT") );
BOOST_CHECK( DoocsServerTestHelper::doocsGet<double>("//DOUBLE/RENAMED_CONSTANT") == 1./8.);
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGet<int>("//DOUBLE/FROM_DEVICE_SCALAR") );
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGet<int>("//DOUBLE/DOUBLE.TO_DEVICE_SCALAR") );
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGet<int>("//DOUBLE/I_AM_A_FLOAT_SCALAR") );
......@@ -53,15 +53,15 @@ void testVariableExistence(){
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGetArray<int>("//FLOAT/CONSTANT_ARRAY") );
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGetArray<int>("//FLOAT/FROM_DEVICE_ARRAY") );
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGetArray<int>("//FLOAT/TO_DEVICE_ARRAY") );
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGet<int>("//FLOAT/DATA_TYPE_CONSTANT") );
BOOST_CHECK( DoocsServerTestHelper::doocsGet<float>("//FLOAT/DATA_TYPE_CONSTANT") == 1./4.);
BOOST_CHECK_NO_THROW( DoocsServerTestHelper::doocsGet<int>("//FLOAT/FROM_DEVICE_SCALAR") );
}
// due to the doocs server thread you can only have one test suite
class RenameImportTestSuite : public test_suite {
class RenameImportServerTestSuite : public test_suite {
public:
RenameImportTestSuite(int argc, char* argv[])
: test_suite("RenameImport test suite") ,
RenameImportServerTestSuite(int argc, char* argv[])
: test_suite("RenameImport server test suite") ,
doocsServerThread(eq_server, argc, argv)
{
doocsServerThread.detach();
......@@ -75,6 +75,6 @@ protected:
test_suite*
init_unit_test_suite( int argc, char* argv[] )
{
framework::master_test_suite().p_name.value = "RenameImport test suite";
return new RenameImportTestSuite(argc, argv);
framework::master_test_suite().p_name.value = "RenameImport server test suite";
return new RenameImportServerTestSuite(argc, argv);
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment