test code v1
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
# Test Case: FLAT_INLINE Tailpacking
|
||||
|
||||
**Test ID**: TC033-tailpacking-normal
|
||||
|
||||
## Objective
|
||||
|
||||
Verify a 5000-byte file reads exactly across its full data block and 904-byte
|
||||
inline tail boundary.
|
||||
|
||||
## Fixture
|
||||
|
||||
Use `images/inline.erofs` and `source/inline/tailpacked.dat`. Evidence asserts
|
||||
layout 2 and size 5000.
|
||||
|
||||
## Procedure
|
||||
|
||||
```sh
|
||||
stat -f 'size=%z blocks=%b' "$mnt/tailpacked.dat"
|
||||
cmp /tmp/repo22-g1/source/inline/tailpacked.dat "$mnt/tailpacked.dat"
|
||||
sha256 /tmp/repo22-g1/source/inline/tailpacked.dat "$mnt/tailpacked.dat"
|
||||
./read_probe pread "$mnt/tailpacked.dat" 4080 64 /tmp/tc033-mounted-range
|
||||
dd if=/tmp/repo22-g1/source/inline/tailpacked.dat \
|
||||
of=/tmp/tc033-source-range bs=1 skip=4080 count=64 2>/dev/null
|
||||
cmp /tmp/tc033-source-range /tmp/tc033-mounted-range
|
||||
```
|
||||
|
||||
Remove outputs, unmount, and detach.
|
||||
|
||||
## Expected Results
|
||||
|
||||
- Full file and the range crossing logical offset 4096 match the source.
|
||||
- The transition from plain block data to metadata tail is seamless and
|
||||
cleanup succeeds.
|
||||
Reference in New Issue
Block a user