Examples of assertLogEntriesContainExpected()


Examples of com.google.gwt.dev.util.UnitTestTreeLogger.assertLogEntriesContainExpected()

          logger, compilerContext, "com.google.gwt.dev.cfg.testdata.errors.DeepInheritsError0");
      fail("Should have failed to load module.");
    } catch (UnableToCompleteException e) {
      // failure is expected.
    }
    logger.assertLogEntriesContainExpected();
  }

  public void testErrorReporting_inheritNotFound() {
    assertErrorsWhenLoading("com.google.gwt.dev.cfg.testdata.errors.InheritNotFound",
        "Unable to find 'com/google/gwt/dev/cfg/testdata/NonExistentModule.gwt.xml' on your "
View Full Code Here

Examples of com.google.gwt.dev.util.UnitTestTreeLogger.assertLogEntriesContainExpected()

      ModuleDefLoader.loadFromClassPath(
          logger, compilerContext, "com.google.gwt.dev.cfg.testdata.naming.Invalid..Foo");
      fail("Expected exception from invalid module name.");
    } catch (UnableToCompleteException expected) {
    }
    logger.assertLogEntriesContainExpected();
  }

  public void testModuleNamingValid() throws Exception {
    TreeLogger logger = TreeLogger.NULL;
View Full Code Here

Examples of com.google.gwt.dev.util.UnitTestTreeLogger.assertLogEntriesContainExpected()

      ModuleDefLoader.loadFromClassPath(logger,
          compilerContext, "com.google.gwt.dev.cfg.testdata.naming.NestedInvalid", false);
      fail("Expected exception from invalid module name.");
    } catch (UnableToCompleteException expected) {
    }
    logger.assertLogEntriesContainExpected();
  }

  public void testRequiresStrictResources() throws Exception {
    assertHonorsStrictResources(true);
  }
View Full Code Here

Examples of com.google.gwt.dev.util.UnitTestTreeLogger.assertLogEntriesContainExpected()

    incrementalBuilder.clean();

    boolean actualBuildSuccess = incrementalBuilder.build(testLogger).isSuccess();

    assertEquals(expectedBuildSuccess, actualBuildSuccess);
    testLogger.assertLogEntriesContainExpected();
  }

  private static ResourceLoader createGwtClassPathResourceLoader() throws MalformedURLException {
    String gwtClassPathProperty = System.getProperty("gwt.cp");
    String[] gwtClassPathStrings = gwtClassPathProperty.split(";");
View Full Code Here

Examples of com.google.gwt.dev.util.UnitTestTreeLogger.assertLogEntriesContainExpected()

    // Compile.
    boolean actualBuildSuccess = incrementalBuilder.build(testLogger).isSuccess();

    // Assert compile succeeded and was a full compile with no caching.
    assertEquals(true, actualBuildSuccess);
    testLogger.assertLogEntriesContainExpected();

    // Setup logging expectations for a fully cached compile.
    loggerBuilder = new UnitTestTreeLogger.Builder();
    loggerBuilder.setLowestLogLevel(TreeLogger.INFO);
    loggerBuilder.expectInfo(IncrementalBuilder.NO_FILES_HAVE_CHANGED, null);
View Full Code Here

Examples of com.google.gwt.dev.util.UnitTestTreeLogger.assertLogEntriesContainExpected()

    // Recompile without changes.
    actualBuildSuccess = incrementalBuilder.rebuild(testLogger).isSuccess();

    // Assert compile succeeded and was fully cached.
    assertEquals(true, actualBuildSuccess);
    testLogger.assertLogEntriesContainExpected();

    // Change modification date of the Foo.java seen by SimpleMid.gwt.xml
    File fooFile = new File(resourceLoader.getResource(
        "com/google/gwt/dev/testdata/incrementalbuildsystem/Foo.java").getPath());
    fooFile.setLastModified(System.currentTimeMillis() + 60 * 1000);
 
View Full Code Here

Examples of com.google.gwt.dev.util.UnitTestTreeLogger.assertLogEntriesContainExpected()

    // Recompile with changes.
    actualBuildSuccess = incrementalBuilder.rebuild(testLogger).isSuccess();

    // Assert compile succeeded and was partially cached.
    assertEquals(true, actualBuildSuccess);
    testLogger.assertLogEntriesContainExpected();
  }

  public void testCircularReference() throws MalformedURLException {
    List<String> circularModulePath = Arrays.asList(new String[] {
        "com.google.gwt.dev.testdata.incrementalbuildsystem.CircularRoot",
View Full Code Here

Examples of com.google.gwt.dev.util.UnitTestTreeLogger.assertLogEntriesContainExpected()

        createGwtClassPathResourceLoader());
    incrementalBuilder.clean();

    boolean buildSucceeded = incrementalBuilder.build(testLogger).isSuccess();
    assertFalse(buildSucceeded);
    testLogger.assertLogEntriesContainExpected();
  }

  public void testDuplicateGeneratorOutput() throws MalformedURLException {
    String duplicateCompilationUnitError = LibraryGroup.formatDuplicateCompilationUnitMessage(
        "com.google.gwt.dev.Bar", "com.google.gwt.dev.testdata.incrementalbuildsystem.ParallelLeft",
View Full Code Here

Examples of com.google.gwt.dev.util.UnitTestTreeLogger.assertLogEntriesContainExpected()

        createGwtClassPathResourceLoader());
    incrementalBuilder.clean();

    boolean buildSucceeded = incrementalBuilder.build(testLogger).isSuccess();
    assertFalse(buildSucceeded);
    testLogger.assertLogEntriesContainExpected();
  }

  public void testEntryPointWithFailedSameModuleTypeReference() throws MalformedURLException {
    String victimTypeName =
        "com.google.gwt.dev.testdata.incrementalbuildsystem.EntryPointCompileFails";
View Full Code Here

Examples of com.google.gwt.dev.util.UnitTestTreeLogger.assertLogEntriesContainExpected()

        createGwtClassPathResourceLoader());
    incrementalBuilder.clean();

    boolean buildSucceeded = incrementalBuilder.build(testLogger).isSuccess();
    assertFalse(buildSucceeded);
    testLogger.assertLogEntriesContainExpected();
  }

  public void testIgnoresCompileFailuresInUnreachableTypes() throws MalformedURLException {
    assertBuildResult(
        "com.google.gwt.dev.testdata.incrementalbuildsystem.UnreachableTypeCompileFails", true);
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.