Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-6618

Selenium test integration using XML files

    XMLWordPrintableJSON

Details

    • Patch

    Description

      Added a new type of test, for testing with Selenium WebDriver, but without writing any Java code. This will help making GUI tests quicker and easier to create. Test steps and instances are defined in XML files, like example below, which tests the login procedure for the admin user.

      <testcase name="adminLogin">
        <step function="openBrowser"/>
        <step function="navigate" datavalue="https://localhost:8443/example/control/checkLogin/main"/>
        <step function="writeInput" by="name" webobject="USERNAME" dataname="username"/>
        <step function="writeInput" by="name" webobject="PASSWORD" dataname="password"/>
        <step function="click" by="cssSelector" webobject="input[type=&quot;submit&quot;]"/>
        <step function="checkExists" by="linkText" datavalue="Logout"/>
        <step function="pause" datavalue="2"/>
        <step function="closeBrowser"/>
        
        <testinstance>
          <data name="username" value="admin"/>
          <data name="password" value="ofbiz"/>
        </testinstance>
      </testcase>
      

      Git repository with example (put in 'hot-deploy' folder and check README.txt file):

      git clone http://antwebsystems.com/gerrit/growerptest
      

      Attachments

        1. ModelTestSuite.patch
          1 kB
          Ruud Griepsma
        2. test-suite.patch
          0.8 kB
          Ruud Griepsma
        3. build.patch
          2 kB
          Jacques Le Roux

        Activity

          People

            hansbak Hans Bakker
            ruud Ruud Griepsma
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: