[parted-devel] [PATCH] Improved and separate test for reading
disk labels.
Jim Meyering
jim at meyering.net
Wed Apr 25 19:12:59 UTC 2007
"Debarshi 'Rishi' Ray" <debarshi.ray at gmail.com> wrote:
> I have separated the test for creating and reading disklabels.
> Moreover I have added an extra check to verify that the disk label
> read is of the same type as the one that was created.
>
> Please find attached the patch for this.
It's great to see more unit tests.
Do the existing ones work for you on the trunk?
On a Debian unstable x86_64 system, "make check" on "master" gives this:
make[3]: Entering directory `/f/mirror/parted/a/libparted/tests'
Running suite(s): Disk Label
Backtrace has 7 calls on stack:
7: ./label(ped_assert+0x55) [0x441ca8]
6: ./label(ped_disk_destroy+0x5e) [0x40e6f8]
5: ./label [0x4097c9]
4: ./label(srunner_run_all+0x50c) [0x40ba2c]
3: ./label(main+0x15b) [0x409950]
2: /lib/libc.so.6(__libc_start_main+0xf4) [0x2b9c49f4f314]
1: ./label(free+0xa1) [0x409189]
66%: Checks: 3, Failures: 1, Errors: 0
label.c:48:P:Create:test_create_label:0: Passed
label.c:81:P:Probe:test_probe_label:0: Passed
common.c:16:F:Clone:test_clone_label:0: Exception of type Bug has been raised: Assertion (!disk->update_mode) at disk.c:418 in function ped_disk_destroy() failed.
FAIL: label
More information about the parted-devel
mailing list