Hi Alistair,
Alistair Leslie-Hughes wrote:
The problem is hres is DISP_E_EXCEPTION, whereas I'm expecting E_INVALIDARG (Tested on windows). It appears in ITypeInfo_fnInvoke, if an error is returned from the function call, the result is changed to return DISP_E_EXCEPTION (~ line 6320).
Should ITypeInfo_fnInvoke propergate the returned HRESULT instead of changing it?
Native mshtml.dll doesn't use typelib for IDispatch calls, so it may handle errors differently. It's not something that we want to test in DOM tests, so changing test to check for FAILED(hres) should be fine. Otherwise you could call interface functions directly in tests, without using IDispatch.
Jacek