Example #1
0
        protected override CommonTest.TreeRepositoryTestMethods getTestMethods(FileSystem system)
        {
            IStreamedBlobRepository blrepo = new StreamedBlobRepository(system);
            ITreeRepository         trrepo = new TreeRepository(system);

            return(new CommonTest.TreeRepositoryTestMethods(blrepo, trrepo));
        }
        protected override CommonTest.TreeRepositoryTestMethods getTestMethods(DataContext db)
        {
            IStreamedBlobRepository blrepo = new StreamedBlobRepository(db);
            ITreeRepository         trrepo = new TreeRepository(db);

            return(new CommonTest.TreeRepositoryTestMethods(blrepo, trrepo));
        }
Example #3
0
        protected override CommonTest.TagRepositoryTestMethods getTestMethods(FileSystem system)
        {
            IStreamedBlobRepository blrepo = new StreamedBlobRepository(system);
            ITreeRepository         trrepo = new TreeRepository(system);
            ICommitRepository       cmrepo = new CommitRepository(system);
            ITagRepository          tgrepo = new TagRepository(system);
            IRefRepository          rfrepo = new RefRepository(system);

            return(new CommonTest.TagRepositoryTestMethods(cmrepo, blrepo, trrepo, tgrepo, rfrepo));
        }
        protected override CommonTest.RefRepositoryTestMethods getTestMethods(DataContext db)
        {
            IStreamedBlobRepository blrepo = new StreamedBlobRepository(db);
            ITreeRepository         trrepo = new TreeRepository(db);
            ICommitRepository       cmrepo = new CommitRepository(db);
            ITagRepository          tgrepo = new TagRepository(db);
            IRefRepository          rfrepo = new RefRepository(db);

            return(new CommonTest.RefRepositoryTestMethods(cmrepo, blrepo, trrepo, tgrepo, rfrepo));
        }
Example #5
0
        public static TestContext getTestContext(DateTimeOffset? viewDate = null, IConditionalEvaluator evaluator = null, ICustomElementProvider provider = null)
        {
            DateTimeOffset realDate = viewDate ?? DateTimeOffset.Now;

            var db = getDataContext();

            var trrepo = new TreeRepository(db);
            var blrepo = new StreamedBlobRepository(db);
            var tpsbrepo = new TreePathStreamedBlobRepository(db, blrepo);

            return new TestContext(new ContentEngine(trrepo, blrepo, tpsbrepo, realDate, evaluator, provider), trrepo, blrepo, tpsbrepo);
        }
Example #6
0
        public SQLSystemContext(string dataSource)
        {
            // @"Data Source=.\SQLEXPRESS;Initial Catalog=IVO;Integrated Security=SSPI"
            Asynq.DataContext db = new Asynq.DataContext(dataSource);

            TreeRepository trrepo = new TreeRepository(db);
            StreamedBlobRepository blrepo = new StreamedBlobRepository(db);
            TreePathStreamedBlobRepository tpsbrepo = new TreePathStreamedBlobRepository(db, blrepo);
            TagRepository tgrepo = new TagRepository(db);
            RefRepository rfrepo = new RefRepository(db);
            StageRepository strepo = new StageRepository(db);
            CommitRepository cmrepo = new CommitRepository(db);

            this.trrepo = trrepo;
            this.blrepo = blrepo;
            this.tpsbrepo = tpsbrepo;
            this.tgrepo = tgrepo;
            this.rfrepo = rfrepo;
            this.strepo = strepo;
            this.cmrepo = cmrepo;

            this.db = db;
        }
 public QueryBlobByPath(StreamedBlobRepository blrepo, TreeBlobPath treePath)
 {
     this._blrepo   = blrepo;
     this._treePath = treePath;
 }
Example #8
0
 public QueryBlob(StreamedBlobRepository blrepo, BlobID id)
 {
     this._blrepo = blrepo;
     this._id     = id;
 }
Example #9
0
 public PersistBlob(StreamedBlobRepository blrepo, PersistingBlob bl)
 {
     this._bl     = bl;
     this._blrepo = blrepo;
     this._length = -1;
 }