diff options
author | Ulf Adams <ulfjack@google.com> | 2016-03-23 09:18:13 +0000 |
---|---|---|
committer | Damien Martin-Guillerez <dmarting@google.com> | 2016-03-23 12:21:08 +0000 |
commit | c73051c6baad0aaaf1fdf34d5ad19602b8df628a (patch) | |
tree | 29bfc153be8f0cc80c99bf29cff264c97cf0a70d /src/test/java/com/google/devtools/build/lib/skyframe/PackageLookupFunctionTest.java | |
parent | 8a5f5c7a9174222c13f5546e3c467309e19534d7 (diff) |
Move TimestampGranularityMonitor to CommandEnvironment.
This is one of the last pieces of state in BlazeRuntime that isn't safe to
share across command invocations.
--
MOS_MIGRATED_REVID=117910631
Diffstat (limited to 'src/test/java/com/google/devtools/build/lib/skyframe/PackageLookupFunctionTest.java')
-rw-r--r-- | src/test/java/com/google/devtools/build/lib/skyframe/PackageLookupFunctionTest.java | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/test/java/com/google/devtools/build/lib/skyframe/PackageLookupFunctionTest.java b/src/test/java/com/google/devtools/build/lib/skyframe/PackageLookupFunctionTest.java index 3452728420..07edc60c1d 100644 --- a/src/test/java/com/google/devtools/build/lib/skyframe/PackageLookupFunctionTest.java +++ b/src/test/java/com/google/devtools/build/lib/skyframe/PackageLookupFunctionTest.java @@ -32,7 +32,6 @@ import com.google.devtools.build.lib.pkgcache.PathPackageLocator; import com.google.devtools.build.lib.skyframe.PackageLookupValue.ErrorReason; import com.google.devtools.build.lib.testutil.FoundationTestCase; import com.google.devtools.build.lib.testutil.TestRuleClassProvider; -import com.google.devtools.build.lib.util.BlazeClock; import com.google.devtools.build.lib.util.io.TimestampGranularityMonitor; import com.google.devtools.build.lib.vfs.Path; import com.google.devtools.build.lib.vfs.PathFragment; @@ -74,7 +73,6 @@ public class PackageLookupFunctionTest extends FoundationTestCase { new PathPackageLocator(outputBase, ImmutableList.of(emptyPackagePath, rootDirectory))); deletedPackages = new AtomicReference<>(ImmutableSet.<PackageIdentifier>of()); ExternalFilesHelper externalFilesHelper = new ExternalFilesHelper(pkgLocator, false); - TimestampGranularityMonitor tsgm = new TimestampGranularityMonitor(BlazeClock.instance()); BlazeDirectories directories = new BlazeDirectories(rootDirectory, outputBase, rootDirectory); Map<SkyFunctionName, SkyFunction> skyFunctions = new HashMap<>(); @@ -83,7 +81,8 @@ public class PackageLookupFunctionTest extends FoundationTestCase { skyFunctions.put( SkyFunctions.PACKAGE, new PackageFunction(null, null, null, null, null, null, null)); - skyFunctions.put(SkyFunctions.FILE_STATE, new FileStateFunction(tsgm, externalFilesHelper)); + skyFunctions.put(SkyFunctions.FILE_STATE, new FileStateFunction( + new AtomicReference<TimestampGranularityMonitor>(), externalFilesHelper)); skyFunctions.put(SkyFunctions.FILE, new FileFunction(pkgLocator)); skyFunctions.put(SkyFunctions.BLACKLISTED_PACKAGE_PREFIXES, new BlacklistedPackagePrefixesFunction()); |