[Webtest] [webtest][JIRA] Created: (WT-113) Warning Messages: verifyNoDialogResponses only works if you use verifyProperty first

Annette Cass (JIRA) webtest@lists.canoo.com
Mon, 21 Nov 2005 16:05:35 +0100 (CET)


Warning Messages: verifyNoDialogResponses only works if you use verifyProperty first
------------------------------------------------------------------------------------

         Key: WT-113
         URL: http://webtest-community.canoo.com/jira/browse/WT-113
     Project: WebTest
        Type: Bug
    Reporter: Annette Cass


verifyNoDialogResponses only works if you pair it with verifyProperty. It doesn't work if you do NOT use verifyProperty first.

Situation:

I want to make sure that unexpected message boxes are identified and will throw out an error.

In code below:

- I created a situation where I knew a message box would be generated when a required field wasn't filled in and the record was submitted.
- verifyNoDialogResponses failed to pick up the presence of a message box indicating the record wasn't saved because of a missing field.
- The following steps to search for the record that was supposedly added didn't work -- because it never shifted to the "Search" screen. Instead, it "found" the record because it was stuck on the original "Add" screen.

Any questions on this - please feel free to e-mail me at Annette.Cass@duke.edu

Thanks.

Annette Cass


<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE project [
	  <!ENTITY init    SYSTEM "modules/init.properties">
	  <!ENTITY config  SYSTEM "modules/config.properties">
          <!ENTITY loginAdminUser   SYSTEM "steps/loginAdminUser.txt">
	  ]>
<project name="View Data Collection Form" basedir="." default="CreateSite">
  <property file="config/registryWebTest.properties"/>
  &init;
  <target name="CreateSite" >
    <testSpec name="CreateSite" >
      &config;
      <steps>
	&loginAdminUser;

        <prepareDialogResponse dialogType="alert" saveProperty="simpleDialog" />

	<!-- Navigate to create site, populate Site data -->
	<invoke description="Navigate to create site and populate Site data" url="${createSiteUrl}" />


	<verifyTitle description="Verify Create Site screen is displayed" text="Create Site" />


	<selectForm description="Select form" name="registryForm" />


	<setInputField description="Set site id" name="siteValue.siteCode" value="${SiteId}" />


	<setInputField description="Set Site name" name="siteValue.name" value="${SiteName}" />


	<setInputField description="Set Site City" name="siteValue.city" value="${SiteCity}" />

        <setInputField description="Set Site State" name="siteValue.state" value="${SiteState}"  />
  

      <!-- TESTING NOT filling in REGISTRY field AND SEEING IF verifyNoDialogResponses picks up error -->

        

	<clickButton description="Submit the new Site data" htmlId="ApplyButton"  />

        <verifyNoDialogResponses description="Check all responses were used" />


	


        <!--  Search for the newly created Site and verify it's found -->

        <invoke description="Search for newly created site and verify it is found" url="${viewSiteUrl}"  />

	<verifyTitle description="Verify transition to View Sites screen" text='View Sites' />

	<setInputField description="Set Site name" name="siteValue.name" value="${SiteName}" />


	<clickButton description="Search for newly created Site" htmlId="SearchButton" save="View_Sites_Search_For_${SiteName}" />


	<verifyText description="Verify newly created Site is found by search" text="${SiteName}"	/>

           
       <!-- invoke description="Logout" url="${LogoutUrl}" / -->

      </steps>
    </testSpec>        
  </target>
</project>


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://webtest-community.canoo.com/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira