summaryrefslogtreecommitdiffstats
path: root/lib/libarchive/test/test_read_format_isorr_bz2.c
diff options
context:
space:
mode:
authorkientzle <kientzle@FreeBSD.org>2009-04-27 19:23:53 +0000
committerkientzle <kientzle@FreeBSD.org>2009-04-27 19:23:53 +0000
commitafb10f1ced1d396df35bb5222c382ab41b2018ac (patch)
tree39b777a8cec63f3e4fb152df0d618386c70c5dc4 /lib/libarchive/test/test_read_format_isorr_bz2.c
parentce69be627f4413073861bd259dba2aaf61a7e7ca (diff)
downloadFreeBSD-src-afb10f1ced1d396df35bb5222c382ab41b2018ac.zip
FreeBSD-src-afb10f1ced1d396df35bb5222c382ab41b2018ac.tar.gz
Merge r1034 from libarchive.googlecode.com:
Put a much larger file on the reference ISO for this test.
Diffstat (limited to 'lib/libarchive/test/test_read_format_isorr_bz2.c')
-rw-r--r--lib/libarchive/test/test_read_format_isorr_bz2.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/libarchive/test/test_read_format_isorr_bz2.c b/lib/libarchive/test/test_read_format_isorr_bz2.c
index f00bbbe..cd53c7c 100644
--- a/lib/libarchive/test/test_read_format_isorr_bz2.c
+++ b/lib/libarchive/test/test_read_format_isorr_bz2.c
@@ -26,13 +26,14 @@
__FBSDID("$FreeBSD$");
/*
-Execute the following to rebuild the data for this program:
+Execute the following command to rebuild the data for this program:
tail -n +32 test_read_format_isorr_bz2.c | /bin/sh
rm -rf /tmp/iso
mkdir /tmp/iso
mkdir /tmp/iso/dir
echo "hello" >/tmp/iso/file
+dd if=/dev/zero bs=1 count=12345678 >>/tmp/iso/file
ln /tmp/iso/file /tmp/iso/hardlink
(cd /tmp/iso; ln -s file symlink)
TZ=utc touch -afhm -t 197001020000.01 /tmp/iso /tmp/iso/file /tmp/iso/dir
@@ -95,11 +96,10 @@ DEFINE_TEST(test_read_format_isorr_bz2)
assertEqualInt(0, archive_read_next_header(a, &ae));
assertEqualString("file", archive_entry_pathname(ae));
assert(S_ISREG(archive_entry_stat(ae)->st_mode));
- assertEqualInt(6, archive_entry_size(ae));
+ assertEqualInt(12345684, archive_entry_size(ae));
assertEqualInt(0, archive_read_data_block(a, &p, &size, &offset));
- assertEqualInt(6, (int)size);
assertEqualInt(0, offset);
- assertEqualInt(0, memcmp(p, "hello\n", 6));
+ assertEqualMem(p, "hello\n", 6);
assertEqualInt(86401, archive_entry_mtime(ae));
assertEqualInt(86401, archive_entry_atime(ae));
assertEqualInt(2, archive_entry_stat(ae)->st_nlink);
@@ -111,7 +111,7 @@ DEFINE_TEST(test_read_format_isorr_bz2)
assertEqualString("hardlink", archive_entry_pathname(ae));
assert(S_ISREG(archive_entry_stat(ae)->st_mode));
assertEqualString("file", archive_entry_hardlink(ae));
- assertEqualInt(6, archive_entry_size(ae));
+ assertEqualInt(12345684, archive_entry_size(ae));
assertEqualInt(86401, archive_entry_mtime(ae));
assertEqualInt(86401, archive_entry_atime(ae));
assertEqualInt(2, archive_entry_stat(ae)->st_nlink);
OpenPOWER on IntegriCloud