aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/test/java/com/google/devtools/build/lib/actions/ActionCacheCheckerTest.java
diff options
context:
space:
mode:
authorGravatar tomlu <tomlu@google.com>2018-01-16 11:07:51 -0800
committerGravatar Copybara-Service <copybara-piper@google.com>2018-01-16 11:09:25 -0800
commit1cdcdf9a72458850f8a0f40c7cab1699685ed6cc (patch)
tree888c68cd1fc59cc4608ac178ae633c1f40e22230 /src/test/java/com/google/devtools/build/lib/actions/ActionCacheCheckerTest.java
parent644ada0444a9db285eb4e6c2511fc9581cc69880 (diff)
Rename Root to ArtifactRoot.
This is slightly more descriptive, and we will potentially want to use the name Root for a broader concept shared between ArtifactRoot and RootedPath. PiperOrigin-RevId: 182082367
Diffstat (limited to 'src/test/java/com/google/devtools/build/lib/actions/ActionCacheCheckerTest.java')
-rw-r--r--src/test/java/com/google/devtools/build/lib/actions/ActionCacheCheckerTest.java19
1 files changed, 10 insertions, 9 deletions
diff --git a/src/test/java/com/google/devtools/build/lib/actions/ActionCacheCheckerTest.java b/src/test/java/com/google/devtools/build/lib/actions/ActionCacheCheckerTest.java
index c6de33475e..8892fcf38d 100644
--- a/src/test/java/com/google/devtools/build/lib/actions/ActionCacheCheckerTest.java
+++ b/src/test/java/com/google/devtools/build/lib/actions/ActionCacheCheckerTest.java
@@ -274,15 +274,16 @@ public class ActionCacheCheckerTest {
@Test
public void testMiddleman_DifferentFiles() throws Exception {
- Action action = new NullMiddlemanAction() {
- @Override
- public synchronized Iterable<Artifact> getInputs() {
- FileSystem fileSystem = getPrimaryOutput().getPath().getFileSystem();
- Path path = fileSystem.getPath("/input");
- Root root = Root.asSourceRoot(fileSystem.getPath("/"));
- return ImmutableList.of(new Artifact(path, root));
- }
- };
+ Action action =
+ new NullMiddlemanAction() {
+ @Override
+ public synchronized Iterable<Artifact> getInputs() {
+ FileSystem fileSystem = getPrimaryOutput().getPath().getFileSystem();
+ Path path = fileSystem.getPath("/input");
+ ArtifactRoot root = ArtifactRoot.asSourceRoot(fileSystem.getPath("/"));
+ return ImmutableList.of(new Artifact(path, root));
+ }
+ };
runAction(action); // Not cached so recorded as different deps.
FileSystemUtils.writeContentAsLatin1(action.getPrimaryInput().getPath(), "modified");
runAction(action); // Cache miss because input files were modified.