test code v1
This commit is contained in:
@@ -0,0 +1,48 @@
|
||||
# Test Case: MicroLZMA Compression
|
||||
|
||||
**Test ID**: TC109-microlzma
|
||||
|
||||
**G5 fixture contract**: Use [G5-MANUAL-SETUP.md](G5-MANUAL-SETUP.md).
|
||||
Its generated paths, source comparisons, structured corruption offsets, and
|
||||
cleanup rules supersede placeholder examples in this file.
|
||||
**Category**: Compression
|
||||
**Priority**: Medium
|
||||
**Regression**: None
|
||||
|
||||
## Objective
|
||||
Verify MicroLZMA compressed data path works correctly.
|
||||
|
||||
## Preconditions
|
||||
- `images/microlzma-edge.erofs`, generated with LZMA level 6
|
||||
- Actual 1-byte, 4096-byte, and 16384-byte source files
|
||||
- The 16384-byte inode must be compressed full-index with algorithm 1. The
|
||||
smaller files are valid flat controls and must not be claimed as compressed.
|
||||
- FreeBSD 13.0+ with liblzma
|
||||
|
||||
## Test Steps
|
||||
1. Create image with MicroLZMA-compressed small files
|
||||
2. Attach and mount: `unit=$(mdconfig -a -t vnode -f test.img); mount -t erofs -o ro /dev/${unit} /mnt`
|
||||
3. Read all small files
|
||||
4. Verify content integrity
|
||||
5. Test edge cases (1-byte, 16KB boundary)
|
||||
|
||||
## Expected Results
|
||||
- All files read correctly and match their source bytes
|
||||
- MicroLZMA format handled properly
|
||||
- Good compression for small files
|
||||
- No format detection errors
|
||||
|
||||
## Verification Method
|
||||
- Checksums match for all files
|
||||
- Verify LZMA format detection in dmesg
|
||||
- Test files at boundaries: 1B, 4KB, 16KB
|
||||
- No decompression failures
|
||||
|
||||
## Cleanup
|
||||
```sh
|
||||
umount /mnt
|
||||
mdconfig -d -u "${unit#md}"
|
||||
```
|
||||
|
||||
## Notes
|
||||
Tests feature 60: MicroLZMA variant of LZMA compression.
|
||||
Reference in New Issue
Block a user