-
Notifications
You must be signed in to change notification settings - Fork 402
/
Copy pathWebMapPublicTest.php
30 lines (24 loc) · 1.06 KB
/
WebMapPublicTest.php
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
<?php
include_once dirname(__FILE__) . '/OpenFlightsSeleniumTestCase.php';
class WebMapPublicTest extends OpenFlightsSeleniumTestCase {
public function testPublicUserMapAsAnonymous() {
global $settings;
$this->open("/user/" . $settings['name']);
$this->verifyTextPresent("${settings['name']}'s flights");
# Analyze
$this->click("//input[@value='Analyze']");
$this->verifyTextPresent("Total flown");
$this->verifyTextPresent("1000 mi");
# Top 10
$this->click("//input[@value='Top 10']");
$this->verifyTextPresent("Lifou (LIF)");
$this->click('link=LIF');
$this->verifyTextPresent("Lifou, New Caledonia");
$this->click("//img[@onclick='JavaScript:closePopup(true);']");
$this->click('link=Decatur Aviation');
$this->verifyTextPresent($settings['name'] . "'s flights on Decatur Aviation");
# Back to the main map
$this->select('Airlines', 'label=All carriers');
$this->verifyTextPresent($settings['name'] . "'s flights");
}
}