add getCoverPageImage api for CreDocument

This commit is contained in:
chrox
2014-08-22 18:24:49 +08:00
parent baae364571
commit 7048ca971b
2 changed files with 18 additions and 0 deletions

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)