Files
apfstests/218.out
T
Eric Sandeen 76f4a7b9fa Test a few very basic defragmentation scenarios.
This test creates some files, runs defrag on them,
and compares the before/after fragmentation as well
as file md5sums and timestamps.

The test currently expects to find e4defrag in
/usr/bin

It should be relatively easy to add more interestingly
fragmented files to the tests, as well as to test
that memory-mapped files aren't touched, etc - 
but this gives us a framework.

V2: remount before checking file contents, and create
common.defrag.

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-08-10 13:10:26 -05:00

20 lines
392 B
Plaintext

QA output created by 218
zero-length file:
Before: 0
After: 0
Sparse file (no blocks):
Before: 0
After: 0
Contiguous file:
Before: 1
After: 1
Write backwards sync, but contiguous - should defrag to 1 extent
Before: 10
After: 1
Write backwards sync leaving holes - defrag should do nothing
Before: 16
After: 16
Write forwards sync leaving holes - defrag should do nothing
Before: 16
After: 16