Index: trunk/extensions/PagedTiffHandler/selenium/PagedTiffHandlerTestCases.php |
— | — | @@ -6,7 +6,7 @@ |
7 | 7 | public function runTest() { |
8 | 8 | |
9 | 9 | // check whether Multipage.tiff is already uploaded |
10 | | - $this->open( Selenium::getBaseUrl() . |
| 10 | + $this->open( $this->getUrl() . |
11 | 11 | '/index.php?title=Image:Multipage.tiff' ); |
12 | 12 | |
13 | 13 | $source = $this->getAttribute( "//div[@id='bodyContent']//ul@id" ); |
— | — | @@ -15,7 +15,7 @@ |
16 | 16 | } |
17 | 17 | |
18 | 18 | // Check for language |
19 | | - $this->open( Selenium::getBaseUrl() . |
| 19 | + $this->open( $this->getUrl() . |
20 | 20 | '/api.php?action=query&meta=userinfo&uiprop=options&format=xml'); |
21 | 21 | |
22 | 22 | $lang = $this->getAttribute( "//options/@language" ); |
— | — | @@ -28,8 +28,8 @@ |
29 | 29 | |
30 | 30 | public function tearDown() { |
31 | 31 | if ( $this->prerequisiteError ) { |
32 | | - $this->selenium->stop(); |
33 | | - die( 'failed: ' . $this->prerequisiteError . "\n" ); |
| 32 | + //$this->selenium->stop(); |
| 33 | + throw new MWException( 'failed: ' . $this->prerequisiteError . "\n" ); |
34 | 34 | } |
35 | 35 | } |
36 | 36 | } |
— | — | @@ -37,7 +37,7 @@ |
38 | 38 | class SeleniumUploadTiffTest extends SeleniumTestCase { |
39 | 39 | public function uploadFile( $filename ) { |
40 | 40 | |
41 | | - $this->open( Selenium::getBaseUrl() . |
| 41 | + $this->open( $this->getUrl() . |
42 | 42 | '/index.php?title=Special:Upload' ); |
43 | 43 | $this->type( 'wpUploadFile', dirname( __FILE__ ) . |
44 | 44 | "\\testImages\\" . $filename ); |
— | — | @@ -104,7 +104,7 @@ |
105 | 105 | |
106 | 106 | public function runTest() { |
107 | 107 | |
108 | | - $this->open( Selenium::getBaseUrl() . '/index.php?title=Image:' |
| 108 | + $this->open( $this->getUrl() . '/index.php?title=Image:' |
109 | 109 | . ucfirst( $this->filename ) . '&action=delete' ); |
110 | 110 | $this->type( 'wpReason', 'Remove test file' ); |
111 | 111 | $this->click( 'mw-filedelete-submit' ); |
— | — | @@ -123,7 +123,7 @@ |
124 | 124 | |
125 | 125 | parent::tearDown(); |
126 | 126 | // Clear EmbedTiffTest page for future tests |
127 | | - $this->open( Selenium::getBaseUrl() . |
| 127 | + $this->open( $this->getUrl() . |
128 | 128 | '/index.php?title=EmbedTiffTest&action=edit' ); |
129 | 129 | $this->type( 'wpTextbox1', '' ); |
130 | 130 | $this->click( 'wpSave' ); |
— | — | @@ -131,7 +131,7 @@ |
132 | 132 | |
133 | 133 | public function preparePage( $text ) { |
134 | 134 | |
135 | | - $this->open( Selenium::getBaseUrl() . |
| 135 | + $this->open( $this->getUrl() . |
136 | 136 | '/index.php?title=EmbedTiffTest&action=edit' ); |
137 | 137 | $this->type( 'wpTextbox1', $text ); |
138 | 138 | $this->click( 'wpSave' ); |
— | — | @@ -144,7 +144,7 @@ |
145 | 145 | public function tearDown() { |
146 | 146 | parent::tearDown(); |
147 | 147 | // Clear EmbedTiffTest page for future tests |
148 | | - $this->open( Selenium::getBaseUrl() . '/index.php?title=Image:' |
| 148 | + $this->open( $this->getUrl() . '/index.php?title=Image:' |
149 | 149 | . $this->image . '&action=edit' ); |
150 | 150 | $this->type( 'wpTextbox1', '' ); |
151 | 151 | $this->click( 'wpSave' ); |
— | — | @@ -153,7 +153,7 @@ |
154 | 154 | public function prepareImagePage( $image, $text ) { |
155 | 155 | |
156 | 156 | $this->image = $image; |
157 | | - $this->open( Selenium::getBaseUrl() . '/index.php?title=Image:' |
| 157 | + $this->open( $this->getUrl() . '/index.php?title=Image:' |
158 | 158 | . $image . '&action=edit' ); |
159 | 159 | $this->type( 'wpTextbox1', $text ); |
160 | 160 | $this->click( 'wpSave' ); |
— | — | @@ -170,7 +170,7 @@ |
171 | 171 | "[[Category:Wiki]]\n" ); |
172 | 172 | |
173 | 173 | |
174 | | - $this->open( Selenium::getBaseUrl() . '/index.php?title=Category:Wiki' ); |
| 174 | + $this->open( $this->getUrl() . '/index.php?title=Category:Wiki' ); |
175 | 175 | |
176 | 176 | // Ergebnis chekcen |
177 | 177 | $source = $this->getAttribute( |