Jacek Caban (@jacek) commented about programs/wscript/tests/run.c:
+ +static void run_cscript_unknown_option_test(void) +{ + char stdout_buf[4096], stderr_buf[4096]; + DWORD exit_code; + + exit_code = run_cscript("//nologo /unknownoption", stdout_buf, sizeof(stdout_buf), + stderr_buf, sizeof(stderr_buf)); + if(exit_code == ~0u) + return; + ok(exit_code == 1, "exit_code = %lu, expected 1\n", exit_code); + /* On Windows, cscript reports "Unknown option" on stdout. On Wine, + * unrecognized options are treated as filenames to allow Unix-style + * paths (/tmp/foo.vbs), so the error will be about the file instead. */ + ok(strstr(stdout_buf, "Unknown option") != NULL || strstr(stdout_buf, "Can not find") != NULL, + "expected error on stdout, got: %s\n", stdout_buf); Aren't those error messages localized on Windows?
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/10518#note_134530