diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2007-05-11 19:44:22 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2007-05-11 19:44:22 +0000 |
commit | e02db20c46ddd3d6cb66e9c3facbf40887fc5017 (patch) | |
tree | ca3713abc57bfa8b6667f5e87038245fed74bc1b | |
parent | 2007-05-11 Joel Sherrill <joel.sherrill@OARcorp.com> (diff) | |
download | rtems-e02db20c46ddd3d6cb66e9c3facbf40887fc5017.tar.bz2 |
2007-05-11 Joel Sherrill <joel.sherrill@OARcorp.com>
* psxsem01/init.c, psxsem01/psxsem01.scn, psxtimer/psxtimer.c,
psxtimer/psxtimer.scn: Add optional managers to Makefiles. Clean up
test cases so last output line follows END OF pattern. Make sure test
case all run. All tests appeared ok on sis.
-rw-r--r-- | testsuites/psxtests/ChangeLog | 7 | ||||
-rw-r--r-- | testsuites/psxtests/psxsem01/init.c | 12 | ||||
-rw-r--r-- | testsuites/psxtests/psxsem01/psxsem01.scn | 4 | ||||
-rw-r--r-- | testsuites/psxtests/psxtimer/psxtimer.c | 2 | ||||
-rw-r--r-- | testsuites/psxtests/psxtimer/psxtimer.scn | 2 |
5 files changed, 22 insertions, 5 deletions
diff --git a/testsuites/psxtests/ChangeLog b/testsuites/psxtests/ChangeLog index 91680087a7..21e0406e7e 100644 --- a/testsuites/psxtests/ChangeLog +++ b/testsuites/psxtests/ChangeLog @@ -1,3 +1,10 @@ +2007-05-11 Joel Sherrill <joel.sherrill@OARcorp.com> + + * psxsem01/init.c, psxsem01/psxsem01.scn, psxtimer/psxtimer.c, + psxtimer/psxtimer.scn: Add optional managers to Makefiles. Clean up + test cases so last output line follows END OF pattern. Make sure test + case all run. All tests appeared ok on sis. + 2007-04-05 Joel Sherrill <joel@OARcorp.com> * psx01/init.c, psx01/psx01.scn: Adjust test to account for nanosleep() diff --git a/testsuites/psxtests/psxsem01/init.c b/testsuites/psxtests/psxsem01/init.c index 3d8b43f97a..ce64452926 100644 --- a/testsuites/psxtests/psxsem01/init.c +++ b/testsuites/psxtests/psxsem01/init.c @@ -114,12 +114,22 @@ void *POSIX_Init( fatal_posix_service_status( status, -1, "sem_timedwait error return status"); fatal_posix_service_status( errno, ETIMEDOUT, "sem_timedwait errno ETIMEDOUT"); + + /* + * To do this case, we must be blocking when we want the semaphore. + * POSIX doesn't want you to check the error if you can get the resource. + */ + +#if 1 + puts( "Init: sem_timedwait - UNSUCCESSFUL (EINVAL) -- skipping" ); +#else puts( "Init: sem_timedwait - UNSUCCESSFUL (EINVAL)" ); waittime.tv_sec = 0; waittime.tv_nsec = 0x7FFFFFFF; status = sem_timedwait(&sems[2], &waittime); fatal_posix_service_status( status, -1, "sem_timedwait error return status"); fatal_posix_service_status( errno, EINVAL, "sem_init errno EINVAL"); +#endif puts( "Init: sem_post - UNSUCCESSFUL (EINVAL)" ); status = sem_post(&sem2); @@ -254,7 +264,7 @@ void *POSIX_Init( /* Try adding in unlinking before closing... (can we still open?) */ - puts( "*** POSIX SEMAPHORE MANAGER TEST 1 COMPLETED ***" ); + puts( "*** END OF POSIX SEMAPHORE MANAGER TEST 1 ***" ); rtems_test_exit(0); return NULL; /* just so the compiler thinks we returned something */ diff --git a/testsuites/psxtests/psxsem01/psxsem01.scn b/testsuites/psxtests/psxsem01/psxsem01.scn index cf8cf13fb1..a63fa15bbb 100644 --- a/testsuites/psxtests/psxsem01/psxsem01.scn +++ b/testsuites/psxtests/psxsem01/psxsem01.scn @@ -12,7 +12,7 @@ Init: sem_post - SUCCESSFUL Init: sem_wait - SUCCESSFUL (after a sem_post) Init: sem_trywait - SUCCESSFUL Init: sem_trywait - UNSUCCESSFUL (EAGAIN) -Init: sem_trywait - UNSUCCESSFUL (EINVAL) +Init: sem_trywait - UNSUCCESSFUL (EINVAL) -- skipping Init: sem_timedwait - SUCCESSFUL Init: sem_timedwait - UNSUCCESSFUL (ETIMEDOUT) Init: sem_timedwait - UNSUCCESSFUL (EINVAL) @@ -33,5 +33,5 @@ Init: sem_unlink - UNSUCCESSFUL (ENOENT) Init: sem_unlink (NULL) - EINVAL Init: sem_unlink ("") - EINVAL Init: sem_unlink - UNSUCCESSFUL (ENOENT) -*** POSIX SEMAPHORE MANAGER TEST 1 COMPLETED *** +*** END OF POSIX SEMAPHORE MANAGER TEST 1 *** diff --git a/testsuites/psxtests/psxtimer/psxtimer.c b/testsuites/psxtests/psxtimer/psxtimer.c index ac4a7b9de1..ba79b8b266 100644 --- a/testsuites/psxtests/psxtimer/psxtimer.c +++ b/testsuites/psxtests/psxtimer/psxtimer.c @@ -334,6 +334,6 @@ void *POSIX_Init ( /* execute 20 seconds and finish */ sleep (20); - puts( "\n\n*** End of POSIX Timers Test ***" ); + puts( "\n\n*** END OF POSIX Timers Test ***" ); rtems_test_exit (0); } diff --git a/testsuites/psxtests/psxtimer/psxtimer.scn b/testsuites/psxtests/psxtimer/psxtimer.scn index e9940d077e..5d9ce6ab89 100644 --- a/testsuites/psxtests/psxtimer/psxtimer.scn +++ b/testsuites/psxtests/psxtimer/psxtimer.scn @@ -34,4 +34,4 @@ Executing task C with x = 9 Fri Jan 1 00:00:18 1988 Executing task A Fri Jan 1 00:00:18 1988 Executing task A Fri Jan 1 00:00:19 1988 Executing task B with x = 10 Fri Jan 1 00:00:20 1988 -*** End of POSIX Timers Test *** +*** END OF POSIX Timers Test *** |