diff options
author | kientzle <kientzle@FreeBSD.org> | 2007-05-29 01:00:21 +0000 |
---|---|---|
committer | kientzle <kientzle@FreeBSD.org> | 2007-05-29 01:00:21 +0000 |
commit | 013be331bc10706807599a452a143f4744398e9f (patch) | |
tree | 793787ab8615d768ba51341dfd934a5fb3039728 /lib/libarchive/test/test_read_format_isorr_bz2.c | |
parent | c611006e893ac2bf962cabe02743954e3b3c3314 (diff) | |
download | FreeBSD-src-013be331bc10706807599a452a143f4744398e9f.zip FreeBSD-src-013be331bc10706807599a452a143f4744398e9f.tar.gz |
libarchive 2.2.3
* "compression_program" support uses an external program
* Portability: no longer uses "struct stat" as a primary
data interchange structure internally
* Part of the above: refactor archive_entry to separate
out copy_stat() and stat() functions
* More complete tests for archive_entry
* Finish archive_entry_clone()
* Isolate major()/minor()/makedev() in archive_entry; remove
these from everywhere else.
* Bug fix: properly handle decompression look-ahead at end-of-data
* Bug fixes to 'ar' support
* Fix memory leak in ZIP reader
* Portability: better timegm() emulation in iso9660 reader
* New write_disk flags to suppress auto dir creation and not
overwrite newer files (for future cpio front-end)
* Simplify trailing-'/' fixup when writing tar and pax
* Test enhancements: fix various compiler warnings, improve
portability, add lots of new tests.
* Documentation: document new functions, first draft of
libarchive_internals.3
MFC after: 14 days
Thanks to: Joerg Sonnenberger (compression_program)
Thanks to: Kai Wang (ar)
Thanks to: Colin Percival (many small fixes)
Thanks to: Many others who sent me various patches and problem reports.
Diffstat (limited to 'lib/libarchive/test/test_read_format_isorr_bz2.c')
-rw-r--r-- | lib/libarchive/test/test_read_format_isorr_bz2.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/lib/libarchive/test/test_read_format_isorr_bz2.c b/lib/libarchive/test/test_read_format_isorr_bz2.c index 3a7c56d..a0859f9 100644 --- a/lib/libarchive/test/test_read_format_isorr_bz2.c +++ b/lib/libarchive/test/test_read_format_isorr_bz2.c @@ -102,18 +102,18 @@ DEFINE_TEST(test_read_format_isorr_bz2) /* First entry is '.' root directory. */ assert(0 == archive_read_next_header(a, &ae)); - assert(0 == strcmp(".", archive_entry_pathname(ae))); + assertEqualString(".", archive_entry_pathname(ae)); assert(S_ISDIR(archive_entry_stat(ae)->st_mode)); - assert(2048 == archive_entry_size(ae)); - assert(1 == archive_entry_mtime(ae)); - assert(0 == archive_entry_mtime_nsec(ae)); - assert(1 == archive_entry_ctime(ae)); - assert(0 == archive_entry_stat(ae)->st_nlink); - assert(0 == archive_entry_uid(ae)); + assertEqualInt(2048, archive_entry_size(ae)); + assertEqualInt(1, archive_entry_mtime(ae)); + assertEqualInt(0, archive_entry_mtime_nsec(ae)); + assertEqualInt(1, archive_entry_ctime(ae)); + assertEqualInt(0, archive_entry_stat(ae)->st_nlink); + assertEqualInt(0, archive_entry_uid(ae)); /* A directory. */ assert(0 == archive_read_next_header(a, &ae)); - assert(0 == strcmp("dir", archive_entry_pathname(ae))); + assertEqualString("dir", archive_entry_pathname(ae)); assert(S_ISDIR(archive_entry_stat(ae)->st_mode)); assert(2048 == archive_entry_size(ae)); assert(1 == archive_entry_mtime(ae)); @@ -124,7 +124,7 @@ DEFINE_TEST(test_read_format_isorr_bz2) /* A regular file. */ assert(0 == archive_read_next_header(a, &ae)); - assert(0 == strcmp("file", archive_entry_pathname(ae))); + assertEqualString("file", archive_entry_pathname(ae)); assert(S_ISREG(archive_entry_stat(ae)->st_mode)); assert(6 == archive_entry_size(ae)); assert(0 == archive_read_data_block(a, &p, &size, &offset)); @@ -139,9 +139,9 @@ DEFINE_TEST(test_read_format_isorr_bz2) /* A hardlink to the regular file. */ assert(0 == archive_read_next_header(a, &ae)); - assert(0 == strcmp("hardlink", archive_entry_pathname(ae))); + assertEqualString("hardlink", archive_entry_pathname(ae)); assert(S_ISREG(archive_entry_stat(ae)->st_mode)); - assert(0 == strcmp("file", archive_entry_hardlink(ae))); + assertEqualString("file", archive_entry_hardlink(ae)); assert(6 == archive_entry_size(ae)); assert(1 == archive_entry_mtime(ae)); assert(1 == archive_entry_atime(ae)); @@ -151,9 +151,9 @@ DEFINE_TEST(test_read_format_isorr_bz2) /* A symlink to the regular file. */ assert(0 == archive_read_next_header(a, &ae)); - assert(0 == strcmp("symlink", archive_entry_pathname(ae))); + assertEqualString("symlink", archive_entry_pathname(ae)); assert(S_ISLNK(archive_entry_stat(ae)->st_mode)); - assert(0 == strcmp("file", archive_entry_symlink(ae))); + assertEqualString("file", archive_entry_symlink(ae)); assert(0 == archive_entry_size(ae)); assert(-2 == archive_entry_mtime(ae)); assert(-2 == archive_entry_atime(ae)); |