Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Here's an example from one of the Tapestry modules:

Code Block
java
java
titleYour Integration Test Class : SinglePersistenceUnitIntegrationTest.java
package org.apache.tapestry5.jpa.integration.app2;

import org.apache.tapestry5.test.SeleniumTestCase;
import org.testng.annotations.Test;

public class SinglePersistenceUnitIntegrationTest extends SeleniumTestCase
{

    @Test
    public void persist_entities()
    {
        open("/persistitem");
        assertEquals(getText("//span[@id='name']").length(), 0);

        clickAndWait("link=create item");
        assertText("//span[@id='name']", "name");
    }
}

...

Here's an example :

Code Block
xml
xml
titletestng.xml
<suite name="Selenium Tests Suite" annotations="1.5">
  <test name="Integration Tests" enabled="true">
    <parameter name="tapestry.browser-start-command" value="*googlechrome" />
    <parameter name="tapestry.port" value="9091" />

    <classes>
      <class name="com.example.newapp.SeleniumTest"></class>
    </classes>
  </test>
</suite>