source: rtems/testsuites/psxtests/psxfile01/psxfile01.scn @ 9a4eca5

5
Last change on this file since 9a4eca5 was cf36b70, checked in by Sebastian Huber <sebastian.huber@…>, on 12/31/14 at 09:56:05

IMFS: Replace node union with individual struct

This reduces the average node size.

Add and use IMFS_GENERIC_INITIALIZER().

  • Property mode set to 100644
File size: 5.0 KB
Line 
1*** BEGIN OF TEST PSXFILE 1 ***
2stat of /dev/console
3....st_dev     (0xfffe:0x0)
4....st_rdev    (0x0:0x0)
5....st_ino     4  may vary by small amount
6....mode  = 00020755
7....nlink = 1
8....uid = 0
9....gid = 0
10....atime = Fri Jan  1 00:00:00 1988
11....mtime = Fri Jan  1 00:00:00 1988
12....ctime = Fri Jan  1 00:00:00 1988
13....st_blksize 0
14....st_blocks  0
15
16mkdir /dev/tty
17
18mkdir /usr
19mkdir /etc
20mkdir /tmp
21mkdir /tmp/..
22mkdir /tmp/
23mkdir /j/j1
24mkdir tmp
25
26rmdir /usr
27rmdir /dev
28rmdir /fred
29rmdir /tmp/bha
30mknod /dev/test_console
31mknod /dev/tty/S3
32mknod /etc/passwd
33mkdir /tmp/my_dir
34mkfifo /c/my_dir
35mkdir /etc/passwd/j
36open /tmp/joel - should fail with ENOENT
37open /tmp/j
38open returned file descriptor 3
39close /tmp/j
40close /tmp/j again
41unlink /tmp/j
42unlink /tmp
43create and close /tmp/tom
44Attempt to recreate /tmp/tom
45create /tmp/john
46Attempt to create a file, open in read-only mode and truncate it
47Exercise the reentrant version _link_r -- Expect ENOENT
48Unlink /tmp/bha using the reentrant version -- OK
49mknod with bad type - expect EINVAL
50open /tmp/bha in write only mode -- OK
51attempt fcntl on opened file -- OK
52attempt to read from /tmp/bha - expect EBADF
53closing and unlinking /tmp/bha
54open /tmp/bha in read only mode -- OK
55attempt to read from /tmp/bha - expect EBADF
56closing and unlinking /tmp/bha
57attempt to read from an unopened filedes - expect EBADF
58attempt to write to an unopened filedes - expect EBADF
59mknod /tmp/joel
60(0)the first write!!!
61
62rename /tmp/joel to /tmp/drjoel
63rename /tmp/drjoel to /tmp/joel
64rename /tmp/drjoel to /tmp/joel - Should result in an error since old path is not valid
65rename /tmp/joel to /tmp/drjoel/joel - Should result in an error since new path is not valid
66changing dir to /tmp
67rename joel to drjoel
68rename drjoel to joel
69creating directory /imfs
70creating directory /imfs/hidden_on_mount
71mounting filesystem with IMFS_ops at /imfs
72creating directory /imfs/test (on newly mounted filesystem)
73attempt to rename directory joel to /imfs/test/joel - should fail with EXDEV
74changing dir to /
75attempt to rename across filesystem, with old path having a parent node
76attempt to rename tmp/joel to /imfs/test/joel
77End of _rename_r tests
78(10)the first write!!!
79
80stat( /tmp/joel ) returned
81....st_dev     (0xfffe:0x0)
82....st_rdev    (0x0:0x0)
83....st_ino     17  may vary by small amount
84....mode  = 00100700
85....nlink = 1
86....uid = 0
87....gid = 0
88....atime = Sat Dec 31 09:00:00 1988
89....mtime = Sat Dec 31 09:00:00 1988
90....ctime = Sat Dec 31 09:00:00 1988
91....st_blksize 80
92....st_blocks  0
93unlink /tmp/joel
94unlink /tmp/joel
95mknod /tmp/joel
96(514)the first write!!!
97
98(513)the first write!!!
99
100(24)the first write!!!
101
102(2)the first write!!!
103
104(1)the first write!!!
105
106(0)the first write!!!
107
108(0)rst write!!!
109
110(513)the first write!!!
111
112Skipping maximum file size test since max_size is 4329344 bytes
113That is likely to be bigger than the available RAM on many targets.
114stat( /tmp/joel ) returned
115....st_dev     (0xfffe:0x0)
116....st_rdev    (0x0:0x0)
117....st_ino     18  may vary by small amount
118....mode  = 00100700
119....nlink = 1
120....uid = 0
121....gid = 0
122....atime = Sat Dec 31 09:00:00 1988
123....mtime = Sat Dec 31 09:00:00 1988
124....ctime = Sat Dec 31 09:00:00 1988
125....st_blksize 80
126....st_blocks  0
127stat of /tmp/j
128stat(/tmp/j) returned -1 (errno=2)
129....st_dev     (0x0:0x0)
130....st_rdev    (0x0:0x0)
131....st_ino     0  may vary by small amount
132....mode  = 00000000
133....nlink = 0
134....uid = 0
135....gid = 0
136....atime = Thu Jan  1 00:00:00 1970
137....mtime = Thu Jan  1 00:00:00 1970
138....ctime = Thu Jan  1 00:00:00 1970
139....st_blksize 0
140....st_blocks  0
141fopen of /tmp/j
142fprintf to /tmp/j
143(1) 26 characters written to the file
144(2) 26 characters written to the file
145(3) 26 characters written to the file
146(4) 26 characters written to the file
147(5) 26 characters written to the file
148....st_dev     (0xfffe:0x0)
149....st_rdev    (0x0:0x0)
150....st_ino     19  may vary by small amount
151....mode  = 00100644
152....nlink = 1
153....uid = 0
154....gid = 0
155....atime = Sat Dec 31 09:00:00 1988
156....mtime = Sat Dec 31 09:00:00 1988
157....ctime = Sat Dec 31 09:00:00 1988
158....st_blksize 80
159....st_blocks  0
160This is call 1 to fprintf
161This is call 2 to fprintf
162This is call 3 to fprintf
163This is call 4 to fprintf
164This is call 5 to fprintf
165....st_dev     (0xfffe:0x0)
166....st_rdev    (0x0:0x0)
167....st_ino     19  may vary by small amount
168....mode  = 00100644
169....nlink = 1
170....uid = 0
171....gid = 0
172....atime = Sat Dec 31 09:00:01 1988
173....mtime = Sat Dec 31 09:00:00 1988
174....ctime = Sat Dec 31 09:00:00 1988
175....st_blksize 80
176....st_blocks  0
177truncate /tmp/j to length of 40
178....st_dev     (0xfffe:0x0)
179....st_rdev    (0x0:0x0)
180....st_ino     19  may vary by small amount
181....mode  = 00100644
182....nlink = 1
183....uid = 0
184....gid = 0
185....atime = Sat Dec 31 09:00:01 1988
186....mtime = Sat Dec 31 09:00:02 1988
187....ctime = Sat Dec 31 09:00:02 1988
188....st_blksize 80
189....st_blocks  0
190truncate /tmp/j to length of 0
191truncate /tmp to length of 0 should fail with EISDIR
192
19321: Is a directory
194Writing First File
195Writing Second File
196(0)this is a test line
197this is a test line
198
199(0)this is a test line
200this is a test line
201
202*** END OF TEST PSXFILE 1 ***
Note: See TracBrowser for help on using the repository browser.