forked from janodvarko/harviewer
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest1.php
More file actions
49 lines (43 loc) · 1.29 KB
/
Copy pathtest1.php
File metadata and controls
49 lines (43 loc) · 1.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<?php
require_once("PHPUnit/Extensions/SeleniumTestCase.php");
require_once("config.php");
/**
* Run several browsers and check if HAR Viewer is properly initialized.
*/
class HAR_Test1 extends PHPUnit_Extensions_SeleniumTestCase
{
public static $browsers = array(
array(
'name' => 'Firefox on Windows',
'browser' => '*firefox',
'port' => 4444,
'timeout' => 30000,
),
array(
'name' => 'Internet Explorer on Windows XP',
'browser' => '*iexplore',
'port' => 4444,
'timeout' => 30000,
)
);
protected function setUp()
{
print "\nHAR Test1::setUp()";
$this->setBrowserUrl($GLOBALS["harviewer_base"]);
//$this->setSleep(5);
}
protected function tearDown()
{
print "\nHAR Test1::tearDown()";
}
public function testTabs()
{
print "\nHAR Test1::testTabs()";
$this->open($GLOBALS["harviewer_base"]);
$this->assertElementContainsText("css=.HomeTab", "Home");
$this->assertElementContainsText("css=.PreviewTab", "Preview");
$this->assertElementContainsText("css=.DOMTab", "HAR");
$this->assertElementContainsText("css=.SchemaTab", "Schema");
}
}
?>