Add profile-specific DOS client setup helpers and authenticated downloads

This commit is contained in:
2026-11-28 11:57:06 +00:00
parent b6abb353c8
commit 15fde09e9e
33 changed files with 158 additions and 8 deletions

View File

@@ -19,6 +19,7 @@ const fs=require('fs'),path=require('path'),assert=require('assert');
await page.evaluate(()=>show(2));
for(const os of ['ms5','ms6','ms7','pc','dr','free'])for(const client of ['netx','vlm','client32']){
await page.locator('#dosVersion').selectOption(os);await page.locator('#dosClient').selectOption(client);
assert.equal(await page.locator('#dosInstaller').getAttribute('href'),'/dos/'+os+'-'+client+'.zip');
const info=await page.locator('#dosProfileInfo').textContent();assert(info.includes('noch nicht implementiert'));assert(info.includes('noch nicht mit einem echten Client getestet'));
if(client==='client32')assert(info.includes('8086/286'));
}

View File

@@ -18,7 +18,8 @@ cat > "$cfg" <<'CONF'
99 PRESERVE
CONF
chmod 600 "$cfg"
mkdir -p "$d/www/drivers"
mkdir -p "$d/www/drivers" "$d/www/dos"
printf "DOS helper fixture" > "$d/www/dos/ms5-netx.zip"
cp websetup/* "$d/www/"
printf 'ZIP fixture bytes' > "$d/www/drivers/WIN95.zip"
printf '{"platforms":["WIN95"],"map":"test"}' > "$d/www/drivers/enabled.json"
@@ -39,6 +40,9 @@ post api/password '{"current":"admin","new":"NativeTestPassword123","repeat":"Na
[[ $(status -b "$d/old-cookie" "$base/api/state") == 401 ]]
post api/login '{"user":"admin","password":"NativeTestPassword123"}' | jq -e .ok >/dev/null
s=$(get api/state); jq -e '(.defaultPassword|not) and (.text|contains("99 PRESERVE"))' <<<"$s" >/dev/null
get dos/ms5-netx.zip > "$d/dos.zip"
cmp "$d/dos.zip" "$d/www/dos/ms5-netx.zip"
[[ $(status -b "$d/cookie" "$base/dos/unknown-netx.zip") == 404 ]]
get drivers/WIN95.zip > "$d/download.zip"
cmp "$d/download.zip" "$d/www/drivers/WIN95.zip"
[[ $(status -b "$d/cookie" "$base/drivers/WINXP.zip") == 404 ]]