ILIAS  Release_4_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilXHTMLPageTest Class Reference
+ Inheritance diagram for ilXHTMLPageTest:
+ Collaboration diagram for ilXHTMLPageTest:

Public Member Functions

 testSetGetSettings ()

Protected Member Functions

 setUp ()

Protected Attributes

 $backupGlobals = FALSE

Detailed Description

Definition at line 24 of file ilXHTMLPageTest.php.

Member Function Documentation

ilXHTMLPageTest::setUp ( )
protected

Definition at line 28 of file ilXHTMLPageTest.php.

References ilUnitUtil\performInitialisation().

{
include_once("./Services/PHPUnit/classes/class.ilUnitUtil.php");
}

+ Here is the call graph for this function:

ilXHTMLPageTest::testSetGetSettings ( )

Definition at line 34 of file ilXHTMLPageTest.php.

References $result, ilXHTMLPage\_lookupContent(), and ilXHTMLPage\_lookupSavedContent().

{
include_once("./Services/XHTMLPage/classes/class.ilXHTMLPage.php");
$page = new ilXHTMLPage();
$page->setContent("aaa");
$page->save();
$page_id = $page->getId();
// save/read
$page = new ilXHTMLPage($page_id);
if ($page->getContent() == "aaa")
{
$result.= "saveread-";
}
$page->setContent("bbb");
$page->save();
// lookups
if (ilXHTMLPage::_lookupContent($page_id) == "bbb")
{
$result.= "lookupContent-";
}
if (ilXHTMLPage::_lookupSavedContent($page_id) == "aaa")
{
$result.= "lookupSavedContent-";
}
// undo
$page->undo();
if (ilXHTMLPage::_lookupContent($page_id) == "aaa")
{
$result.= "undo1-";
}
if (ilXHTMLPage::_lookupSavedContent($page_id) == "bbb")
{
$result.= "undo2-";
}
// clear
$page->clear();
if (ilXHTMLPage::_lookupContent($page_id) == "")
{
$result.= "clear1-";
}
if (ilXHTMLPage::_lookupSavedContent($page_id) == "aaa")
{
$result.= "clear2-";
}
$this->assertEquals("saveread-lookupContent-lookupSavedContent-undo1-undo2-clear1-clear2-", $result);
}

+ Here is the call graph for this function:

Field Documentation

ilXHTMLPageTest::$backupGlobals = FALSE
protected

Definition at line 26 of file ilXHTMLPageTest.php.


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