Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/torch/image.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'test/test.lua')
-rw-r--r--test/test.lua11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/test.lua b/test/test.lua
index 80299e9..0a25cd9 100644
--- a/test/test.lua
+++ b/test/test.lua
@@ -635,6 +635,17 @@ function test.test_pbmload()
end
----------------------------------------------------------------------
+-- Load unknown image type without extension test
+--
+function test.LoadUnknownImageTypeWithoutExtension()
+ tester:assertErrorPattern(
+ function() image.load(getTestImagePath("bmp-without-ext")) end,
+ "unable to determine image type for file",
+ "unknown image type should not be loaded or unexpected error message"
+ )
+end
+
+----------------------------------------------------------------------
-- Text drawing test
--
function test.test_textdraw()