|
37 | 37 | import com.google.gwt.thirdparty.guava.common.collect.Lists; |
38 | 38 | import com.google.gwt.thirdparty.guava.common.collect.Sets; |
39 | 39 | import com.google.gwt.thirdparty.guava.common.io.MoreFiles; |
| 40 | +import com.google.gwt.thirdparty.guava.common.io.RecursiveDeleteOption; |
40 | 41 |
|
41 | 42 | import java.io.File; |
42 | 43 | import java.io.IOException; |
@@ -2505,7 +2506,7 @@ private void assertCompileSucceeds(CompilerOptions options, String moduleName, |
2505 | 2506 | // is clean to avoid confusion when returning the output JS. |
2506 | 2507 | File outputDir = new File(applicationDir.getPath() + File.separator + moduleName); |
2507 | 2508 | if (outputDir.exists()) { |
2508 | | - MoreFiles.deleteDirectoryContents(outputDir.toPath()); |
| 2509 | + MoreFiles.deleteDirectoryContents(outputDir.toPath(), RecursiveDeleteOption.ALLOW_INSECURE); |
2509 | 2510 | } |
2510 | 2511 |
|
2511 | 2512 | // Fake out the resource loader to read resources both from the normal classpath as well as |
@@ -2537,7 +2538,7 @@ private void assertCompileSucceeds(CompilerOptions options, String moduleName, |
2537 | 2538 | // Run the compiler once here. |
2538 | 2539 | Compiler.compile(logger, options); |
2539 | 2540 | } finally { |
2540 | | - MoreFiles.deleteRecursively(compileWorkDir.toPath()); |
| 2541 | + MoreFiles.deleteRecursively(compileWorkDir.toPath(), RecursiveDeleteOption.ALLOW_INSECURE); |
2541 | 2542 | if (oldPersistentUnitCacheValue == null) { |
2542 | 2543 | System.clearProperty(UnitCacheSingleton.GWT_PERSISTENTUNITCACHE); |
2543 | 2544 | } else { |
@@ -2584,8 +2585,8 @@ private void assertDeterministicBuild(String topLevelModule, int optimizationLev |
2584 | 2585 | } else { |
2585 | 2586 | System.setProperty(UnitCacheSingleton.GWT_PERSISTENTUNITCACHE, oldPersistentUnitCacheValue); |
2586 | 2587 | } |
2587 | | - MoreFiles.deleteRecursively(firstCompileWorkDir.toPath()); |
2588 | | - MoreFiles.deleteRecursively(secondCompileWorkDir.toPath()); |
| 2588 | + MoreFiles.deleteRecursively(firstCompileWorkDir.toPath(), RecursiveDeleteOption.ALLOW_INSECURE); |
| 2589 | + MoreFiles.deleteRecursively(secondCompileWorkDir.toPath(), RecursiveDeleteOption.ALLOW_INSECURE); |
2589 | 2590 | } |
2590 | 2591 | } |
2591 | 2592 |
|
@@ -2689,7 +2690,7 @@ private String compileToJs(TreeLogger logger, CompilerOptions compilerOptions, F |
2689 | 2690 | // clean to avoid confusion when returning the output JS. |
2690 | 2691 | File outputDir = new File(applicationDir.getPath() + File.separator + moduleName); |
2691 | 2692 | if (outputDir.exists()) { |
2692 | | - MoreFiles.deleteDirectoryContents(outputDir.toPath()); |
| 2693 | + MoreFiles.deleteDirectoryContents(outputDir.toPath(), RecursiveDeleteOption.ALLOW_INSECURE); |
2693 | 2694 | } |
2694 | 2695 |
|
2695 | 2696 | // Fake out the resource loader to read resources both from the normal classpath as well as this |
|
0 commit comments