public void Check_04() { var input = "123/some.file"; var expected = "some.file"; var actual = BCFv21Container.GetFilenameFromReference(input); Assert.Equal(expected, actual); }
public void Check_01() { var container = BcfTestCaseFactory.GetContainerByTestName(TestCaseEnum.MaximumInformation); var references = container.Topics.SelectMany(t => t.Markup.Topic.DocumentReferences); foreach (var currentDocument in references.Where(r => !r.isExternal)) { var retrievedFile = container.GetAttachmentForDocumentReference(currentDocument); Assert.NotNull(retrievedFile); Assert.True(retrievedFile.SequenceEqual( container.FileAttachments[BCFv21Container.GetFilenameFromReference(currentDocument.ReferencedDocument)])); } }
public void EmptyOnEmptyInput() { Assert.True(string.IsNullOrWhiteSpace(BCFv21Container.GetFilenameFromReference(string.Empty))); }