jscript: Added accessing not existing property on IDispatchEx tests.

This commit is contained in:
Jacek Caban 2014-06-12 10:44:03 +02:00 committed by Alexandre Julliard
parent 84bf97087d
commit cbe63d977c
1 changed files with 10 additions and 0 deletions

View File

@ -101,6 +101,7 @@ DEFINE_EXPECT(testobj_withprop_i);
DEFINE_EXPECT(testobj_noprop_d);
DEFINE_EXPECT(testobj_onlydispid_d);
DEFINE_EXPECT(testobj_onlydispid_i);
DEFINE_EXPECT(testobj_notexists_d);
DEFINE_EXPECT(GetItemInfo_testVal);
DEFINE_EXPECT(ActiveScriptSite_OnScriptError);
DEFINE_EXPECT(invoke_func);
@ -327,6 +328,11 @@ static HRESULT WINAPI testObj_GetDispID(IDispatchEx *iface, BSTR bstrName, DWORD
*pid = DISPID_TESTOBJ_ONLYDISPID;
return S_OK;
}
if(!strcmp_wa(bstrName, "notExists")) {
CHECK_EXPECT(testobj_notexists_d);
test_grfdex(grfdex, fdexNameCaseSensitive);
return DISP_E_UNKNOWNNAME;
}
ok(0, "unexpected name %s\n", wine_dbgstr_w(bstrName));
return E_NOTIMPL;
@ -2055,6 +2061,10 @@ static BOOL run_tests(void)
parse_script_a("var notExists; notExists = 1;");
CHECK_CALLED(global_notexists_d);
SET_EXPECT(testobj_notexists_d);
parse_script_a("testObj.notExists;");
CHECK_CALLED(testobj_notexists_d);
parse_script_a("function f() { var testPropGet; }");
parse_script_a("(function () { var testPropGet; })();");
parse_script_a("(function () { eval('var testPropGet;'); })();");