Пример #1
0
        public void Projected(int expectedDocId, int projectedAt, bool isPending)
        {
            var expectedDocumentId = new DocumentDescriptorId(expectedDocId);

            _writer.Promise(_documentHandle, 10);
            _writer.LinkDocument(_documentHandle, _document2, projectedAt);

            var h = _writer.FindOneById(_documentHandle);

            Assert.NotNull(h);
            Assert.AreEqual(10, h.CreatetAt);
            Assert.IsNull(h.FileName);

            if (h.ProjectedAt >= h.CreatetAt)
            {
                Assert.AreEqual(expectedDocumentId, h.DocumentDescriptorId);
                Assert.AreEqual(projectedAt, h.ProjectedAt);
            }

            Assert.AreEqual(isPending, h.IsPending());
        }