summaryrefslogtreecommitdiffstats
path: root/testsuites
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>1999-11-09 13:38:00 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>1999-11-09 13:38:00 +0000
commita8df60b31dfff4a62cd3cf14ec27efb044bcc85c (patch)
tree27d76ab4b45695685a8933580e076977d942baee /testsuites
parentNew files. (diff)
downloadrtems-a8df60b31dfff4a62cd3cf14ec27efb044bcc85c.tar.bz2
New test for POSIX Message Queues added.
Diffstat (limited to 'testsuites')
-rw-r--r--testsuites/psxtests/Makefile.am2
-rw-r--r--testsuites/psxtests/psxmsgq01/init.c28
-rw-r--r--testsuites/psxtests/psxmsgq01/psxmsgq01.scn3
-rw-r--r--testsuites/psxtests/psxmsgq01/system.h56
4 files changed, 88 insertions, 1 deletions
diff --git a/testsuites/psxtests/Makefile.am b/testsuites/psxtests/Makefile.am
index 7cd45b9bf8..937dec902f 100644
--- a/testsuites/psxtests/Makefile.am
+++ b/testsuites/psxtests/Makefile.am
@@ -14,7 +14,7 @@ $(PREINSTALLDIRS):
all-local: $(PREINSTALLDIRS)
POSIX_DIRS = psxhdrs psx01 psx02 psx03 psx04 psx05 psx06 psx07 psx08 psx09 \
- psx10 psx11 psx12 psxtime psxtimer psxcancel
+ psx10 psx11 psx12 psxtime psxtimer psxcancel psxmsgq01 psxsem01
POSIX_FILES_DIRS = psxfile01 psxreaddir psxstat psxmount psx13
diff --git a/testsuites/psxtests/psxmsgq01/init.c b/testsuites/psxtests/psxmsgq01/init.c
new file mode 100644
index 0000000000..f6cebb4635
--- /dev/null
+++ b/testsuites/psxtests/psxmsgq01/init.c
@@ -0,0 +1,28 @@
+/*
+ * COPYRIGHT (c) 1989-1998.
+ * On-Line Applications Research Corporation (OAR).
+ * Copyright assigned to U.S. Government, 1994.
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.OARcorp.com/rtems/license.html.
+ *
+ * $Id$
+ */
+
+#define CONFIGURE_INIT
+#include "system.h"
+#include <sched.h>
+
+void *POSIX_Init(
+ void *argument
+)
+{
+
+ puts( "\n\n*** POSIX MESSAGE QUEUE TEST ***" );
+
+ puts( "*** END OF POSIX MESSAGE QUEUE TEST ***" );
+ exit( 0 );
+
+ return NULL; /* just so the compiler thinks we returned something */
+}
diff --git a/testsuites/psxtests/psxmsgq01/psxmsgq01.scn b/testsuites/psxtests/psxmsgq01/psxmsgq01.scn
new file mode 100644
index 0000000000..3adecad0d5
--- /dev/null
+++ b/testsuites/psxtests/psxmsgq01/psxmsgq01.scn
@@ -0,0 +1,3 @@
+*** POSIX MESSAGE QUEUE TEST ***
+
+*** END OF POSIX MESSAGE QUEUE TEST ***
diff --git a/testsuites/psxtests/psxmsgq01/system.h b/testsuites/psxtests/psxmsgq01/system.h
new file mode 100644
index 0000000000..9ff369cc01
--- /dev/null
+++ b/testsuites/psxtests/psxmsgq01/system.h
@@ -0,0 +1,56 @@
+/* system.h
+ *
+ * This include file contains information that is included in every
+ * function in the test set.
+ *
+ * COPYRIGHT (c) 1989-1998.
+ * On-Line Applications Research Corporation (OAR).
+ * Copyright assigned to U.S. Government, 1994.
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.OARcorp.com/rtems/license.html.
+ *
+ * $Id$
+ */
+
+/* functions */
+
+#include <pmacros.h>
+#include <unistd.h>
+#include <errno.h>
+#include <sched.h>
+
+void *POSIX_Init(
+ void *argument
+);
+
+void *Task_1_through_3(
+ void *argument
+);
+
+/* configuration information */
+
+#define CONFIGURE_SPTEST
+
+#define CONFIGURE_TEST_NEEDS_CONSOLE_DRIVER
+#define CONFIGURE_TEST_NEEDS_CLOCK_DRIVER
+
+#define CONFIGURE_POSIX_INIT_THREAD_TABLE
+
+#define CONFIGURE_MAXIMUM_POSIX_THREADS 2
+
+#include <confdefs.h>
+
+/* global variables */
+
+#ifdef CONFIGURE_INIT
+#define TEST_EXTERN
+#else
+#define TEST_EXTERN extern
+#endif
+
+TEST_EXTERN pthread_t Init_id;
+TEST_EXTERN pthread_t Task_id;
+
+/* end of include file */