summaryrefslogtreecommitdiffstats
path: root/cpukit/libtest/t-test-checks-psx.c
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2019-01-31 14:45:31 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2019-03-27 07:15:55 +0100
commitcfcc2cbf7aa4e6aeb6dca83d57cf2dae610d4d65 (patch)
tree7fd0d789fa32b56d2340c97544c77cf0f4cbfd0c /cpukit/libtest/t-test-checks-psx.c
parentbuild: Move test support to librtemstest.a (diff)
downloadrtems-cfcc2cbf7aa4e6aeb6dca83d57cf2dae610d4d65.tar.bz2
Add RTEMS Test Framework
Update #3199.
Diffstat (limited to 'cpukit/libtest/t-test-checks-psx.c')
-rw-r--r--cpukit/libtest/t-test-checks-psx.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/cpukit/libtest/t-test-checks-psx.c b/cpukit/libtest/t-test-checks-psx.c
new file mode 100644
index 0000000000..58e9fb64f5
--- /dev/null
+++ b/cpukit/libtest/t-test-checks-psx.c
@@ -0,0 +1,17 @@
+#include <t.h>
+
+#include <errno.h>
+
+void T_check_psx_error(int a, const T_check_context *t, int eeno)
+{
+ int aeno;
+
+ aeno = errno;
+ T_check_true(a == -1 && aeno == eeno, t, "%i == -1, %s == %s", a,
+ T_strerror(aeno), T_strerror(eeno));
+}
+
+void T_check_psx_success(int a, const T_check_context *t)
+{
+ T_check_true(a == 0, t, "%i == 0, %s", a, T_strerror(errno));
+}