Exemplo n.º 1
0
        public void TestEpilogueFolding()
        {
            const string text     = "This is a multipart epilogue.";
            const string expected = "\nThis is a multipart epilogue.\n";
            var          options  = FormatOptions.Default.Clone();

            options.NewLineFormat = NewLineFormat.Unix;

            var actual = Multipart.FoldPreambleOrEpilogue(options, text, true);

            Assert.AreEqual(expected, actual, "Folded multipart preamble does not match.");
        }
Exemplo n.º 2
0
        public void TestPreambleFolding()
        {
            const string text     = "This is a multipart MIME message. If you are reading this text, then it means that your mail client does not support MIME.\n";
            const string expected = "This is a multipart MIME message. If you are reading this text, then it means\nthat your mail client does not support MIME.\n";
            var          options  = FormatOptions.Default.Clone();

            options.NewLineFormat = NewLineFormat.Unix;

            var actual = Multipart.FoldPreambleOrEpilogue(options, text, false);

            Assert.AreEqual(expected, actual, "Folded multipart preamble does not match.");
        }