1 #DESCRIPTION:A small subset of the syscalls
3 # Basic test for access(2) using F_OK, R_OK, W_OK and X_OK arguments.
5 # EFAULT error testing for access(2)
7 # Basic test for alarm(2)
9 # Boundary Value Test for alarm(2)
11 # Test Case One - A call to alarm() shall not return an error if
13 # Test FAILS if a non-zero value is returned.
14 # Test Case Two - A call to alarm() shall not return an error if
15 # seconds is the maximum unsigned integer (2**63).
16 # Test FAILS if a non-zero value is returned.
17 # Test Case Three - A call to alarm() shall not return an error if
18 # seconds is the maximum unsigned integer plus 1 ((2**63)+1).
19 # Test FAILS if a non-zero value is returned.
21 # alarm(2) cleared by a fork
23 # 1.) alarm(100), fork, child's alarm(0) shall return 0;
24 # 2.) alarm(100), fork, parent's alarm(0) shall return non-zero.
26 # Attempt to get some memory to work with.
27 # Call testrun writing (BUFSIZ + 1) bytes
28 # Call testrun writing BUFSIZ bytes
29 # Repeated call to testrun() with decreasing write sizes
34 # Attempt to open a temporary file.
35 # Write the memory to the file.
36 # Attempt to close the file which also flushes the buffers.
37 # Now check to see if the number of bytes written is the
38 # same as the number of bytes in the file.
41 # Basic test for brk()
43 # 1.) brk(2) returns...
45 # Basic test for chdir(2)
47 # 1.) chdir(2) returns...
49 # Basic test for chmod(2)
51 # 1.) chmod(2) returns...
53 # Basic test for chown(2)
55 # 1.) chown(2) returns...
57 # Basic test for close(2)
59 # 1.) close(2) returns...
61 # Basic test for creat(2) using 0700 argument.
63 # 1.) creat(2) returns...
65 # Basic test for dup(2)
67 # 1.) dup(2) returns...(See Description)
69 # Negative test for dup(2) with bad fd
71 # 1-?.) dup(2) returns -1 with errno set to EBADF...(See Description)
73 # Negative test for dup(2) (too many fds)
75 # Basic test for dup(2) of a system pipe descriptor
77 # Basic test for dup(2) of a named pipe descriptor
79 # Basic test for execl(2)
81 # Basic test for execle(2)
83 # Basic test for execlp(2
85 # Basic test for execv(2)
87 # Basic test for execve(2)
89 # Basic test for execvp(2)
91 # This is a simple test for handling of the pentium f00f bug.
92 # It is an example of a catistrophic test case. If the system
93 # doesn't correctly handle this test, it will likely lockup.
95 # Basic test for fchmod(2) using 0700 argument.
97 # Basic test for fchown(2)
99 # Basic test for fcntl(2) using F_DUPFD argument
101 # Basic test for fcntl(2) using F_GETFD argument
103 # Basic test for fcntl(2) using F_GETFL argument
105 # Basic test for fcntl(2) using F_GETLK argument
107 # Close-On-Exec functional test
109 # 1.) test close-on-exec with a regular file
110 # 2.) test close-on-exec with a system pipe
112 # Close-On-Exec of named pipe functional test
114 # 1.) test close-on-exec with a named pipe
116 # Basic test for fcntl(2) using F_SETFL argument
118 # Basic test for fcntl(2) using F_SETLK argument
120 # Basic test for fcntl(2) using F_SETLKW argument
122 # Basic test for fork(2)
124 # 1.) fork returns without error
125 # 2.) fork returns the pid of the child
127 # Child inheritance of Environment Variables after fork()
129 # Test these environment variables correctly inherited by child:
134 # This is a test sent in my Ulrich Drepper to test for a bug in fork() where
135 # %gs is not handled correctly. See fork05.c for a copy of Ulrich's email
136 fpathconf01 fpathconf01
137 # Basic test for fpathconf(2)
139 # Basic test for fstat(2)
141 # Basic test for fstatfs(2)
143 # Basic test for fsync(2)
145 # Basic test for getegid(2)
147 # Basic test for geteuid(2)
149 # Basic test for getgid(2)
150 getgroups01 getgroups01
151 # Getgroups system call critical test
153 # 1. Check to see if getgroups(-1, gidset) fails and sets errno to EINVAL
154 # 2. Check to see if getgroups(0, gidset) does not return -1 and gidset is
156 # 3. Check to see if getgroups(x, gigset) fails and sets errno to EINVAL,
157 # where x is one less then what is returned by getgroups(0, gidset).
158 # 4. Check to see if getgroups() succeeds and gidset contains
159 # group id returned from getgid().
160 getgroups02 getgroups02
161 # Basic test for getgroups(2)
162 gethostid01 gethostid01
163 # Basic test for gethostid(2)
164 gethostname01 gethostname01
165 # Basic test for gethostname(2)
167 # Basic test for getpgrp(2)
169 # Basic test for getpid(2)
171 # Basic test for getppid(2)
173 # Basic test for getuid(2)
175 # Sending a signal to processes with the same process group ID.
177 # Basic test for kill(2)
179 # Basic test for link(2)
183 # Negative test cases for link(2)
185 # multi links (EMLINK) negative test
187 # Basic test for lseek(2)
189 # Negative test for lseek(2)
191 # Negative test for lseek(2) whence
193 # Negative test for lseek(2) of a fifo
195 # Negative test for lseek(2) of a pipe
197 # Basic test for lstat(2)
199 # Basic errno test for mkdir(2)
201 # Basic test for mkdir(2)
205 # Basic test for nice(2)
207 # Basic test for open(2)
208 pathconf01 pathconf01
209 # Basic test for pathconf(2)
211 # Basic test for pause(2)
213 # Basic test for read(2)
215 # write multiple files and try to find them with readdir
217 # 1.) Create n files and check that readdir() finds n files
218 readlink02 readlink02
219 # Basic test for readlink(2)
221 # Basic test for rename(2)
223 # Basic test for rmdir(2)
225 # rmdir(2) test for errno(s) EINVAL, EMLINK, EFAULT
227 # Basic test for sbrk(2)
231 # 1.) select(2) to a fd of regular file with no I/O and small timeout
233 # select of system pipe fds
235 # select of fd of a named-pipe (FIFO)
237 # Basic test for setgid(2)
239 # Basic test for setpgid(2)
241 # Basic test for setpgrp(2)
242 setregid01 setregid01
243 # Basic test for setregid(2)
244 setreuid01 setreuid01
245 # Basic test for setreuid(2)
247 # Basic test for setuid(2)
249 # Holding all signals
251 # Boundary value and other invalid value checking of signal setup
252 # and signal sending.
253 sigrelse01 sigrelse01
254 # Releasing held signals
256 # Basic test for stat(2)
258 # Negative tests for stat(2)
260 # Basic test for statfs(2) mounted filesys
262 # Basic test for statvfs(2) mounted filesys
264 # Basic test for sync(2)
266 # Basic test for time(2)
268 # Basic test for times(2)
270 # Basic test for ulimit(2)
272 # Basic test for umask(2)
274 # Basic test for uname(2)
276 # Basic test for unlink(2)
278 # unlink(2) of a FIFO
280 # unlink(2) negative testcases
282 # unlink(2) negative testcases
284 # Basic test for wait(2)
286 # Basic test for write(2)
288 # Make a Symbolic Link to a File
290 # 1. Create symbolic link with abnormal object name path
291 # 2. Create symbolic link with normal object name path
292 # 3. Create symbolic link with path to an existing object file
293 # 4. Receive EEXIST error when creating an already existing symbolic link file.
294 # 5. Receive ENAMETOOLONG error when creating symbolic link which exceeds PATH_MAX in length
296 # Basic test for symlink(2)
297 readlink01A symlink01 -T readlink01
298 # Reads Value of a Symbolic Link
300 # 1. Read a symbolic link file which points at no object file
301 # 2. Read a symbolic link file which points at an object file
302 # 3. Receive ENAMETOOLONG error when reading symbolic link which exceeds PATH_MAX in length
303 # 4. Receive an EINVAL error when reading a file which is not a symbolic
305 stat04 symlink01 -T stat04
306 # Gets File Status Indirectly From a Symbolic Link File
308 # 1. Get object file status through symbolic link file
309 # 2. Receive ENOENT error when accessing non-existent object file through symbolic link file
310 # 3. Receive ELOOP error when nesting of symbolic links exceed maximum
311 lstat01A symlink01 -T lstat01
312 # Get file Status About a Symbolic Link File
314 # 1. Get symbolic link file status when pointing at no object file
315 # 2. Get symbolic link file status when pointing at an object file
316 # 3. Get object file status when argument is not a symbolic link
318 mkdir05A symlink01 -T mkdir05
319 # Fail When Making a Directory File Indirectly From a Symbolic Link File
321 # 1. Receive EEXIST error when creating a directory through a symbolic link file
322 rmdir03A symlink01 -T rmdir03
323 # Fail When Removing a Directory File Indirectly From a Symbolic Link File
325 # 1. Receive ENOTDIR error when removing an existing directory through a symbolic link file
326 chdir01A symlink01 -T chdir01
327 # Changes Current Working DIrectory Location Indirectly From a Symbolic Link File
329 # 1. Change current working directory through a symbolic link file
330 # 2. Receive ENOENT error when accessing non-existent directory through symbolic link file
331 # 3. Receive ELOOP error when nesting of symbolic links exceed maximum
332 link01 symlink01 -T link01
333 # Creates a Link To a File Indirectly From a Symbolic Link File
335 # 1. Link an object file to a new file through symbolic link file
336 # 2. Receive ENOENT error when accessing non-existent object file through symbolic link file
337 # 3. Receive ELOOP error when nesting of symbolic links exceed maximum
338 unlink01 symlink01 -T unlink01
339 # Removes a Link To a File And Not Any Object File Which Maybe Pointed At
341 # 1. Delete a symbolic link file and not the object file which it points at
342 chmod01A symlink01 -T chmod01
343 # Change Object File Permissions Indirectly From a Symbolic Link File
345 # 1. Change file permissions of object file through a symbolic link file
346 # 2. Receive ENOENT error when accessing non-existent directory through symbolic link file
347 # 3. Receive ELOOP error when nesting of symbolic links exceed maximum
348 utime01A symlink01 -T utime01
349 # Set File Access And Modify Object File Times Indirectly From a Symbolic Link File
351 # 1. Change inode times of object file through a symbolic link file
352 # 2. Receive ENOENT error when accessing non-existent directory through symbolic link file
353 # 3. Receive ELOOP error when nesting of symbolic links exceed maximum
354 rename01A symlink01 -T rename01
355 # Rename a Symbolic Link File And Not Any Object File
357 # 1. Rename a symbolic link file which points at no object file
358 # 2. Rename a symbolic link file which points at an object file without any object file alterations.
359 # 3. Receive EXDEV when trying to rename a symbolic link file to an address outside of current file system
360 open01A symlink01 -T open01
361 # Create/Open a File For Reading Or Writing Indirectly From a Symbolic Link File
363 # 1. Create an object file through a symbolic link file
364 # 2. Open an object file through a symbolic link file
365 # 3. Receive EEXIST error when exclusively creating an object file through a symbolic link file
366 # 4. Receive ENOENT error when accessing non-existent object file through symbolic link file
367 # 5. Receive ELOOP error when nesting of symbolic links exceed maximum