Files
mars-dosutils/test
Mario Fetka 4a952b4c4c dosutils: align Novell-compatible tests and stage NCOPY work
Update the DOS utilities and test suite with the current Novell comparison
state.

Validated/updated tool behavior:
- improve CREATOR output by showing Novell-style attribute and rights masks
- extend FLAGDIR handling with old NCP22 directory attribute read/write
  fallback paths
- expand NDIR Novell-style formatting, filtering, /SUB handling, date output,
  DI/RI attribute display and richer metadata collection
- adjust REVOKE output/grammar, recursive /SUBDIRECTORIES behavior and trustee
  update/delete paths to better match Novell tools
- adjust SLIST header/output behavior for logged-in and logged-out cases
- update README status to reflect the currently green/tested tools

Test-suite changes:
- add/refresh Novell comparison tests for CREATOR, NDIR, REVOKE and SLIST
- update NCOPY tests and collection scripts for the current investigation state
- refresh per-tool README files and top-level test documentation
- keep MAP documented as still separately open

NCOPY:
- add the current NCOPY implementation and experimental NCP74/server-side-copy
  scaffolding
- build ncopy.c so it stays compile-tested
- keep NCOPY disabled in the NET multicall dispatch for now because the
  server-side-copy/open-handle path is still unsafe and needs further analysis

Build:
- include ncopy.c in the DOS utility build
- drop the temporary MARS_DOSUTILS_VERSION define wiring from CMake
2026-05-29 07:40:04 +02:00
..

DOS utility regression tests

This directory contains DOS-side comparison and regression tests for the mars-dosutils tools. The tests are meant for maintainer use against a MARS-NWE SYS: tree that also contains the original Novell tools in SYS:NPUBLIC and SYS:NLOGIN.

Most tests compare captured Novell output with the current public implementation byte-for-byte. Some tests also switch to a normal user and read back effective rights, because matching command output alone is not enough for trustee tools.

Output naming convention

The generated result trees use these names consistently:

OUT       Novell reference output from SYS:NPUBLIC or SYS:NLOGIN
PUBOUT    current implementation output from SYS:PUBLIC or SYS:LOGIN
COMPARE.LOG

UNOV      Novell readback while logged in as NOPASSUSER
UPUB      public readback while logged in as NOPASSUSER
UCOMP.LOG

LOUT      Novell output while logged out, usually from SYS:NLOGIN copy
LPUBOUT   public output while logged out, usually from SYS:LOGIN copy
LCOMP.LOG

Not every test has every directory. For example, SLIST has LOUT/LPUBOUT, while trustee tools usually have UNOV/UPUB.

User switching and local helpers

Tests that must survive a LOGOUT use DLYSTRT.EXE and a local helper directory on C:. This is required because logging out removes F: and normal network mappings. The common pattern is:

  1. run the main *STA.BAT as SUPERVISOR from F:,
  2. copy the helper *C.BAT, DLYSTRT.EXE, and required tools to C:\*TMP,
  3. queue the helper with DLYSTRT,
  4. let the helper log out, perform the user or logged-out checks, log back in,
  5. queue F:\*STA.BAT PART2,
  6. compare and package the captured files.

For automatic re-login, set the Supervisor password before starting the test:

SET LGNTPWD=your-supervisor-password

LGNTPWD is used only by maintainer tests and should not be committed to any script or log.

Test index

Directory Main script Current purpose/status
creator/ CIXSTA.BAT CREATOR metadata/xattr test plus optional NOPASSUSER readback.
flag/ FLGTSTA.BAT NPUBLIC\FLAG vs PUBLIC\FLAG, including user-context readback.
flagdir/ FDGTSTA.BAT NPUBLIC\FLAGDIR vs PUBLIC\FLAGDIR, including user-context readback.
grant/ GRNTSTA.BAT NPUBLIC\GRANT vs PUBLIC\GRANT, rights matrix and NOPASSUSER readback.
login/ LGNTSTA.BAT Maintainer baseline for Novell LOGIN/LOGOUT/MAP flow.
logout/ see login/ LOGOUT is covered by the LOGIN baseline flow.
map/ MAPTSTA.BAT Novell MAP baseline and root/non-root mapping semantics; full PUBLIC comparison still pending.
ndir/ NDIRTSTA.BAT NPUBLIC\NDIR vs PUBLIC\NDIR, matrix, filters, /SUB, /RIGHTS, user readback.
remove/ RMVSTA.BAT NPUBLIC\REMOVE vs PUBLIC\REMOVE, matrix and NOPASSUSER readback.
revoke/ RVKSTA.BAT NPUBLIC\REVOKE vs PUBLIC\REVOKE, matrix and NOPASSUSER readback.
rights/ RGHTSTA.BAT NPUBLIC\RIGHTS vs PUBLIC\RIGHTS, direct effective-rights cases.
slist/ SLSTSTA.BAT NPUBLIC\SLIST vs PUBLIC\SLIST while logged in, plus NLOGIN\SLIST vs LOGIN\SLIST while logged out.
whoami/ WHOSTA.BAT NPUBLIC\WHOAMI vs PUBLIC\WHOAMI.
rightsuser/ varies Additional user-rights experiments.
renmove/ varies Rename/move experiments.
ncopy/ varies NCOPY experiments.
filer/ varies FILER-related notes/experiments.

Packaging

Most test directories have a matching *ZIP.BAT that packages the result tree under SYS:. After that, include a recent server log from Linux, for example:

sudo ./mars_packtest_v3.sh slststa 5 mario

Use the test-specific README for exact ZIP names and any Linux-side collector steps.

Current high-level status

Recently green comparison tests:

CREATOR readback
FLAG
FLAGDIR
GRANT
NDIR
REMOVE
REVOKE
RIGHTS
SLIST logged-in and logged-out
WHOAMI

LOGIN/LOGOUT are covered by the maintainer baseline. MAP still needs a full PUBLIC\MAP vs Novell comparison beyond the current baseline/semantics test.