summaryrefslogtreecommitdiff
path: root/test/liberasurecode_test.c
diff options
context:
space:
mode:
authorTushar Gohad <tushar.gohad@intel.com>2014-07-25 22:18:37 -0700
committerTushar Gohad <tushar.gohad@intel.com>2014-07-25 22:18:37 -0700
commit6671c45b03489ab19f2d74864e4bb94c0e1333e1 (patch)
tree8781529db298555a7ebac74c060ae420056ed70d /test/liberasurecode_test.c
parent124a8c61963c1fe6a7047951230f3247e2a374ed (diff)
downloadliberasurecode-6671c45b03489ab19f2d74864e4bb94c0e1333e1.tar.gz
Add liberasurecode_supported_backends API implementation
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com>
Diffstat (limited to 'test/liberasurecode_test.c')
-rw-r--r--test/liberasurecode_test.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/test/liberasurecode_test.c b/test/liberasurecode_test.c
index 58abce6..5dc342c 100644
--- a/test/liberasurecode_test.c
+++ b/test/liberasurecode_test.c
@@ -31,7 +31,8 @@
#include "erasurecode.h"
-typedef int (*TEST_FUNC)(const char *, struct ec_args *);
+// typedef int (*TEST_FUNC)(const char *, struct ec_args *);
+typedef int (*TEST_FUNC)();
struct testcase {
const char *description;
@@ -79,11 +80,14 @@ out:
return num_frags;
}
-static int test_liberasurecode_supported_backends(
- const char *backend,
- struct ec_args *args)
+static int test_liberasurecode_supported_backends()
{
- //EDL skipping for now since this function is not implemented.
+ int i, num_backends;
+ const char **supported_ec_backends =
+ liberasurecode_supported_backends(&num_backends);
+
+ for (i = 0; i < num_backends; i++)
+ printf("%s\n", supported_ec_backends[i]);
}
static int test_create_and_destroy_backend(
@@ -191,7 +195,7 @@ struct testcase testcases[] = {
{"liberasurecode_supported_backends",
test_liberasurecode_supported_backends,
NULL, NULL,
- .skip = true},
+ .skip = false},
{"create_and_destroy_backend",
test_create_and_destroy_backend,
"null", &null_args,