I can cause it to fail in the same test rather than the next test. I'll include an html results set of a suite of four tests to show you what I mean. The "halt" command is a custom one. If I leave it out, then the failure is usually on the next test. On the last test run, the failure is on the next "clickAndWait" command.

Jamie

Title: Categories Regression Test Suite Results
Suite NameCategories Regression Test Suite
Resultfailed
Total Time893
Tests Passed0
Test Failures4
Commands Passed68
Commands Failed0
Command Erros4
Browser InfoMozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.7.9) Gecko/20050713 Firefox/1.0.5 (PowerBook)
Categories Regression Test Suite
ManageWebCategoriesTest
AddAndEditProteinTest
AddAndEditIsoformTest
ManageBiotoolCategoriesTest
Categories Regression Test
open /catalog/Index.action go to the Catalog Home Page
verifyTextPresent Catalog Manager  
assertElementPresent dom=document.forms['gotoWebCategories'].submit  
clickAndWait dom=document.forms['gotoWebCategories'].submit  
verifyTitle Catalog Manager - viewWebCategories  
store _javascript_{tmpName("test-category");} categoryName
verifyElementPresent webCategory.name
type webCategory.name ${categoryName}
verifyElementPresent dom=document.forms['addWebCategory']['submit']
clickAndWait dom=document.forms['addWebCategory']['submit']
verifyTextPresent ${categoryName}
verifyElementPresent webCategory.description
store The Web Category Description webCategoryDescription
type webCategory.description ${webCategoryDescription}
verifyElementPresent webCategory.webTemplate
store web template goes here webTemplate
type webCategory.webTemplate ${webTemplate}
verifyElementPresent webCategory.displayOptions
store display options go here displayOptions
type webCategory.displayOptions ${displayOptions}
verifyElementPresent dom=document.forms['editWebCategory']['savePressed']
clickAndWait dom=document.forms['editWebCategory']['savePressed']
verifyValue webCategory.description ${webCategoryDescription}
verifyValue webCategory.webTemplate ${webTemplate}
verifyValue webCategory.displayOptions ${displayOptions}
verifyTextPresent ${categoryName} has changes that have not been published Verify message that it's not published yet
verifyElementPresent savePublishPressed
clickAndWait savePublishPressed
verifyTextNotPresent ${categoryName} has changes that have not been published Verify message that it's now published
verifyElementPresent xpath=//[EMAIL PROTECTED]'Delete ${categoryName}']
clickAndWait xpath=//[EMAIL PROTECTED]'Delete ${categoryName}']
verifyTextNotPresent ${categoryName} Verify message that it's now deleted
haltstop hereThere was an unexpected Confirmation! [This category ( test-category-2005.10.1-11:15:55 ) will be immediately deleted. Are you sure?]
Add And Edit Protein Test
open /catalog/Index.action go to the Catalog Home Page
verifyTextPresent Catalog Manager  
assertElementPresent dom=document.forms['gotoProteins'].submit  
clickAndWait dom=document.forms['gotoProteins'].submit  
verifyTitle Catalog Manager - viewProteins  
store _javascript_{tmpName("test-protein");} proteinName
verifyElementPresent protein.name
type protein.name ${proteinName}
verifyElementPresent dom=document.forms['addProtein']['submit']
clickAndWait dom=document.forms['addProtein']['submit']
verifyTextPresent ${proteinName}
verifyElementPresent protein.description
store The Protein Long Description proteinDescription
type protein.description ${proteinDescription}
verifyElementPresent protein.keywords
store five, four, three, two, one keywords
type protein.keywords ${keywords}
verifyElementPresent protein.shortDescription
store The Protein Short Description proteinShortDescription
type protein.shortDescription ${proteinShortDescription}
verifyElementPresent protein.productGroupRelationsNote
store one, two, three, four, five productGroupRelationsNote
type protein.productGroupRelationsNote ${productGroupRelationsNote}
verifyElementPresent document.forms['editProtein']['savePressed']
clickAndWait document.forms['editProtein']['savePressed']
verifyTextPresent ${proteinName} has changes that have not been published Verify message that it's not published yet
verifyElementPresent savePublishPressed
clickAndWait savePublishPressed
verifyTextNotPresent ${proteinName} has changes that have not been published Verify message that it's now published
verifyElementPresent xpath=//[EMAIL PROTECTED]'Delete ${proteinName}']
clickAndWait xpath=//[EMAIL PROTECTED]'Delete ${proteinName}']
verifyTextNotPresent ${proteinName} Verify message that it's now deleted
haltstop hereThere was an unexpected Confirmation! [This protein ( test-protein-2005.10.1-11:18:58 ) will be immediately deleted. Are you sure?]
Add And Edit Isoform Test
open /catalog/Index.action go to the Catalog Home Page
verifyTextPresent Catalog Manager  
assertElementPresent dom=document.forms['gotoProteins'].submit  
clickAndWait dom=document.forms['gotoProteins'].submit  
verifyTitle Catalog Manager - viewProteins  
store _javascript_{tmpName("test-isoform");} isoformName
verifyElementPresent isoform.name
type isoform.name ${isoformName}
verifyElementPresent dom=document.forms['addIsoform']['submit']
clickAndWait dom=document.forms['addIsoform']['submit']
verifyTextPresent ${isoformName}
verifyElementPresent isoform.keywords
store one, two, three, four keywords
type isoform.keywords ${keywords}
verifyElementPresent document.forms['editIsoForm']['savePressed']
clickAndWait document.forms['editIsoForm']['savePressed']
verifyTextPresent ${isoformName} has changes that have not been published Verify message that it's not published yet
verifyElementPresent savePublishPressed
clickAndWait savePublishPressed
verifyTextNotPresent ${isoformName} has changes that have not been published Verify message that it's now published
verifyElementPresent xpath=//[EMAIL PROTECTED]'Delete ${isoformName}']
clickAndWait xpath=//[EMAIL PROTECTED]'Delete ${isoformName}']
verifyTextNotPresent ${isoformName} Verify message that it's now deleted
haltstop hereThere was an unexpected Confirmation! [This isoform ( test-isoform-2005.10.1-11:24:13 ) will be immediately deleted. Are you sure?]
Manage Biotool Categories Test
open /catalog/Index.action go to the Catalog Home Page
verifyTextPresent Catalog Manager  
assertElementPresent dom=document.forms['gotoBiotools'].submit  
clickAndWait dom=document.forms['gotoBiotools'].submit  
verifyTitle Catalog Manager - viewBiotools  
store _javascript_{tmpName("test-biotool");} biotoolName
store _javascript_{tmpName("test-biotool-sub");} biotoolSubName
verifyElementPresent dom=document.forms['addBiotoolCategory']['biotool.name']
type dom=document.forms['addBiotoolCategory']['biotool.name'] ${biotoolName}
verifyElementPresent dom=document.forms['addBiotoolCategory']['submit']
clickAndWait dom=document.forms['addBiotoolCategory']['submit']
verifyTextPresent ${biotoolName}
verifyElementPresent biotool.description
store The Biotool Long Description biotoolDescription
type biotool.description ${biotoolDescription}
verifyElementPresent biotool.shortDescription
store The short biotool description. biotoolShortDescription
type biotool.shortDescription ${biotoolShortDescription}
verifyElementPresent document.forms['editBiotool']['savePressed']
clickAndWait document.forms['editBiotool']['savePressed']
verifyTextPresent ${biotoolName} has changes that have not been published Verify message that it's not published yet
verifyElementPresent savePublishPressed
clickAndWait savePublishPressed
verifyTextNotPresent ${biotoolName} has changes that have not been published Verify message that it's now published
open /catalog/RetrieveBiotools.action TODO: perhaps a Save & Publish should go here, rather than to edit
verifyElementPresent dom=document.forms['addBiotoolSubCategory']['biotool.name']
type dom=document.forms['addBiotoolSubCategory']['biotool.name'] ${biotoolSubName}
verifyElementPresent dom=document.forms['addBiotoolSubCategory']['submit']
clickAndWait dom=document.forms['addBiotoolSubCategory']['submit']
verifyElementPresent document.forms['editBiotool']['savePressed']
clickAndWait document.forms['editBiotool']['savePressed']
verifyTextPresent ${biotoolSubName} has changes that have not been published Verify message that it's not published yet
verifyElementPresent savePublishPressed
clickAndWait savePublishPressed
verifyTextNotPresent ${biotoolSubName} has changes that have not been published Verify message that it's now published
verifyElementPresent xpath=//[EMAIL PROTECTED]'Delete ${biotoolSubName}']
clickAndWait xpath=//[EMAIL PROTECTED]'Delete ${biotoolSubName}']
verifyTextNotPresent ${biotoolSubName} Verify message that it's now deleted
verifyElementPresent xpath=//[EMAIL PROTECTED]'Delete ${biotoolName}']
clickAndWait xpath=//[EMAIL PROTECTED]'Delete ${biotoolName}'] There was an unexpected Confirmation! [This biotool sub category( test-biotool-sub-2005.10.1-11:29:27 ) will be immediately deleted. Are you sure?]
verifyTextNotPresent ${biotoolName} Verify message that it's now deleted
haltstop here


On Oct 1, 2005, at 6:46 AM, Mike Williams wrote:

Jamie Orchard-Hays wrote:


I submitted a JIRA issue yesterday for this bug and wonder if anyone else has encountered it and found a work-around.

The first time the form generates a confirmation, selenium handles it automatically as advertised. The next one throws the error, "There was an unexpected Confirmation!" (This isn't the only situation it's happened to me, but a good example.)

It seems that somehow selenium isn't resetting the handling of the confirmation box somehow.


There's a known issue around alerts/confirmations not getting cleared at the end of a test:

http://jira.public.thoughtworks.org/browse/SEL-58

Is this the kind of behaviour you're seeing?

--
cheers, MikeW http://www.dogbiscuit.org/ mdub/

_______________________________________________
Selenium-users mailing list
Selenium-users@lists.public.thoughtworks.org
http://lists.public.thoughtworks.org/mailman/listinfo/selenium-users


_______________________________________________
Selenium-users mailing list
Selenium-users@lists.public.thoughtworks.org
http://lists.public.thoughtworks.org/mailman/listinfo/selenium-users

Reply via email to