Uploaded image for project: 'Click'
  1. Click
  2. CLK-510

QuickStart should generate tests too.

    XMLWordPrintableJSON

    Details

    • Type: New Feature
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: 3.0.0
    • Component/s: None
    • Labels:
      None

      Description

      QuickStart generation should produce test artifacts(and configuration for tests too).
      To enforce a good usage of Click, the generator should produce JUnit tests (with SeleniumUnit test for the Pages).
      E.g. for google page (but it is similar for every click page):
      <code>
      import com.thoughtworks.selenium.*;
      import junit.framework.*;
      public class GoogleTest extends TestCase {
      private Selenium browser;
      public void setUp()

      { browser = new DefaultSelenium("localhost", 4444, "*firefox", "http://www.google.com"); browser.start(); }

      public void testGoogle()

      { browser.open("http://www.google.com/webhp?hl=en"); browser.type("q", "hello world"); browser.click("btnG"); browser.waitForPageToLoad("5000"); assertEquals("hello world - Google Search", browser.getTitle()); }

      public void tearDown()

      { browser.stop(); }

      }
      </code>

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                a_adrian Adrian A.
                Reporter:
                jschmidt71 Joseph Schmidt
              • Votes:
                3 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated: