summaryrefslogtreecommitdiff
path: root/tests/FunctionalTests/active-controls/tests/DelayedCallbackTestCase.php
blob: 49c268ad80d6d8b8cedf76f73350f773aac09f26 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<?php

class DelayedCallbackTestCase extends PradoGenericSelenium2Test
{
	function test()
	{
		$base='ctl0_Content_';
		$this->url("active-controls/index.php?page=DelayedCallback");
		$this->assertContains("Delayed Callback Test", $this->source());

		$this->assertText("{$base}status", "");
		$this->byId("{$base}button1")->click();
		$this->byId("{$base}button2")->click();

		$this->pause("5000");
		$this->assertText("{$base}status", "Callback 1 returned after 4s");
		$this->pause("3000");
		$this->assertText("{$base}status", "Callback 2 delayed 2s");

	}
}