Add profile-specific DOS client setup helpers and authenticated downloads
This commit is contained in:
@@ -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'));
|
||||
}
|
||||
|
||||
@@ -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 ]]
|
||||
|
||||
Reference in New Issue
Block a user