source: rtems/testsuites/psxtests/psxreaddir/psxreaddir.scn @ 1e566bbb

4.104.114.84.95
Last change on this file since 1e566bbb was 1e566bbb, checked in by Jennifer Averett <Jennifer.Averett@…>, on 11/17/00 at 19:06:40

2000-11-17 Jennifer Averret <jennifer@…>

  • psxmount/test.c, psxmount/psxmount.scn: Improve output to report expected error condition in one case.
  • psxreaddir/test.c, psxreaddir.scn: Added test cases to exercise readdir() of root of mounted filesystem. Also corrected the screen file for some mistakes noticed in this effort.
  • Property mode set to 100644
File size: 8.3 KB
Line 
1*** READDIR TEST ***
2chdir to the root directory
3chdir() status : 0
4Creating a series of directories under /
5Creating directory: a      0 0    Success
6Creating directory: b      0 0    Success
7Creating directory: c      0 0    Success
8Creating directory: d      0 0    Success
9Creating directory: e      0 0    Success
10Creating directory: f      0 0    Success
11Creating directory: c/y      0 0    Success
12Creating directory: c/z      0 0    Success
13Creating directory: c/x      0 0    Success
14Creating directory: c/y/a3333      0 0    Success
15Creating directory: c/y/j123      0 0    Success
16Create a lot of files
17Create a
18Create b
19Create c
20Create d
21Create e
22Create f
23Create g
24Create h
25Create i
26Create j
27Create k
28Create l
29Create m
30Create n
31Create o
32Create p
33Create q
34Create r
35Create s
36Create t
37Create u
38Create v
39Create w
40Create x
41Create y
42Create z
43Create aa
44Create ab
45Create ac
46Create ad
47Create ae
48Create af
49Create ag
50Create ah
51Create ai
52Create aj
53Create ak
54Create al
55Create am
56Create an
57Create ao
58Create ap
59Create aq
60Create ar
61Open /many and print the directory
62name               inode   offset   reclen  type
63a                          17        0    268   0x010c
64b                          18      268    268   0x010c
65c                          19      536    268   0x010c
66d                          20      804    268   0x010c
67e                          21     1072    268   0x010c
68f                          22     1340    268   0x010c
69g                          23     1608    268   0x010c
70h                          24     1876    268   0x010c
71i                          25     2144    268   0x010c
72j                          26     2412    268   0x010c
73k                          27     2680    268   0x010c
74l                          28     2948    268   0x010c
75m                          29     3216    268   0x010c
76n                          30     3484    268   0x010c
77o                          31     3752    268   0x010c
78p                          32     4020    268   0x010c
79q                          33     4288    268   0x010c
80r                          34     4556    268   0x010c
81s                          35     4824    268   0x010c
82t                          36     5092    268   0x010c
83u                          37     5360    268   0x010c
84v                          38     5628    268   0x010c
85w                          39     5896    268   0x010c
86x                          40     6164    268   0x010c
87y                          41     6432    268   0x010c
88z                          42     6700    268   0x010c
89aa                         43     6968    268   0x010c
90ab                         44     7236    268   0x010c
91ac                         45     7504    268   0x010c
92ad                         46     7772    268   0x010c
93ae                         47     8040    268   0x010c
94af                         48     8308    268   0x010c
95ag                         49     8576    268   0x010c
96ah                         50     8844    268   0x010c
97ai                         51     9112    268   0x010c
98aj                         52     9380    268   0x010c
99ak                         53     9648    268   0x010c
100al                         54     9916    268   0x010c
101am                         55    10184    268   0x010c
102an                         56    10452    268   0x010c
103ao                         57    10720    268   0x010c
104ap                         58    10988    268   0x010c
105aq                         59    11256    268   0x010c
106ar                         60    11524    268   0x010c
107open /b/myfile
108scandir a file status: -1
109Open /b/new_file
110fcntl F_SETFD should return 0
111fcntl F_SETFD should return 1
112fcntl F_DUPFD should return 0 -- skip until implemented
113fcntl F_GETFL returns current flags
114fcntl F_GETFL returned 0x200
115fcntl F_SETFL to add O_APPEND and O_NONBLOCK
116fcntl F_GETFL return current flags to see changes
117fcntl F_GETFL returned 0x1208
118fcntl F_GETLK should return -1
119fcntl F_SETLK should return -1
120fcntl F_SETLKW should return -1
121fcntl F_SETOWN should return -1
122fcntl F_GETOWN should return -1
123fcntl invalid argument should return -1
124Status -1
125opendir and readdir /b/myfile
126opendir and readdir
127chdir to /b/myfile
128Performing stat of directory /
129status for stat : 0, size of directory: 2144
130Open and print directory /
131name               inode   offset   reclen  type
132dev                         2        0    268   0x010c
133a                           5      268    268   0x010c
134b                           6      536    268   0x010c
135c                           7      804    268   0x010c
136d                           8     1072    268   0x010c
137e                           9     1340    268   0x010c
138f                          10     1608    268   0x010c
139many                       16     1876    268   0x010c
140mkdir /d/my_dir
141Open /d/my_dir
142remove /d/my_dir.
143close /d/my_dir.
144Opening directory /c
145name               inode   offset   reclen  type
146y                          11        0    268   0x010c
147z                          12      268    268   0x010c
148x                          13      536    268   0x010c
149Opening directory /c/y
150name               inode   offset   reclen  type
151a3333                      14        0    268   0x010c
152j123                       15      268    268   0x010c
153LSEEK to the start of the open directory
154name               inode   offset   reclen  type
155dev                         2        0    268   0x010c
156a                           5      268    268   0x010c
157b                           6      536    268   0x010c
158c                           7      804    268   0x010c
159d                           8     1072    268   0x010c
160e                           9     1340    268   0x010c
161f                          10     1608    268   0x010c
162many                       16     1876    268   0x010c
163Rewinding directory
164name               inode   offset   reclen  type
165dev                         2        0    268   0x010c
166a                           5      268    268   0x010c
167b                           6      536    268   0x010c
168c                           7      804    268   0x010c
169d                           8     1072    268   0x010c
170e                           9     1340    268   0x010c
171f                          10     1608    268   0x010c
172many                       16     1876    268   0x010c
173Send rewinddir a NULL pointer
174Seek directory
175telldir() should report only sizeof(struct dirent) increments
176in position. Sizeof(struct dirent): 268
177seeked to  0 -- currently at  0
178seeked to 67 -- currently at  0
179seeked to 134 -- currently at  0
180Send seekdir a NULL pointer
181Closing directory
182SCANDIR TEST
183selection rule 1
184scanning for any entry under directory /c
185SCANDIR SELECT1 accepts  nodename: y
186SCANDIR SELECT1 accepts  nodename: z
187SCANDIR SELECT1 accepts  nodename: x
188scandir status: 3
189Selected Node Name: y
190Selected Node Name: z
191Selected Node Name: x
192selection rule 2
193scanning for any entry under directory /c whose name = y
194SCANDIR SELECT accepted nodename: y
195SCANDIR SELECT rejected nodename: z
196SCANDIR SELECT rejected nodename: x
197scandir status: 1
198Selected Node Name: y
199SCANDIR with sorting
200selection rule 1
201scanning for any entry under directory /c
202sort in ascending order
203SCANDIR SELECT1 accepts  nodename: y
204SCANDIR SELECT1 accepts  nodename: z
205SCANDIR SELECT1 accepts  nodename: x
206scandir status: 3
207Selected and Sorted Node Name: x
208Selected and Sorted Node Name: y
209Selected and Sorted Node Name: z
210SCANDIR with sorting
211selection rule 1
212scanning for any entry under directory /c
213sort in descending order
214SCANDIR SELECT1 accepts  nodename: y
215SCANDIR SELECT1 accepts  nodename: z
216SCANDIR SELECT1 accepts  nodename: x
217scandir status: 3
218Selected and Sorted Node Name: z
219Selected and Sorted Node Name: y
220Selected and Sorted Node Name: x
221Validate readdir across mount point
222name               inode   offset   reclen  type
223should_be_hidden           65        0    268   0x010c
224Attempting to mount IMFS file system at /imfs
225create /imfs/testdir and /imfs/testdir/testsubdir
226name               inode   offset   reclen  type
227testdir                     2        0    268   0x010c
228name               inode   offset   reclen  type
229testdir                     2        0    268   0x010c
230name               inode   offset   reclen  type
231testdir                     2        0    268   0x010c
232name               inode   offset   reclen  type
233testsubdir                  3        0    268   0x010c
234name               inode   offset   reclen  type
235testdir                     2        0    268   0x010c
236*** END OF READDIR TEST ***
Note: See TracBrowser for help on using the repository browser.