Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

testPlatform Class Reference

#include <testPlatform.h>

List of all members.

Public Member Functions

virtual void setUp ()
virtual void tearDown ()
void testGetBoundaries ()
void testCmosChecksum ()
void testCmosWriting ()
void testSystemInfo ()
void testIdByte ()
void testServiceTag ()
void testServiceTagWriting ()
void testAssetTag ()
void testSystemName ()
void testBiosVersion ()
void testIsDell ()
void testVariousAccessors ()
void testOutOfBounds ()
void testConstructionOffset1 ()
void testConstructionOffset2 ()
void testStateBytes ()
void testUpBoot ()
 CPPUNIT_TEST_SUITE (testPlatform)
 CPPUNIT_TEST (testCmosChecksum)
 CPPUNIT_TEST (testCmosWriting)
 CPPUNIT_TEST (testSystemInfo)
 CPPUNIT_TEST (testIdByte)
 CPPUNIT_TEST (testServiceTag)
 CPPUNIT_TEST (testServiceTagWriting)
 CPPUNIT_TEST (testAssetTag)
 CPPUNIT_TEST (testSystemName)
 CPPUNIT_TEST (testBiosVersion)
 CPPUNIT_TEST (testIsDell)
 CPPUNIT_TEST (testVariousAccessors)
 CPPUNIT_TEST (testOutOfBounds)
 CPPUNIT_TEST (testConstructionOffset1)
 CPPUNIT_TEST (testConstructionOffset2)
 CPPUNIT_TEST (testStateBytes)
 CPPUNIT_TEST (testUpBoot)
 CPPUNIT_TEST_SUITE_END ()

Protected Member Functions

virtual std::string getCppunitTopDirectory ()
virtual std::string getWritableDirectory ()
virtual std::string getTestName ()
virtual std::string getTestDirectory ()
std::string getTestInputString (std::string toFind, std::string section="systemInfo")
void checkSkipTest (std::string testName)

Protected Attributes

XML_NAMESPACE DOMBuilder * parser
XML_NAMESPACE DOMDocument * doc


Member Function Documentation

void checkSkipTest std::string  testName  )  [protected]
 

Definition at line 151 of file testPlatform.cpp.

References doc, DOMElement, xmlutils::findElement(), XERCES_CPP_NAMESPACE_QUALIFIER, and xmlDocGetRootElement.

CPPUNIT_TEST testUpBoot   ) 
 

CPPUNIT_TEST testStateBytes   ) 
 

CPPUNIT_TEST testConstructionOffset2   ) 
 

CPPUNIT_TEST testConstructionOffset1   ) 
 

CPPUNIT_TEST testOutOfBounds   ) 
 

CPPUNIT_TEST testVariousAccessors   ) 
 

CPPUNIT_TEST testIsDell   ) 
 

CPPUNIT_TEST testBiosVersion   ) 
 

CPPUNIT_TEST testSystemName   ) 
 

CPPUNIT_TEST testAssetTag   ) 
 

CPPUNIT_TEST testServiceTagWriting   ) 
 

CPPUNIT_TEST testServiceTag   ) 
 

CPPUNIT_TEST testIdByte   ) 
 

CPPUNIT_TEST testSystemInfo   ) 
 

CPPUNIT_TEST testCmosWriting   ) 
 

CPPUNIT_TEST testCmosChecksum   ) 
 

CPPUNIT_TEST_SUITE testPlatform   ) 
 

CPPUNIT_TEST_SUITE_END  ) 
 

virtual std::string getCppunitTopDirectory  )  [inline, protected, virtual]
 

Definition at line 43 of file testPlatform.h.

References global_argv.

Referenced by setUp().

virtual std::string getTestDirectory  )  [inline, protected, virtual]
 

Definition at line 59 of file testPlatform.h.

References global_argv.

Referenced by setUp().

string getTestInputString std::string  toFind,
std::string  section = "systemInfo"
[protected]
 

Definition at line 409 of file testPlatform.cpp.

References doc, DOMElement, xmlutils::findElement(), xmlutils::getNodeText(), XERCES_CPP_NAMESPACE_QUALIFIER, and xmlDocGetRootElement.

Referenced by testAssetTag(), testBiosVersion(), testIdByte(), testIsDell(), testServiceTag(), testServiceTagWriting(), and testSystemName().

virtual std::string getTestName  )  [inline, protected, virtual]
 

Definition at line 54 of file testPlatform.h.

References global_argv.

Referenced by testAssetTag(), testBiosVersion(), testCmosChecksum(), testCmosWriting(), testConstructionOffset1(), testConstructionOffset2(), testIdByte(), testIsDell(), testOutOfBounds(), testServiceTag(), testServiceTagWriting(), testStateBytes(), testSystemInfo(), testSystemName(), testUpBoot(), and testVariousAccessors().

virtual std::string getWritableDirectory  )  [inline, protected, virtual]
 

Definition at line 48 of file testPlatform.h.

References global_argv.

Referenced by setUp().

void setUp  )  [virtual]
 

Definition at line 71 of file testPlatform.cpp.

References compatXmlReadFile, copyFile(), doc, fileExists(), getCppunitTopDirectory(), SmiFactory::getFactory(), MemoryFactory::getFactory(), CmosRWFactory::getFactory(), SmbiosFactory::getFactory(), xmlutils::getParser(), getTestDirectory(), getWritableDirectory(), InitXML, and parser.

void tearDown  )  [virtual]
 

Definition at line 124 of file testPlatform.cpp.

References doc, FiniXML, SmiFactory::getFactory(), CmosRWFactory::getFactory(), MemoryFactory::getFactory(), SmbiosFactory::getFactory(), TokenTableFactory::getFactory(), parser, xmlFreeDoc, and xmlFreeParser.

void testAssetTag  ) 
 

Definition at line 595 of file testPlatform.cpp.

References getAssetTagFromToken(), getTestInputString(), getTestName(), safeConvertToString(), SMBIOSGetAssetTag(), SMBIOSSetAssetTag(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testBiosVersion  ) 
 

Definition at line 621 of file testPlatform.cpp.

References getTestInputString(), getTestName(), safeConvertToString(), SMBIOSGetBiosVersion(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testCmosChecksum  ) 
 

Definition at line 179 of file testPlatform.cpp.

References ITokenTable::begin(), ITokenTable::const_iterator, ITokenTable::end(), CmosRWFactory::getFactory(), TokenTableFactory::getFactory(), TokenTableFactory::getSingleton(), getTestName(), IObservable::notify(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testCmosWriting  ) 
 

Definition at line 204 of file testPlatform.cpp.

References ASSERT_THROWS, ITokenTable::begin(), ITokenTable::const_iterator, ITokenTable::end(), CmosRWFactory::getFactory(), TokenTableFactory::getFactory(), TokenTableFactory::getSingleton(), getTestName(), ITokenTable::iterator, IObservable::notify(), STD_TEST_END, STD_TEST_START_CHECKSKIP, and u8.

void testConstructionOffset1  ) 
 

Definition at line 825 of file testPlatform.cpp.

References ISmbiosTable::begin(), ISmbiosTable::const_iterator, doc, DOMElement, ISmbiosTable::end(), xmlutils::findElement(), SmbiosFactory::getFactory(), ISmbiosTable::getNumberOfEntries(), getTestName(), STD_TEST_END, STD_TEST_START_CHECKSKIP, u32, XERCES_CPP_NAMESPACE_QUALIFIER, and xmlDocGetRootElement.

void testConstructionOffset2  ) 
 

Definition at line 865 of file testPlatform.cpp.

References ASSERT_THROWS, doc, DOMElement, xmlutils::findElement(), SmbiosFactory::getFactory(), getTestName(), SmbiosFactory::makeNew(), IFactory::setParameter(), STD_TEST_END, STD_TEST_START_CHECKSKIP, u32, XERCES_CPP_NAMESPACE_QUALIFIER, and xmlDocGetRootElement.

void testGetBoundaries  ) 
 

void testIdByte  ) 
 

Definition at line 432 of file testPlatform.cpp.

References getTestInputString(), getTestName(), SMBIOSGetDellSystemId(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testIsDell  ) 
 

Definition at line 634 of file testPlatform.cpp.

References getTestInputString(), getTestName(), SMBIOSIsDellSystem(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testOutOfBounds  ) 
 

Definition at line 784 of file testPlatform.cpp.

References ASSERT_THROWS, ISmbiosTable::const_iterator, doc, DOMElement, xmlutils::findElement(), SmbiosFactory::getFactory(), getTestName(), STD_TEST_END, STD_TEST_START_CHECKSKIP, XERCES_CPP_NAMESPACE_QUALIFIER, and xmlDocGetRootElement.

void testServiceTag  ) 
 

Definition at line 470 of file testPlatform.cpp.

References getTestInputString(), getTestName(), safeConvertToString(), SMBIOSGetServiceTag(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testServiceTagWriting  ) 
 

Definition at line 486 of file testPlatform.cpp.

References getServiceTagFromCMOSToken(), getTestInputString(), getTestName(), safeConvertToString(), SMBIOSGetServiceTag(), SMBIOSSetServiceTag(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testStateBytes  ) 
 

Definition at line 704 of file testPlatform.cpp.

References getTestName(), SMBIOSGetNvramStateBytes(), SMBIOSHasNvramStateBytes(), SMBIOSSetNvramStateBytes(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testSystemInfo  ) 
 

Definition at line 353 of file testPlatform.cpp.

References getTestName(), SMBIOSFreeMemory(), SMBIOSGetAssetTag(), SMBIOSGetBiosVersion(), SMBIOSGetDellSystemId(), SMBIOSGetServiceTag(), SMBIOSGetSystemName(), SMBIOSGetVendorName(), SMBIOSIsDellSystem(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testSystemName  ) 
 

Definition at line 458 of file testPlatform.cpp.

References getTestInputString(), getTestName(), safeConvertToString(), SMBIOSGetSystemName(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testUpBoot  ) 
 

Definition at line 760 of file testPlatform.cpp.

References getTestName(), SMBIOSGetBootToUp(), SMBIOSHasBootToUp(), SMBIOSSetBootToUp(), STD_TEST_END, and STD_TEST_START_CHECKSKIP.

void testVariousAccessors  ) 
 

Definition at line 648 of file testPlatform.cpp.

References ISmbiosTable::const_iterator, doc, DOMElement, xmlutils::findElement(), SmbiosFactory::getFactory(), xmlutils::getNodeText(), smbios::getString_FromItem(), getTestName(), STD_TEST_END, STD_TEST_START_CHECKSKIP, XERCES_CPP_NAMESPACE_QUALIFIER, and xmlDocGetRootElement.


Member Data Documentation

XML_NAMESPACE DOMDocument* doc [protected]
 

Definition at line 76 of file testPlatform.h.

Referenced by checkSkipTest(), getTestInputString(), setUp(), tearDown(), testConstructionOffset1(), testConstructionOffset2(), testOutOfBounds(), and testVariousAccessors().

XML_NAMESPACE DOMBuilder* parser [protected]
 

Definition at line 71 of file testPlatform.h.

Referenced by setUp(), and tearDown().


The documentation for this class was generated from the following files:
Generated on Tue Feb 26 14:39:02 2008 for SMBIOS Library by  doxygen 1.3.9.1