r65983 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r65982‎ | r65983 | r65984 >
Date:12:30, 6 May 2010
Author:bhagya
Status:deferred
Tags:
Comment:
On error screenshot of the page will be taken. updated all the error handlers. Added a common function to the Common function and updated the config file with new configurations.
Modified paths:
  • /trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/Config.php (modified) (history)
  • /trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikSearch_TC.php (modified) (history)
  • /trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiCommonFunction_TC.php (modified) (history)
  • /trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiDialogs_TC.php (modified) (history)
  • /trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiNTOC_TC.php (modified) (history)
  • /trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiTextFormat_TC.php (modified) (history)
  • /trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiToolBarOther_TC.php (modified) (history)
  • /trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiWatchUnWatch_TC.php (modified) (history)

Diff [purge]

Index: trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiDialogs_TC.php
@@ -22,6 +22,7 @@
2323 try {
2424 $this->assertEquals($_SESSION["WIKI_INTERNAL_LINK"], $this->getText("link=" . $_SESSION["WIKI_INTERNAL_LINK"]));
2525 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 26+ parent::doCreateScreenShot(__FUNCTION__);
2627 array_push($this->verificationErrors, $e->toString());
2728 }
2829 $this->click("link=Daimler-Chrysler");
@@ -29,6 +30,7 @@
3031 try {
3132 $this->assertTrue($this->isTextPresent($_SESSION["WIKI_INTERNAL_LINK"]), $this->getText("firstHeading"));
3233 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 34+ parent::doCreateScreenShot(__FUNCTION__);
3335 array_push($this->verificationErrors, $e->toString());
3436 }
3537 }
@@ -48,6 +50,7 @@
4951 try {
5052 $this->assertEquals($_SESSION["WIKI_INTERNAL_LINK"]." Test", $this->getText("link=" .$_SESSION["WIKI_INTERNAL_LINK"] ." Test"));
5153 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 54+ parent::doCreateScreenShot(__FUNCTION__);
5255 array_push($this->verificationErrors, $e->toString());
5356 }
5457 $this->click("link=" .$_SESSION["WIKI_INTERNAL_LINK"]." Test");
@@ -55,6 +58,7 @@
5659 try {
5760 $this->assertTrue($this->isTextPresent($_SESSION["WIKI_INTERNAL_LINK"]), $this->getText("firstHeading"));
5861 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 62+ parent::doCreateScreenShot(__FUNCTION__);
5963 array_push($this->verificationErrors, $e->toString());
6064 }
6165 }
@@ -72,6 +76,7 @@
7377 try {
7478 $this->assertEquals($_SESSION["WIKI_INTERNAL_LINK"], $this->getText("link=".$_SESSION["WIKI_INTERNAL_LINK"]));
7579 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 80+ parent::doCreateScreenShot(__FUNCTION__);
7681 array_push($this->verificationErrors, $e->toString());
7782 }
7883 $this->click("link=".$_SESSION["WIKI_INTERNAL_LINK"]);
@@ -79,6 +84,7 @@
8085 try {
8186 $this->assertEquals($_SESSION["WIKI_INTERNAL_LINK"], $this->getText("firstHeading"));
8287 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 88+ parent::doCreateScreenShot(__FUNCTION__);
8389 array_push($this->verificationErrors, $e->toString());
8490 }
8591 }
@@ -91,6 +97,7 @@
9298 try {
9399 $this->assertEquals("External link", $this->getText("wikieditor-toolbar-link-int-target-status-external"));
94100 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 101+ parent::doCreateScreenShot(__FUNCTION__);
95102 array_push($this->verificationErrors, $e->toString());
96103 }
97104 $this->assertEquals("on", $this->getValue("wikieditor-toolbar-link-type-ext"));
@@ -100,6 +107,7 @@
101108 try {
102109 $this->assertEquals($_SESSION["WIKI_EXTERNAL_LINK"], $this->getText("link=".$_SESSION["WIKI_EXTERNAL_LINK"]));
103110 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 111+ parent::doCreateScreenShot(__FUNCTION__);
104112 array_push($this->verificationErrors, $e->toString());
105113 }
106114 $this->click("link=".$_SESSION["WIKI_EXTERNAL_LINK"]);
@@ -107,6 +115,7 @@
108116 try {
109117 $this->assertEquals($_SESSION["WIKI_EXTERNAL_LINK_TITLE"], $this->getTitle());
110118 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 119+ parent::doCreateScreenShot(__FUNCTION__);
111120 array_push($this->verificationErrors, $e->toString());
112121 }
113122 }
@@ -120,6 +129,7 @@
121130 try {
122131 $this->assertEquals("External link", $this->getText("wikieditor-toolbar-link-int-target-status-external"));
123132 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 133+ parent::doCreateScreenShot(__FUNCTION__);
124134 array_push($this->verificationErrors, $e->toString());
125135 }
126136 $this->assertEquals("on", $this->getValue("wikieditor-toolbar-link-type-ext"));
@@ -129,6 +139,7 @@
130140 try {
131141 $this->assertEquals($_SESSION["WIKI_EXTERNAL_LINK_TITLE"], $this->getText("link=".$_SESSION["WIKI_EXTERNAL_LINK_TITLE"]));
132142 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 143+ parent::doCreateScreenShot(__FUNCTION__);
133144 array_push($this->verificationErrors, $e->toString());
134145 }
135146 $this->click("link=".$_SESSION["WIKI_EXTERNAL_LINK_TITLE"]);
@@ -136,6 +147,7 @@
137148 try {
138149 $this->assertEquals($_SESSION["WIKI_EXTERNAL_LINK_TITLE"], $this->getTitle());
139150 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 151+ parent::doCreateScreenShot(__FUNCTION__);
140152 array_push($this->verificationErrors, $e->toString());
141153 }
142154
@@ -150,6 +162,7 @@
151163 try {
152164 $this->assertEquals("External link", $this->getText("wikieditor-toolbar-link-int-target-status-external"));
153165 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 166+ parent::doCreateScreenShot(__FUNCTION__);
154167 array_push($this->verificationErrors, $e->toString());
155168 }
156169 $this->assertEquals("on", $this->getValue("wikieditor-toolbar-link-type-ext"));
@@ -159,6 +172,7 @@
160173 try {
161174 $this->assertEquals("[1]", $this->getText("link=[1]"));
162175 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 176+ parent::doCreateScreenShot(__FUNCTION__);
163177 array_push($this->verificationErrors, $e->toString());
164178 }
165179 $this->click("link=[1]");
@@ -166,6 +180,7 @@
167181 try {
168182 $this->assertEquals($_SESSION["WIKI_EXTERNAL_LINK_TITLE"], $this->getTitle());
169183 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 184+ parent::doCreateScreenShot(__FUNCTION__);
170185 array_push($this->verificationErrors, $e->toString());
171186 }
172187 }
@@ -184,6 +199,7 @@
185200 try {
186201 $this->assertEquals("Header text", $this->getText("//table[@id='sortable_table_id_0']/tbody/tr[1]/th[3]"));
187202 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 203+ parent::doCreateScreenShot(__FUNCTION__);
188204 array_push($this->verificationErrors, $e->toString());
189205 }
190206 }
@@ -203,6 +219,7 @@
204220 try {
205221 $this->assertEquals("Header text", $this->getTable("//div[@id='wikiPreview']/table.0.0"));
206222 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 223+ parent::doCreateScreenShot(__FUNCTION__);
207224 array_push($this->verificationErrors, $e->toString());
208225 }
209226 }
@@ -220,6 +237,7 @@
221238 try {
222239 $this->assertEquals("Example", $this->getTable("//div[@id='wikiPreview']/table.1.3"));
223240 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 241+ parent::doCreateScreenShot(__FUNCTION__);
224242 array_push($this->verificationErrors, $e->toString());
225243 }
226244 }
@@ -242,6 +260,7 @@
243261 try {
244262 $this->assertEquals("Example", $this->getTable("sortable_table_id_0.0.0"));
245263 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 264+ parent::doCreateScreenShot(__FUNCTION__);
246265 array_push($this->verificationErrors, $e->toString());
247266 }
248267 }
@@ -263,6 +282,7 @@
264283 try {
265284 $this->assertEquals("Example", $this->getTable("//div[@id='wikiPreview']/table.0.0"));
266285 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 286+ parent::doCreateScreenShot(__FUNCTION__);
267287 array_push($this->verificationErrors, $e->toString());
268288 }
269289 }
@@ -282,16 +302,19 @@
283303 try {
284304 $this->assertEquals($_SESSION["WIKI_REPLACE_TEXT"], $this->getText("//div[@id='wikiPreview']/p[1]"));
285305 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 306+ parent::doCreateScreenShot(__FUNCTION__);
286307 array_push($this->verificationErrors, $e->toString());
287308 }
288309 try {
289310 $this->assertEquals($_SESSION["WIKI_REPLACE_TEXT"], $this->getText("//div[@id='wikiPreview']/p[2]"));
290311 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 312+ parent::doCreateScreenShot(__FUNCTION__);
291313 array_push($this->verificationErrors, $e->toString());
292314 }
293315 try {
294316 $this->assertEquals($_SESSION["WIKI_REPLACE_TEXT"], $this->getText("//div[@id='wikiPreview']/p[3]"));
295317 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 318+ parent::doCreateScreenShot(__FUNCTION__);
296319 array_push($this->verificationErrors, $e->toString());
297320 }
298321 }
@@ -314,16 +337,19 @@
315338 try {
316339 $this->assertEquals($_SESSION["WIKI_REPLACE_TEXT"], $this->getText("//div[@id='wikiPreview']/p[1]"));
317340 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 341+ parent::doCreateScreenShot(__FUNCTION__);
318342 array_push($this->verificationErrors, $e->toString());
319343 }
320344 try {
321345 $this->assertEquals($_SESSION["WIKI_REPLACE_TEXT"], $this->getText("//div[@id='wikiPreview']/p[2]"));
322346 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 347+ parent::doCreateScreenShot(__FUNCTION__);
323348 array_push($this->verificationErrors, $e->toString());
324349 }
325350 try {
326351 $this->assertEquals($_SESSION["WIKI_SEARCH_TEXT"], $this->getText("//div[@id='wikiPreview']/p[3]"));
327352 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 353+ parent::doCreateScreenShot(__FUNCTION__);
328354 array_push($this->verificationErrors, $e->toString());
329355 }
330356 }
Index: trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/Config.php
@@ -18,4 +18,8 @@
1919 $_SESSION["WIKI_SAMPLE_TEXT"] = "calcey qa\n\ncalcey qa\n\ncalcey qa"; // String to type in the editor to use for search and replace
2020 $_SESSION["WIKI_SEARCH_TEXT"] = "calcey qa"; // Text use for search
2121 $_SESSION["WIKI_REPLACE_TEXT"] = "test team" ; // Text use for replace search text
 22+$_SESSION["WIKI_CODE_PATH"] = getcwd();
 23+$_SESSION["WIKI_SCREENSHOTS_PATH"] = "screenshots";
 24+$_SESSION["WIKI_SCREENSHOTS_TYPE"] = "png";
 25+
2226 ?>
Index: trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikSearch_TC.php
@@ -1,5 +1,7 @@
22 <?php
33 session_start();
 4+require_once('log4php/Logger.php');
 5+Logger::configure('log4php.properties');
46 require_once 'WikiCommonFunction_TC.php';
57 require_once 'Config.php';
68
@@ -9,14 +11,18 @@
1012 * @author : BhagyaG - Calcey
1113 */
1214 class WikiSearch_TC extends WikiCommonFunction_TC {
13 -
 15+ private $logger;
 16+
1417 // Set up the testing environment
1518 function setup(){
1619 parent::setUp();
 20+ $this->logger = Logger::getLogger(__CLASS__);
1721 }
1822
 23+
1924 // Search for a Wiki Page. Search result should be directed to the page itself
2025 function testSearchPage(){
 26+ $this->logger->info('Test Search Page - Start');
2127 parent::doOpenLink();
2228 parent::doLogin();
2329 $this->click("link=Main page");
@@ -26,13 +32,16 @@
2733 try {
2834 $this->assertEquals($_SESSION["WIKI_SEARCH_PAGE"], $this->getText("//*[@id='firstHeading']"));
2935 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 36+ parent::doCreateScreenShot(__FUNCTION__);
3037 array_push($this->verificationErrors, $e->toString());
3138 }
3239 $this->click("link=Main page");
3340 $this->waitForPageToLoad($_SESSION["WIKI_TEST_WAIT_TIME"]);
3441 parent::doLogout();
35 - }
 42+ $this->logger->info('Test Search Page - End');
 43+ }
3644
 45+
3746 // Search for a text. Search result should display links which contain the search text
3847 function testSearchText(){
3948 parent::doOpenLink();
@@ -45,11 +54,13 @@
4655 try {
4756 $this->assertEquals("Search results", $this->getText("firstHeading"));
4857 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 58+ parent::doCreateScreenShot(__FUNCTION__);
4959 array_push($this->verificationErrors, $e->toString());
5060 }
5161 try {
5262 $this->assertEquals($_SESSION["WIKI_SEARCH_TEXT"] . " - Search results - Wikipedia, the free encyclopedia", $this->getTitle());
5363 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 64+ parent::doCreateScreenShot(__FUNCTION__);
5465 array_push($this->verificationErrors, $e->toString());
5566 }
5667 parent::doLogout();
Index: trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiTextFormat_TC.php
@@ -19,6 +19,7 @@
2020 try {
2121 $this->assertEquals("Bold", $this->getText("//div[@id='wikiPreview']/p/b"));
2222 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 23+ parent::doCreateScreenShot(__FUNCTION__);
2324 array_push($this->verificationErrors, $e->toString());
2425 }
2526 }
@@ -30,7 +31,12 @@
3132 $this->type("wpTextbox1", "''Italian'' text");
3233 $this->click("wpPreview");
3334 $this->waitForPageToLoad($_SESSION["WIKI_TEST_WAIT_TIME"]);
34 - $this->assertEquals("Italian", $this->getText("//div[@id='wikiPreview']/p/i"));
 35+ try {
 36+ $this->assertEquals("Italian", $this->getText("//div[@id='wikiPreview']/p/i"));
 37+ } catch (PHPUnit_Framework_AssertionFailedError $e) {
 38+ parent::doCreateScreenShot(__FUNCTION__);
 39+ array_push($this->verificationErrors, $e->toString());
 40+ }
3541 }
3642
3743 // Mark text Bold and Italic and verify output
@@ -41,7 +47,12 @@
4248 $this->type("wpTextbox1", "Text '''''Italic & Bold'''''");
4349 $this->click("wpPreview");
4450 $this->waitForPageToLoad($_SESSION["WIKI_TEST_WAIT_TIME"]);
45 - $this->assertEquals("Italic & Bold", $this->getText("//div[@id='wikiPreview']/p/i/b"));
 51+ try {
 52+ $this->assertEquals("Italic & Bold", $this->getText("//div[@id='wikiPreview']/p/i/b"));
 53+ } catch (PHPUnit_Framework_AssertionFailedError $e) {
 54+ parent::doCreateScreenShot(__FUNCTION__);
 55+ array_push($this->verificationErrors, $e->toString());
 56+ }
4657 }
4758
4859
@@ -58,16 +69,19 @@
5970 try {
6071 $this->assertEquals("Bulleted list item", $this->getText("//div[@id='wikiPreview']/ul/li[1]"));
6172 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 73+ parent::doCreateScreenShot(__FUNCTION__);
6274 array_push($this->verificationErrors, $e->toString());
6375 }
6476 try {
6577 $this->assertEquals("Bulleted list item", $this->getText("//div[@id='wikiPreview']/ul/li[2]"));
6678 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 79+ parent::doCreateScreenShot(__FUNCTION__);
6780 array_push($this->verificationErrors, $e->toString());
6881 }
6982 try {
7083 $this->assertEquals("Bulleted list item", $this->getText("//div[@id='wikiPreview']/ul/li[3]"));
7184 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 85+ parent::doCreateScreenShot(__FUNCTION__);
7286 array_push($this->verificationErrors, $e->toString());
7387 }
7488 }
@@ -85,16 +99,19 @@
86100 try {
87101 $this->assertEquals("Numbered list item", $this->getText("//div[@id='wikiPreview']/ol/li[1]"));
88102 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 103+ parent::doCreateScreenShot(__FUNCTION__);
89104 array_push($this->verificationErrors, $e->toString());
90105 }
91106 try {
92107 $this->assertEquals("Numbered list item", $this->getText("//div[@id='wikiPreview']/ol/li[2]"));
93108 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 109+ parent::doCreateScreenShot(__FUNCTION__);
94110 array_push($this->verificationErrors, $e->toString());
95111 }
96112 try {
97113 $this->assertEquals("Numbered list item", $this->getText("//div[@id='wikiPreview']/ol/li[3]"));
98114 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 115+ parent::doCreateScreenShot(__FUNCTION__);
99116 array_push($this->verificationErrors, $e->toString());
100117 }
101118 }
@@ -109,6 +126,7 @@
110127 try {
111128 $this->assertEquals("==Heading text==", $this->getText("//div[@id='wikiPreview']/p"));
112129 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 130+ parent::doCreateScreenShot(__FUNCTION__);
113131 array_push($this->verificationErrors, $e->toString());
114132 }
115133 }
@@ -123,6 +141,7 @@
124142 try {
125143 $this->assertEquals("this is a test text to check the line\n break.", $this->getText("//div[@id='wikiPreview']/p"));
126144 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 145+ parent::doCreateScreenShot(__FUNCTION__);
127146 array_push($this->verificationErrors, $e->toString());
128147 }
129148 }
@@ -138,6 +157,7 @@
139158 try {
140159 $this->assertEquals("This", $this->getText("//div[@id='wikiPreview']/p/big"));
141160 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 161+ parent::doCreateScreenShot(__FUNCTION__);
142162 array_push($this->verificationErrors, $e->toString());
143163 }
144164 }
@@ -153,6 +173,7 @@
154174 try {
155175 $this->assertEquals("This", $this->getText("//div[@id='wikiPreview']/p/small"));
156176 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 177+ parent::doCreateScreenShot(__FUNCTION__);
157178 array_push($this->verificationErrors, $e->toString());
158179 }
159180 }
@@ -168,6 +189,7 @@
169190 try {
170191 $this->assertEquals("This", $this->getText("//div[@id='wikiPreview']/p/sup"));
171192 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 193+ parent::doCreateScreenShot(__FUNCTION__);
172194 array_push($this->verificationErrors, $e->toString());
173195 }
174196 }
@@ -183,6 +205,7 @@
184206 try {
185207 $this->assertEquals("This", $this->getText("//div[@id='wikiPreview']/p/sub"));
186208 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 209+ parent::doCreateScreenShot(__FUNCTION__);
187210 array_push($this->verificationErrors, $e->toString());
188211 }
189212 }
Index: trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiCommonFunction_TC.php
@@ -98,5 +98,11 @@
9999 $this->click("//li[@id='ca-edit']/a/span");
100100 $this->waitForPageToLoad($_SESSION["WIKI_TEST_WAIT_TIME"]);
101101 }
 102+
 103+ //Screenshot create on error
 104+ function doCreateScreenShot($file_name){
 105+ $this->captureEntirePageScreenshot($_SESSION["WIKI_CODE_PATH"] . "\/". $_SESSION["WIKI_SCREENSHOTS_PATH"] ."\/". $file_name . "_error" . date("Y_m_d") . "." . $_SESSION["WIKI_SCREENSHOTS_TYPE"] , "");
 106+ }
 107+
102108 }
103109 ?>
\ No newline at end of file
Index: trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiWatchUnWatch_TC.php
@@ -25,8 +25,13 @@
2626 $this->waitForPageToLoad("30000");
2727 $this->click("link=View and edit watchlist");
2828 $this->waitForPageToLoad("30000");
29 -
30 - $this->assertTrue($this->isTextPresent($randompage));
 29+ try {
 30+ $this->assertTrue($this->isTextPresent($randompage));
 31+ } catch (PHPUnit_Framework_AssertionFailedError $e) {
 32+ parent::doCreateScreenShot(__FUNCTION__);
 33+ array_push($this->verificationErrors, $e->toString());
 34+ }
 35+
3136 parent::doLogout();
3237 }
3338
@@ -55,6 +60,7 @@
5661 try {
5762 $this->assertFalse($this->isTextPresent($randompage));
5863 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 64+ parent::doCreateScreenShot(__FUNCTION__);
5965 array_push($this->verificationErrors, $e->toString());
6066 }
6167 parent::doLogout();
Index: trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiNTOC_TC.php
@@ -23,6 +23,7 @@
2424 try {
2525 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h2"));
2626 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 27+ parent::doCreateScreenShot(__FUNCTION__);
2728 array_push($this->verificationErrors, $e->toString());
2829 }
2930 }
@@ -40,6 +41,7 @@
4142 try {
4243 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h3"));
4344 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 45+ parent::doCreateScreenShot(__FUNCTION__);
4446 array_push($this->verificationErrors, $e->toString());
4547 }
4648 }
@@ -56,6 +58,7 @@
5759 try {
5860 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h4"));
5961 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 62+ parent::doCreateScreenShot(__FUNCTION__);
6063 array_push($this->verificationErrors, $e->toString());
6164 }
6265 }
@@ -72,6 +75,7 @@
7376 try {
7477 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h5"));
7578 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 79+ parent::doCreateScreenShot(__FUNCTION__);
7680 array_push($this->verificationErrors, $e->toString());
7781 }
7882 }
@@ -94,6 +98,7 @@
9599 try {
96100 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h3"));
97101 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 102+ parent::doCreateScreenShot(__FUNCTION__);
98103 array_push($this->verificationErrors, $e->toString());
99104 }
100105 }
@@ -113,16 +118,19 @@
114119 try {
115120 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h2"));
116121 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 122+ parent::doCreateScreenShot(__FUNCTION__);
117123 array_push($this->verificationErrors, $e->toString());
118124 }
119125 try {
120126 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h3"));
121127 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 128+ parent::doCreateScreenShot(__FUNCTION__);
122129 array_push($this->verificationErrors, $e->toString());
123130 }
124131 try {
125132 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h4"));
126133 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 134+ parent::doCreateScreenShot(__FUNCTION__);
127135 array_push($this->verificationErrors, $e->toString());
128136 }
129137 }
@@ -144,21 +152,25 @@
145153 try {
146154 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h2"));
147155 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 156+ parent::doCreateScreenShot(__FUNCTION__);
148157 array_push($this->verificationErrors, $e->toString());
149158 }
150159 try {
151160 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h3"));
152161 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 162+ parent::doCreateScreenShot(__FUNCTION__);
153163 array_push($this->verificationErrors, $e->toString());
154164 }
155165 try {
156166 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h4"));
157167 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 168+ parent::doCreateScreenShot(__FUNCTION__);
158169 array_push($this->verificationErrors, $e->toString());
159170 }
160171 try {
161172 $this->assertEquals("Heading text", $this->getText("//*[@id='wikiPreview']/h5"));
162173 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 174+ parent::doCreateScreenShot(__FUNCTION__);
163175 array_push($this->verificationErrors, $e->toString());
164176 }
165177 }
Index: trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/testCases/WikiToolBarOther_TC.php
@@ -18,6 +18,7 @@
1919 try {
2020 $this->assertEquals("", $this->getText("//img[@alt='Example.jpg']"));
2121 } catch (PHPUnit_Framework_AssertionFailedError $e) {
 22+ parent::doCreateScreenShot(__FUNCTION__);
2223 array_push($this->verificationErrors, $e->toString());
2324 }
2425 }
@@ -52,6 +53,7 @@
5354 $this->click("wpPreview");
5455 $this->waitForPageToLoad($_SESSION["WIKI_TEST_WAIT_TIME"]);
5556 try {
 57+ parent::doCreateScreenShot(__FUNCTION__);
5658 $this->assertEquals("", $this->getText("//div[@id='wikiPreview']/table/tbody/tr/td[1]/div/div[1]/div"));
5759 } catch (PHPUnit_Framework_AssertionFailedError $e) {
5860 array_push($this->verificationErrors, $e->toString());

Status & tagging log