Examples of IExecutionDataSource


Examples of com.mountainminds.eclemma.core.IExecutionDataSource

    monitor.done();
  }

  private IExecutionDataSource getSessionData() throws CoreException {
    try {
      final IExecutionDataSource source = dataSourceFactory.call();
      if (this.copy) {
        return this.executionDataFiles.newFile(source);
      } else {
        return source;
      }
View Full Code Here

Examples of com.mountainminds.eclemma.core.IExecutionDataSource

    assertArrayEquals(new String[0],
        new File(folder.getRoot(), ".execdata").list());
  }

  private IExecutionDataSource source() {
    return new IExecutionDataSource() {
      public void accept(IExecutionDataVisitor executionDataVisitor,
          ISessionInfoVisitor sessionInfoVisitor) throws CoreException {
        sessionInfoVisitor.visitSessionInfo(new SessionInfo("id", 1, 2));
        executionDataVisitor.visitClassExecution(new ExecutionData(123,
            "MyClass", 15));
View Full Code Here

Examples of com.mountainminds.eclemma.core.IExecutionDataSource

  private <E> Set<E> set(E... elements) {
    return new HashSet<E>(Arrays.asList(elements));
  }

  private IExecutionDataSource source() {
    return new IExecutionDataSource() {
      public void accept(IExecutionDataVisitor executionDataVisitor,
          ISessionInfoVisitor sessionInfoVisitor) throws CoreException {
        sessionInfoVisitor.visitSessionInfo(new SessionInfo("id", 1, 2));
        executionDataVisitor.visitClassExecution(new ExecutionData(123,
            "MyClass", 15));
View Full Code Here

Examples of com.mountainminds.eclemma.core.IExecutionDataSource

  @Rule
  public ExpectedException exception = ExpectedException.none();

  @Test
  public void testAccept() throws IOException, CoreException {
    final IExecutionDataSource source = createValidSource();

    SessionInfoStore sessionStore = new SessionInfoStore();
    ExecutionDataStore execStore = new ExecutionDataStore();
    source.accept(execStore, sessionStore);

    assertEquals(1, sessionStore.getInfos().size());
    assertEquals("MyClass", execStore.get(123).getName());
  }
View Full Code Here

Examples of com.mountainminds.eclemma.core.IExecutionDataSource

  @Test
  public void testAcceptWithError() throws IOException, CoreException {
    exception.expect(CoreException.class);
    exception.expectMessage("Error while reading execution data file");

    final IExecutionDataSource source = creatInvalidSource();

    SessionInfoStore sessionStore = new SessionInfoStore();
    ExecutionDataStore execStore = new ExecutionDataStore();
    source.accept(execStore, sessionStore);
  }
View Full Code Here

Examples of com.mountainminds.eclemma.core.IExecutionDataSource

        launches.add(session.getLaunchConfiguration());
      }
      session.accept(memory, memory);
      monitor.worked(1);
    }
    final IExecutionDataSource executionDataSource = executiondatafiles
        .newFile(memory);

    // Adopt launch configuration only if there is exactly one
    final ILaunchConfiguration launchconfiguration = launches.size() == 1 ? launches
        .iterator().next() : null;
View Full Code Here

Examples of com.mountainminds.eclemma.core.IExecutionDataSource

    assertArrayEquals(new String[0],
        new File(folder.getRoot(), ".execdata").list());
  }

  private IExecutionDataSource source() {
    return new IExecutionDataSource() {
      public void accept(IExecutionDataVisitor executionDataVisitor,
          ISessionInfoVisitor sessionInfoVisitor) throws CoreException {
        sessionInfoVisitor.visitSessionInfo(new SessionInfo("id", 1, 2));
        executionDataVisitor.visitClassExecution(new ExecutionData(123,
            "MyClass", 15));
View Full Code Here

Examples of com.mountainminds.eclemma.core.IExecutionDataSource

  private <E> Set<E> set(E... elements) {
    return new HashSet<E>(Arrays.asList(elements));
  }

  private IExecutionDataSource source() {
    return new IExecutionDataSource() {
      public void accept(IExecutionDataVisitor executionDataVisitor,
          ISessionInfoVisitor sessionInfoVisitor) throws CoreException {
        sessionInfoVisitor.visitSessionInfo(new SessionInfo("id", 1, 2));
        executionDataVisitor.visitClassExecution(new ExecutionData(123,
            "MyClass", 15));
View Full Code Here

Examples of com.mountainminds.eclemma.core.IExecutionDataSource

  @Rule
  public ExpectedException exception = ExpectedException.none();

  @Test
  public void testAccept() throws IOException, CoreException {
    final IExecutionDataSource source = createValidSource();

    SessionInfoStore sessionStore = new SessionInfoStore();
    ExecutionDataStore execStore = new ExecutionDataStore();
    source.accept(execStore, sessionStore);

    assertEquals(1, sessionStore.getInfos().size());
    assertEquals("MyClass", execStore.get(123).getName());
  }
View Full Code Here

Examples of com.mountainminds.eclemma.core.IExecutionDataSource

  @Test
  public void testAcceptWithError() throws IOException, CoreException {
    exception.expect(CoreException.class);
    exception.expectMessage("Error while reading execution data file");

    final IExecutionDataSource source = creatInvalidSource();

    SessionInfoStore sessionStore = new SessionInfoStore();
    ExecutionDataStore execStore = new ExecutionDataStore();
    source.accept(execStore, sessionStore);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.