
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com> Signed-off-by: Jacek Caban <jacek@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
59 lines
1.6 KiB
C
59 lines
1.6 KiB
C
/*
|
|
* Copyright 2016 Nikolay Sivov for CodeWeavers
|
|
*
|
|
* This library is free software; you can redistribute it and/or
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
* License as published by the Free Software Foundation; either
|
|
* version 2.1 of the License, or (at your option) any later version.
|
|
*
|
|
* This library is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
* Lesser General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
* License along with this library; if not, write to the Free Software
|
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
*/
|
|
|
|
#define COBJMACROS
|
|
#define CONST_VTABLE
|
|
|
|
#include <initguid.h>
|
|
#include <ole2.h>
|
|
|
|
#include "msscript.h"
|
|
#include "wine/test.h"
|
|
|
|
static void test_oleobject(void)
|
|
{
|
|
IOleObject *obj;
|
|
HRESULT hr;
|
|
|
|
hr = CoCreateInstance(&CLSID_ScriptControl, NULL, CLSCTX_INPROC_SERVER|CLSCTX_INPROC_HANDLER,
|
|
&IID_IOleObject, (void**)&obj);
|
|
ok(hr == S_OK, "got 0x%08x\n", hr);
|
|
|
|
IOleObject_Release(obj);
|
|
}
|
|
|
|
START_TEST(msscript)
|
|
{
|
|
IUnknown *unk;
|
|
HRESULT hr;
|
|
|
|
CoInitialize(NULL);
|
|
|
|
hr = CoCreateInstance(&CLSID_ScriptControl, NULL, CLSCTX_INPROC_SERVER|CLSCTX_INPROC_HANDLER,
|
|
&IID_IUnknown, (void**)&unk);
|
|
if (FAILED(hr)) {
|
|
win_skip("Could not create ScriptControl object: %08x\n", hr);
|
|
return;
|
|
}
|
|
IUnknown_Release(unk);
|
|
|
|
test_oleobject();
|
|
|
|
CoUninitialize();
|
|
}
|