summaryrefslogtreecommitdiff
path: root/tests/functional/basic.php
blob: 19d9ca8d22be491f5e40950298dd7b9ddf418bb7 (plain)
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
<?php
class BasicTest extends PHPUnit_Extensions_Selenium2TestCase {

	public function setUp() {
		$this->setHost('localhost');
		$this->setPort(4444);
		$this->setBrowserUrl('http://localhost/tt-rss/');
		$this->setBrowser('firefox');
	}

	public function setUpPage() {
		$this->timeouts()->implicitWait(10000);
	}

	public function testLogin() {
		$this->url('/index.php');

		$this->byName("login")->value('admin');
		$this->byName("password")->value('password');
		$this->byCssSelector('#dijit_form_Button_0_label')->click();

		$this->byCssSelector('#feedTree')->displayed();
	}

	public function testOpenFeed() {
		$this->testLogin();

		$this->byCssSelector('#dijit__TreeNode_3')->click();

		$this->byCssSelector('#RROW-1 > div.cdmHeader')->displayed();
	}
}