@Before
  public void setUp() throws URISyntaxException, IOException {
    when(mockLogger.isDebugEnabled()).thenReturn(true);
    when(mockLogger.isInfoEnabled()).thenReturn(true);
    when(mockLogger.isWarnEnabled()).thenReturn(true);
    when(mockLogger.isErrorEnabled()).thenReturn(true);

    Path projectDir = getResource("gradle/application");
    project =
        ProjectBuilder.builder()
            .withName("my-app")
            .withProjectDir(projectDir.toFile())
            .withGradleUserHomeDir(temporaryFolder.newFolder())
            .build();
    project.getPlugins().apply("java");

    DependencyHandler dependencies = project.getDependencies();
    dependencies.add(
        "implementation",
        project.files(
            "dependencies/library.jarC.jar",
            "dependencies/libraryB.jar",
            "dependencies/libraryA.jar",
            "dependencies/dependency-1.0.0.jar",
            "dependencies/more/dependency-1.0.0.jar",
            "dependencies/another/one/dependency-1.0.0.jar",
            "dependencies/dependencyX-1.0.0-SNAPSHOT.jar"));

    // We can't commit an empty directory in Git, so create (if not exist).
    Path emptyDirectory = getResource("gradle/webapp").resolve("WEB-INF/classes/empty_dir");
    Files.createDirectories(emptyDirectory);

    gradleProjectProperties =
        new GradleProjectProperties(
            project,
            mockLogger,
            mockTempDirectoryProvider,
            mockExtensionLoader,
            JavaPlugin.RUNTIME_CLASSPATH_CONFIGURATION_NAME);
  }
Helper for reading back layers in a {@link BuildContext}.
jib-gradle-plugin/src/test/java/com/google/cloud/tools/jib/gradle/GradleProjectPropertiesTest.java