Skip to content

Tutorial: Create new test application

iks github user edited this page Jun 14, 2019 · 36 revisions

Back


  1. In your IDE open java file TestApplicationGenerator and make sure that the constants of this class match your eypectations of the GoogleSearch test application.

  2. Execute the TestApplicationGenerator and assure that the following two files have been generated:

  • file ./sysnat.test.runtime.environment/src/main/resources/execution_properties/GoogleSearch.properties
  • file ./sysnat.test.runtime.environment/src/main/java/com/iksgmbh/sysnat/language_templates/googlesearch/LanguageTemplatesBasics_GoogleSearch.java.
  1. Make sure that the following two methods in LanguageTemplatesBasics_GoogleSearch.java are implemented like this:

          @Override
          public boolean isStartPageVisible() {
              try {
                  return executableExample.isTextCurrentlyDisplayed("Über Google");
               } catch (Exception e) {
                   return false;
               }
          }
    
          @Override
          public void gotoStartPage() {
              if ( ! isStartPageVisible() ) {
                  executableExample.getGuiController().reloadCurrentPage();
              }
          }
    
  2. Start SysNat with its SystemConfigDialog, make sure that the test application GoogleSearch and target environment Production is selected and start test execution.

  3. Check the launched error report. It tells that no executable example has been found. That is what we are going to do in the next part of the tutorial...


Back

Clone this wiki locally