summaryrefslogtreecommitdiffstats
path: root/testsuites/psxtests/psxfile01/test.c
diff options
context:
space:
mode:
authorChris Johns <chrisj@rtems.org>2017-10-19 16:39:16 +1100
committerChris Johns <chrisj@rtems.org>2017-10-23 16:25:45 +1100
commit98c6d501452f02264ff148a1b8479e420c81562d (patch)
tree8c6cd90ccd1df98f782396d94d6acdbfe5d042cb /testsuites/psxtests/psxfile01/test.c
parentposix: Fix POSIX disabled build (diff)
downloadrtems-98c6d501452f02264ff148a1b8479e420c81562d.tar.bz2
testsuite: Use printk for all test output where possible.
- Remove the printf support leaving the direct printk support configured with TESTS_USE_PRINTK and all other output goes via a buffered vsniprintf call to printk. - Control the test's single init for functions and global data with TEST_INIT and not CONFIGURE_INIT. They are now separate. Updates #3170.
Diffstat (limited to 'testsuites/psxtests/psxfile01/test.c')
-rw-r--r--testsuites/psxtests/psxfile01/test.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/testsuites/psxtests/psxfile01/test.c b/testsuites/psxtests/psxfile01/test.c
index 8fcb281307..4f53c1de8a 100644
--- a/testsuites/psxtests/psxfile01/test.c
+++ b/testsuites/psxtests/psxfile01/test.c
@@ -118,7 +118,6 @@ void stat_a_file(
rtems_test_assert( file );
printf( "stat( %s ) returned ", file );
- fflush( stdout );
status = stat( file, &statbuf );
@@ -335,7 +334,7 @@ int main(
status = close( fd );
rtems_test_assert( status == 0 );
- /*
+ /*
* Open a file in read-only mode and try to truncate
*/
@@ -362,7 +361,7 @@ int main(
rtems_test_assert( status == -1 );
rtems_test_assert( errno == EINVAL );
- /*
+ /*
* Read from filedes opened for write
*/
@@ -387,7 +386,7 @@ int main(
puts( "open /tmp/bha in read only mode -- OK" );
fd = open( "/tmp/bha", O_CREAT | O_RDONLY, S_IRWXU|S_IRWXG|S_IRWXO );
rtems_test_assert( fd != -1 );
-
+
puts( "attempt to read from /tmp/bha - expect EBADF" );
status = write( fd, buffer, 10 );
rtems_test_assert( status == -1 );
@@ -398,7 +397,7 @@ int main(
status |= unlink( "/tmp/bha" );
rtems_test_assert( status == 0 );
- /*
+ /*
* Read/write from an unopened filedes
*/
puts( "attempt to read from an unopened filedes - expect EBADF" );