aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/rules/test/TestRunnerAction.java
diff options
context:
space:
mode:
authorGravatar Googler <noreply@google.com>2016-02-03 21:10:05 +0000
committerGravatar David Chen <dzc@google.com>2016-02-03 22:07:21 +0000
commit9e1a604c4d5a754821d8ca571aa2dca9349e450a (patch)
treed4402e0c4649c28e76441394846554054984e599 /src/main/java/com/google/devtools/build/lib/rules/test/TestRunnerAction.java
parent2dae2f6b4cd3182a1fbdbd17ef0726aee4bc3b70 (diff)
Support outputting UNUSED_RUNFILES_LOG to a file.
-- MOS_MIGRATED_REVID=113774246
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/rules/test/TestRunnerAction.java')
-rw-r--r--src/main/java/com/google/devtools/build/lib/rules/test/TestRunnerAction.java11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/test/TestRunnerAction.java b/src/main/java/com/google/devtools/build/lib/rules/test/TestRunnerAction.java
index 9f09c90319..f0860f8295 100644
--- a/src/main/java/com/google/devtools/build/lib/rules/test/TestRunnerAction.java
+++ b/src/main/java/com/google/devtools/build/lib/rules/test/TestRunnerAction.java
@@ -65,6 +65,7 @@ public class TestRunnerAction extends AbstractAction implements NotifyOnActionCa
private final Artifact testLog;
private final Artifact cacheStatus;
private final PathFragment testWarningsPath;
+ private final PathFragment unusedRunfilesLogPath;
private final PathFragment splitLogsPath;
private final PathFragment splitLogsDir;
private final PathFragment undeclaredOutputsDir;
@@ -154,6 +155,7 @@ public class TestRunnerAction extends AbstractAction implements NotifyOnActionCa
: null;
this.xmlOutputPath = baseDir.getChild(namePrefix + ".xml");
this.testWarningsPath = baseDir.getChild(namePrefix + ".warnings");
+ this.unusedRunfilesLogPath = baseDir.getChild(namePrefix + ".unused_runfiles_log");
this.testStderr = baseDir.getChild(namePrefix + ".err");
this.splitLogsDir = baseDir.getChild(namePrefix + ".raw_splitlogs");
// See note in {@link #getSplitLogsPath} on the choice of file name.
@@ -322,6 +324,7 @@ public class TestRunnerAction extends AbstractAction implements NotifyOnActionCa
// We also need to remove *.(xml|data|shard|warnings|zip) files if they are present.
execRoot.getRelative(xmlOutputPath).delete();
execRoot.getRelative(testWarningsPath).delete();
+ execRoot.getRelative(unusedRunfilesLogPath).delete();
// Note that splitLogsPath points to a file inside the splitLogsDir so
// it's not necessary to delete it explicitly.
FileSystemUtils.deleteTree(execRoot.getRelative(splitLogsDir));
@@ -417,6 +420,10 @@ public class TestRunnerAction extends AbstractAction implements NotifyOnActionCa
return testWarningsPath;
}
+ public PathFragment getUnusedRunfilesLogPath() {
+ return unusedRunfilesLogPath;
+ }
+
public PathFragment getSplitLogsPath() {
return splitLogsPath;
}
@@ -583,6 +590,10 @@ public class TestRunnerAction extends AbstractAction implements NotifyOnActionCa
return getPath(splitLogsPath);
}
+ public Path getUnusedRunfilesLogPath() {
+ return getPath(unusedRunfilesLogPath);
+ }
+
/**
* @return path to the directory containing the split logs (raw and proto file).
*/