summaryrefslogtreecommitdiffstats
path: root/testsuites/fstests/fsimfsconfig01/init.c
diff options
context:
space:
mode:
Diffstat (limited to 'testsuites/fstests/fsimfsconfig01/init.c')
-rw-r--r--testsuites/fstests/fsimfsconfig01/init.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/testsuites/fstests/fsimfsconfig01/init.c b/testsuites/fstests/fsimfsconfig01/init.c
index 1d449d6828..dd587fae4c 100644
--- a/testsuites/fstests/fsimfsconfig01/init.c
+++ b/testsuites/fstests/fsimfsconfig01/init.c
@@ -19,6 +19,7 @@
#include "tmacros.h"
#include <sys/stat.h>
+#include <dirent.h>
#include <errno.h>
#include <fcntl.h>
#include <stdio.h>
@@ -46,6 +47,9 @@ static void Init(rtems_task_argument arg)
const char *fifo = "fifo";
int rv;
int fd;
+ DIR *dirp;
+ struct dirent *dire;
+ struct stat st;
TEST_BEGIN();
@@ -88,6 +92,21 @@ static void Init(rtems_task_argument arg)
rtems_test_assert(rv == -1);
rtems_test_assert(errno == ENOSYS);
+ dirp = opendir(mnt);
+ rtems_test_assert(dirp != NULL);
+
+ errno = 0;
+ dire = readdir(dirp);
+ rtems_test_assert(dire == NULL);
+ rtems_test_assert(errno == ENOTSUP);
+
+ rv = closedir(dirp);
+ rtems_test_assert(rv == 0);
+
+ rv = stat(mnt, &st);
+ rtems_test_assert(rv == 0);
+ rtems_test_assert(st.st_size == 0);
+
errno = 0;
rv = mount(
"",
@@ -145,6 +164,7 @@ static void Init(rtems_task_argument arg)
#define CONFIGURE_IMFS_DISABLE_MKNOD_FILE
#define CONFIGURE_IMFS_DISABLE_MOUNT
#define CONFIGURE_IMFS_DISABLE_RENAME
+#define CONFIGURE_IMFS_DISABLE_READDIR
#define CONFIGURE_IMFS_DISABLE_RMNOD
#define CONFIGURE_IMFS_DISABLE_SYMLINK
#define CONFIGURE_IMFS_DISABLE_UTIME