From f3e3e9a5c702c5b2254f6246fd466e309e60d6ba Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Mon, 19 Oct 2009 18:55:06 +0200 Subject: [PATCH] tests: hook up new GPT-crc-corrupting script * tests/Makefile.am (TESTS): Add t0280-gpt-corrupt.sh. * libparted/labels/gpt.c (gpt_read): Change diagnostic to say that the PTE CRC mismatch is in the primary table. * tests/t0280-gpt-corrupt.sh: Tweak diagnostic to match what the code now prints. --- libparted/labels/gpt.c | 2 +- tests/Makefile.am | 1 + tests/t0280-gpt-corrupt.sh | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/libparted/labels/gpt.c b/libparted/labels/gpt.c index daac677..5131ebe 100644 --- a/libparted/labels/gpt.c +++ b/libparted/labels/gpt.c @@ -940,7 +940,7 @@ gpt_read (PedDisk *disk) ped_exception_throw (PED_EXCEPTION_ERROR, PED_EXCEPTION_CANCEL, - _("partition table array (FIXME:which?) CRC mismatch")); + _("primary partition table array CRC mismatch")); goto error_free_ptes; } diff --git a/tests/Makefile.am b/tests/Makefile.am index 42badff..0d393a6 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -7,6 +7,7 @@ TESTS = \ t0202-gpt-pmbr.sh \ t0220-gpt-msftres.sh \ t0250-gpt.sh \ + t0280-gpt-corrupt.sh \ t0300-dos-on-gpt.sh \ t0400-loop-clobber-infloop.sh \ t1000-mkpartfs.sh \ diff --git a/tests/t0280-gpt-corrupt.sh b/tests/t0280-gpt-corrupt.sh index 89ab818..3addcc2 100755 --- a/tests/t0280-gpt-corrupt.sh +++ b/tests/t0280-gpt-corrupt.sh @@ -89,7 +89,7 @@ test_expect_success \ test_expect_success \ 'check for expected diagnostic' \ - 'echo "Error: partition table array CRC mismatch" > exp && + 'echo "Error: primary partition table array CRC mismatch" > exp && compare exp err' test_done -- 2.11.0