Total Complexity | 3 |
Total Lines | 48 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
20 | class LanguageTest extends PreconditionSet |
||
21 | { |
||
22 | /** |
||
23 | * Set up the preconditon. |
||
24 | */ |
||
25 | function setUp() |
||
26 | { |
||
27 | global $webUrl; |
||
28 | global $SUPER_USER_NAME; |
||
29 | global $SUPER_USER_PASSWORD; |
||
30 | |||
31 | $this->login($SUPER_USER_NAME, $SUPER_USER_PASSWORD, |
||
32 | "$webUrl/login.php"); |
||
33 | |||
34 | return TRUE; |
||
35 | } |
||
36 | |||
37 | |||
38 | /** |
||
39 | * Release the relational resource. |
||
40 | */ |
||
41 | function tearDown() |
||
42 | { |
||
43 | // Logout this system. |
||
44 | $this->logout(); |
||
45 | |||
46 | return TRUE; |
||
47 | } |
||
48 | |||
49 | |||
50 | /** |
||
51 | * TestCaseId: DLD001 |
||
52 | * This test is used to test Language Displayed page. |
||
53 | */ |
||
54 | function testLanguage() |
||
55 | { |
||
56 | global $webUrl, $SERVER, $DATABASE; |
||
57 | |||
58 | // Locate the list page of language. |
||
59 | $this->assertTrue($this->get("$webUrl/languages.php", array( |
||
60 | 'server' => $SERVER, |
||
61 | 'database' => $DATABASE, |
||
62 | 'subject' => 'database')) |
||
63 | ); |
||
64 | |||
65 | $this->assertWantedPattern('/sql/'); |
||
66 | |||
67 | return TRUE; |
||
68 | } |
||
72 |