From: Anders Kjersem andersdev@proton.me
--- programs/wscript/host.c | 1 + programs/wscript/tests/run.js | 5 +++++ 2 files changed, 6 insertions(+)
diff --git a/programs/wscript/host.c b/programs/wscript/host.c index 6bec73062e2..2e6ed964f63 100644 --- a/programs/wscript/host.c +++ b/programs/wscript/host.c @@ -395,6 +395,7 @@ static HRESULT WINAPI Host_DisconnectObject(IHost *iface, IDispatch *Object)
static HRESULT WINAPI Host_Sleep(IHost *iface, LONG Time) { + TRACE("(%ld)\n", Time); if (Time < 0) return E_INVALIDARG; Sleep(Time); diff --git a/programs/wscript/tests/run.js b/programs/wscript/tests/run.js index a812a85c9e0..0f8deb64c3b 100644 --- a/programs/wscript/tests/run.js +++ b/programs/wscript/tests/run.js @@ -48,6 +48,11 @@ ok(WScript.Interactive === false, "WScript.Interactive = " + WScript.Interactive WScript.Interactive = true; ok(WScript.Interactive === true, "WScript.Interactive = " + WScript.Interactive); ok(WScript.Application === WScript, "WScript.Application = " + WScript.Application); +ok(WScript.Sleep(0), "Sleep(0)"); +try { + WScript.Sleep(-1); + ok(false, "expected exception"); +}catch(e) {}
var obj = WScript.CreateObject("Wine.Test"); obj.ok(true, "Broken WScript.CreateObject object?");