Skip to content

Commit 7688b29

Browse files
committed
test: 增加单元测试
1 parent e0f781b commit 7688b29

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

test/UnitTest/Services/Html2PdfServiceTest.cs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,14 @@ public async Task ExportPdf_Error()
2121
await Assert.ThrowsAsync<NotImplementedException>(() => pdfService.PdfDataFromHtmlAsync("<h2>Test</h2>"));
2222
await Assert.ThrowsAsync<NotImplementedException>(() => pdfService.PdfStreamFromHtmlAsync("<h2>Test</h2>"));
2323
}
24+
25+
[Fact]
26+
public void PdfOptions_Ok()
27+
{
28+
var options = new PdfOptions
29+
{
30+
Landscape = true
31+
};
32+
Assert.True(options.Landscape);
33+
}
2434
}

0 commit comments

Comments
 (0)