Package er.selenium

Examples of er.selenium.SeleniumTest$Element


    boolean failed = false;
    SeleniumTestRCRunner runner = new SeleniumTestRCRunner(host, port, browserType, appHost);
    runner.prepare();
    try {
      for (File testFile : testsFiles) {
        SeleniumTest test = null;
        try {
          SeleniumCompositeTestFilter testFilter = new SeleniumCompositeTestFilter();
          File[] searchPaths = {testFile.getAbsoluteFile().getParentFile(), testsRoot.getAbsoluteFile()};
          testFilter.addTestFilter(new SeleniumIncludeTestFilter(new NSArray<File>(searchPaths)));
          testFilter.addTestFilter(new SeleniumRepeatExpanderTestFilter());
          testFilter.addTestFilter(new SeleniumOverrideOpenTestFilter(appHost));
         
          test = new SeleniumTestFileProcessor(testFile, testFilter).process();
          log.debug("running: " + testFile);
          runner.run(test);
         
          log.info(String.format("test '%s' PASSED", testFile));
          log.info("");
        } catch (SeleniumTestFailureException e) {
          failed = true;
         
          log.error(String.format("test '%s' FAILED: %s", testFile, e));
          log.error("test log:");
          int curCommand = 0;
          for (SeleniumTest.Element elem: test.elements()) {
            if (elem instanceof SeleniumTest.Command) {
              if (curCommand++ > e.processedCommands()) {
                break;
              }
              SeleniumTest.Command command = (SeleniumTest.Command)elem;
View Full Code Here


          fileContents = ERXFileUtilities.stringFromFile(fio, CharEncoding.UTF_8);
        } catch (IOException e) {
          log.error("Can't read " + fio.getAbsolutePath() + " contents");
          throw new RuntimeException(e);
        }
        SeleniumTest processedTest = importer.process(fileContents);
        return processedTest.elements();
      }     
    }
   
    throw new RuntimeException("Included path not found: " + name);
  }
View Full Code Here

          break;
        default:
          elements.add(new SeleniumTest.Comment(line));
        }
      }
      return new SeleniumTest("", elements);
    } catch (IOException e) {
      throw new RuntimeException("Internal error during parsing", e);
    } catch (RuntimeException e) {
      throw new RuntimeException("Error on line " + lineNumber + " during parsing", e);
    }
View Full Code Here

      }
    } catch (Exception e) {
      throw new RuntimeException("Error parsing document.", e);
    }
   
    SeleniumTest test = new SeleniumTest(name, elements);
    test.dump();
    return test;
  }
View Full Code Here

    /**
     * @see org.andromda.metafacades.uml.EventFacade#getTransition()
     */
    protected java.lang.Object handleGetTransition()
    {
        Element owner = this.metaObject.getOwner();
        if (owner instanceof Transition)
        {
            return owner;
        }
        return null;
View Full Code Here

    /**
     * @see org.andromda.metafacades.uml.EventFacade#getState()
     */
    protected java.lang.Object handleGetState()
    {
        Element owner = this.metaObject.getOwner();
        if (owner instanceof State)
        {
            return owner;
        }
        return null;
View Full Code Here

    /**
     * @see org.andromda.metafacades.uml.FrontEndController#getUseCase()
     */
    protected java.lang.Object handleGetUseCase()
    {
        Element owner = (Classifier)this.metaObject;
        while (!(owner == null || owner instanceof UseCase))
        {
            owner = owner.getOwner();
        }
        return owner;
    }
View Full Code Here

    /**
     * @see org.andromda.metafacades.uml.ActivityGraphFacade#getUseCase()
     */
    protected java.lang.Object handleGetUseCase()
    {
        Element owner = (this.metaObject).getOwner();
        if (owner instanceof UseCase)
        {
            return owner;
        }

View Full Code Here

    {
        // TODO: What should this method return ?
      // As I've seen in uml1.4 impl, it should return the statemachine which this element is the context for.
      // Let's say for UML2: Return the owner if the latter is a StateMachine
      StateMachine stateMachine = null;
        Element owner = this.metaObject.getOwner();
        if(owner instanceof StateMachine)
        {
          stateMachine = (StateMachine) owner;
        }
        return stateMachine;
View Full Code Here

    /**
     * @see org.andromda.metafacades.uml.GuardFacade#getTransition()
     */
    protected java.lang.Object handleGetTransition()
    {
        Element owner = this.metaObject.getOwner();
        if (owner instanceof Transition)
        {
            return owner;
        }
        return null;
View Full Code Here

TOP

Related Classes of er.selenium.SeleniumTest$Element

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.