function AkamaiTestCase::testDirectClear in Akamai 7.2
Same name and namespace in other branches
- 8 akamai.test \AkamaiTestCase::testDirectClear()
- 8.2 akamai.test \AkamaiTestCase::testDirectClear()
- 7.3 akamai.test \AkamaiTestCase::testDirectClear()
- 7 akamai.test \AkamaiTestCase::testDirectClear()
Tests clear.
File
- ./
akamai.test, line 31 - Akamai tests.
Class
- AkamaiTestCase
- Test basic API.
Code
function testDirectClear() {
$node = $this
->drupalCreateNode(array(
'type' => 'page',
'promote' => 1,
));
$canonical = "node/{$node->nid}";
$akamai = akamai_get_class();
$akamai
->clear_url($canonical);
$paths = $akamai->paths;
$this
->assertEqual(1, count($paths), "Only one path cleared");
$this
->assertEqual($canonical, $paths[0]);
}