add getCoverPageImage api for CreDocument

This commit is contained in:
chrox committed 2014-08-22 21:32:03 +08:00
1 parent baae364571
commit 7048ca971b
2 files changed
+18

No files matched your search

+6
View File
@@ -54,6 +54,12 @@ describe("EPUB document module", function()
doc = DocumentRegistry:openDocument(sample_epub)
assert.truthy(doc)
end)
it("should get cover image", function()
local image = doc:getCoverPageImage()
assert.truthy(image)
assert.are.same(image:getWidth(), 442)
assert.are.same(image:getHeight(), 616)
end)
it("should close document", function()
doc:close()
end)