COPASI API  4.16.103
Public Member Functions | Static Protected Attributes | Private Member Functions | List of all members
test000090 Class Reference

#include <test000090.h>

Inheritance diagram for test000090:
Inheritance graph
[legend]
Collaboration diagram for test000090:
Collaboration graph
[legend]

Public Member Functions

void setUp ()
 
void tearDown ()
 
void test_delay_in_function ()
 

Static Protected Attributes

static const char * MODEL_STRING
 
static CCopasiDataModelpCOPASIDATAMODEL = NULL
 

Private Member Functions

 CPPUNIT_TEST (test_delay_in_function)
 
 CPPUNIT_TEST_SUITE (test000090)
 
 CPPUNIT_TEST_SUITE_END ()
 

Detailed Description

Definition at line 24 of file test000090.h.

Member Function Documentation

test000090::CPPUNIT_TEST ( test_delay_in_function  )
private
test000090::CPPUNIT_TEST_SUITE ( test000090  )
private
test000090::CPPUNIT_TEST_SUITE_END ( )
private
void test000090::setUp ( )

Definition at line 31 of file test000090.cpp.

References CCopasiRootContainer::addDatamodel(), CCopasiRootContainer::init(), and pCOPASIDATAMODEL.

32 {
33  // Create the root container.
34  CCopasiRootContainer::init(0, NULL, false);
35  // Create the global data model.
37 }
static CCopasiDataModel * pCOPASIDATAMODEL
Definition: test000090.h:32
static CCopasiDataModel * addDatamodel()
static void init(int argc, char *argv[], const bool &withGui=false)
void test000090::tearDown ( )

Definition at line 39 of file test000090.cpp.

References CCopasiRootContainer::destroy().

void test000090::test_delay_in_function ( )

Definition at line 44 of file test000090.cpp.

References CCopasiMessage::EXCEPTION, CCopasiMessage::getLastMessage(), CCopasiMessage::getText(), CCopasiMessage::getType(), CCopasiDataModel::importSBMLFromString(), MODEL_STRING, and pCOPASIDATAMODEL.

45 {
46  CCopasiDataModel* pDataModel = pCOPASIDATAMODEL;
47 
48  try
49  {
51  }
52  catch (...)
53  {
55  CPPUNIT_ASSERT(message.getType() == CCopasiMessage::EXCEPTION);
56  std::string s = message.getText();
57  CPPUNIT_ASSERT(!s.empty());
58  CPPUNIT_ASSERT(s.find(std::string("Call to delay function used in function definition")) != std::string::npos);
59  return;
60  }
61 
62  // we should never get here
63  CPPUNIT_ASSERT(false);
64 }
const std::string & getText() const
static CCopasiDataModel * pCOPASIDATAMODEL
Definition: test000090.h:32
const CCopasiMessage::Type & getType() const
static const char * MODEL_STRING
Definition: test000090.h:31
static CCopasiMessage getLastMessage()
bool importSBMLFromString(const std::string &sbmlDocumentText, CProcessReport *pImportHandler=NULL, const bool &deleteOldData=true)

Member Data Documentation

const char * test000090::MODEL_STRING
staticprotected

Definition at line 31 of file test000090.h.

Referenced by test_delay_in_function().

CCopasiDataModel * test000090::pCOPASIDATAMODEL = NULL
staticprotected

Definition at line 32 of file test000090.h.

Referenced by setUp(), and test_delay_in_function().


The documentation for this class was generated from the following files: