tests/archive: comments: specs only

This commit is contained in:
4DBug committed 2026-11-01 01:49:50 -05:00
1 parent 54f53a35f6
commit 96602286f8
33 files changed
+34 -226

No files matched your search

+1 -6
View File
@@ -1,7 +1,4 @@
-- archive/d64 tests: D64 / D71 / D81 images made by VICE's c1541 (PRG / SEQ / USR, multi-sector, a deleted file, an
-- error-info block, 30 files over several directory sectors) list the files c1541 reads back (names, sizes, types,
-- data CRCs), disk name and id; our D64 / D71 / D81 output is read by c1541 (fixture step) and round-trips; PETSCII
-- names; errors; the fuzz pass. Fixtures: tools/fixtures/d64.py.
-- archive/d64 tests against VICE's c1541 (tools/fixtures/d64.py).
local T = require("@tests/T")
local F = require("@rosetta")
local D64 = require("@rosetta/archive/d64")
@@ -43,14 +40,12 @@ for _, v in { "d64", "d71", "d81" } do
t:eq(a.meta.disk, "round trip", v .. ": disk name")
end
end
-- PETSCII names: lower / upper case and other bytes survive a round trip
local a = D64.new()
a:add("Mixed Case 1", "x")
a:add("\u{E0D3}hift", "y")
local back = D64.decode(Bytes.reader(a:write() :: buffer)) :: any
t:check(back._byName["Mixed Case 1"] and back._byName["\u{E0D3}hift"] == nil and back._byName["Shift"], "petscii names")
-- errors
local function code(b: buffer): string?
local _, e = D64.decode(Bytes.reader(b))
return e and e.code