[arrayfire] 133/284: Use isImageIOAvailable in testHelper

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Sun Feb 7 18:59:26 UTC 2016


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to branch debian/experimental
in repository arrayfire.

commit 7747ee6bf0ba1719a21faf86e142201d92b75b5f
Author: Shehzan Mohammed <shehzan at arrayfire.com>
Date:   Thu Dec 31 12:31:33 2015 -0500

    Use isImageIOAvailable in testHelper
---
 test/testHelpers.hpp | 12 +++---------
 1 file changed, 3 insertions(+), 9 deletions(-)

diff --git a/test/testHelpers.hpp b/test/testHelpers.hpp
index 758bf98..0b22cef 100644
--- a/test/testHelpers.hpp
+++ b/test/testHelpers.hpp
@@ -390,15 +390,9 @@ bool noDoubleTests()
 
 bool noImageIOTests()
 {
-    af_array arr = 0;
-    const af_err err = af_load_image(&arr, TEST_DIR"/imageio/color_small.png", true);
-
-    if(arr != 0) af_release_array(arr);
-
-    if(err == AF_ERR_NOT_CONFIGURED)
-        return true;    // Yes, disable test
-    else
-        return false;   // No, let test continue
+    bool ret = !af::isImageIOAvailable();
+    if(ret) printf("Image IO Not Configured. Test will exit\n");
+    return ret;
 }
 
 bool noLAPACKTests()

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/arrayfire.git



More information about the debian-science-commits mailing list