Files
mars-nwe/tests/salvage

Salvage smoke tests

This directory is reserved for NetWare salvage/deleted-entry coverage. The backend is intentionally shared by NCP salvage calls and the later AFP 0x13 Get Macintosh Info On Deleted Files adapter; AFP must not grow a parallel local deleted-file scanner.

The first executable coverage is layout-only. It records the repository contract before src/nwsalvage.c exists:

  • deleted file payloads live below the recycle repository,
  • per-object JSON metadata lives below the salvage repository,
  • JSON metadata preserves mars_nwe xattr-backed NetWare/AFP fields from nwarchive and nwatalk,
  • there is no large per-directory index file,
  • stale JSON metadata is detectable when the matching recycle payload is gone.

Default repository names come from the nwserv.conf/nw.ini template options:

48 1
49 .recycle .salvage

Expected layout for a deleted SYS:PUBLIC/PMDFLTS.INI owned by SUPERVISOR. The sidecar JSON must carry the server-only metadata needed for exact recover, including NetWare archive/fileinfo xattrs and AFP FinderInfo/entry-id/attribute xattrs:

SYS/.recycle/SUPERVISOR/PUBLIC/PMDFLTS.INI
SYS/.salvage/SUPERVISOR/PUBLIC/PMDFLTS.INI.json

Future runtime tests should add direct coverage for:

  • NCP 0x2222 / 22 / 27 Scan Salvageable Files (old),
  • NCP 0x2222 / 87 / 16 Scan Salvageable Files,
  • NCP 0x2222 / 87 / 17 Recover Salvageable File,
  • NCP 0x2222 / 87 / 18 Purge Salvageable File,
  • AFP 0x13 as a thin adapter over the shared salvage backend.