You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by jo...@apache.org on 2004/04/05 16:39:40 UTC
cvs commit: apr/test testlfs.c
jorton 2004/04/05 07:39:40
Modified: test testlfs.c
Log:
* test/testlfs.c (test_seek): Test APR_END-relative seek; move test
before testappend.
Revision Changes Path
1.4 +6 -1 apr/test/testlfs.c
Index: testlfs.c
===================================================================
RCS file: /home/cvs/apr/test/testlfs.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -w -d -u -r1.3 -r1.4
--- testlfs.c 30 Mar 2004 10:18:43 -0000 1.3
+++ testlfs.c 5 Apr 2004 14:39:40 -0000 1.4
@@ -173,6 +173,11 @@
apr_file_open(&fh, TESTFN, APR_WRITE,
APR_OS_DEFAULT, p));
+ pos = 0;
+ apr_assert_success(tc, "relative seek to end",
+ apr_file_seek(fh, APR_END, &pos));
+ CuAssert(tc, "seek to END gave 8Gb", pos == eightGb);
+
pos = eightGb;
apr_assert_success(tc, "seek to 8Gb", apr_file_seek(fh, APR_SET, &pos));
CuAssert(tc, "seek gave 8Gb offset", pos == eightGb);
@@ -264,8 +269,8 @@
SUITE_ADD_TEST(suite, test_reopen);
SUITE_ADD_TEST(suite, test_stat);
SUITE_ADD_TEST(suite, test_readdir);
- SUITE_ADD_TEST(suite, test_append);
SUITE_ADD_TEST(suite, test_seek);
+ SUITE_ADD_TEST(suite, test_append);
SUITE_ADD_TEST(suite, test_write);
#if APR_HAS_MMAP
SUITE_ADD_TEST(suite, test_mmap);