Example #1
0
        public virtual void TestSetup()
        {
            this.Repo = new CommonRepoSetup();

            string error;

            RepoMetadata.TryInitialize(
                new MockTracer(),
                this.Repo.Context.FileSystem,
                this.Repo.Context.Enlistment.DotGVFSRoot,
                out error);
        }
Example #2
0
        public FileSystemVirtualizerTester(CommonRepoSetup repo, string[] projectedFiles)
        {
            this.Repo = repo;
            this.MockPlaceholderDb = new Mock <IPlaceholderCollection>(MockBehavior.Strict);
            this.MockPlaceholderDb.Setup(x => x.GetCount()).Returns(1);
            this.MockSparseDb         = new Mock <ISparseCollection>(MockBehavior.Strict);
            this.BackgroundTaskRunner = new MockBackgroundFileSystemTaskRunner();
            this.GitIndexProjection   = new MockGitIndexProjection(projectedFiles);
            this.Virtualizer          = this.CreateVirtualizer(repo);
            this.FileSystemCallbacks  = new MockFileSystemCallbacks(
                repo.Context,
                repo.GitObjects,
                RepoMetadata.Instance,
                new MockBlobSizes(),
                this.GitIndexProjection,
                this.BackgroundTaskRunner,
                this.Virtualizer,
                this.MockPlaceholderDb.Object,
                this.MockSparseDb.Object);

            this.FileSystemCallbacks.TryStart(out string error).ShouldEqual(true);
        }
Example #3
0
 public virtual void TestSetup()
 {
     this.Repo = new CommonRepoSetup();
 }
Example #4
0
 protected abstract FileSystemVirtualizer CreateVirtualizer(CommonRepoSetup repo);
Example #5
0
 public FileSystemVirtualizerTester(CommonRepoSetup repo)
     : this(repo, new[] { "test.txt" })
 {
 }