public void ChartTrackingRefBasedTest03DeleteAddElement()
        {
            using (var stream = new MemoryStream())
            {
                GeneratedDocument.CreatePackage(stream);

                var testEntities = new TestEntities(stream);
                testEntities.DeleteElements(stream, Log);
                testEntities.VerifyDeleteElements(stream, Log);

                testEntities.AddElements(stream, Log);
                testEntities.VerifyAddElements(stream, Log);
            }
        }
Exemplo n.º 2
0
        public void ChartTrackingRefBasedTest03DeleteElement()
        {
            string originalFilepath = GetTestFilePath(generateDocumentFile);
            string deleteFilePath   = GetTestFilePath(deleteDocumentFile);
            string addFilePath      = GetTestFilePath(addDocumentFile);

            System.IO.File.Copy(originalFilepath, deleteFilePath, true);
            Log.Comment("File copy [{0}] to [{1}]", originalFilepath, deleteFilePath);

            testEntities.DeleteElements(deleteFilePath, Log);
            testEntities.VerifyDeleteElements(deleteFilePath, Log);

            System.IO.File.Copy(deleteFilePath, addFilePath, true);
            Log.Comment("File copy [{0}] to [{1}]", originalFilepath, deleteFilePath);

            testEntities.AddElements(addFilePath, Log);
            testEntities.VerifyAddElements(addFilePath, Log);

            Log.Pass("Element deletion is complete.");
        }