gameux/tests: Add creating test for IGameExplorer
Mariusz Pluciński
vshader at gmail.com
Mon Jun 7 15:47:46 CDT 2010
---
configure.ac | 1 +
dlls/gameux/tests/Makefile.in | 12 ++++++++
dlls/gameux/tests/gameexplorer.c | 59 ++++++++++++++++++++++++++++++++++++++
3 files changed, 72 insertions(+), 0 deletions(-)
create mode 100644 dlls/gameux/tests/Makefile.in
create mode 100644 dlls/gameux/tests/gameexplorer.c
diff --git a/configure.ac b/configure.ac
index 161a0cb..d918e4e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2352,6 +2352,7 @@ WINE_CONFIG_DLL(fusion)
WINE_CONFIG_TEST(dlls/fusion/tests)
WINE_CONFIG_DLL(fwpuclnt)
WINE_CONFIG_DLL(gameux)
+WINE_CONFIG_TEST(dlls/gameux/tests)
WINE_CONFIG_DLL(gdi.exe16,enable_win16)
WINE_CONFIG_DLL(gdi32,,[gdi32])
WINE_CONFIG_TEST(dlls/gdi32/tests)
diff --git a/dlls/gameux/tests/Makefile.in b/dlls/gameux/tests/Makefile.in
new file mode 100644
index 0000000..c31fb24
--- /dev/null
+++ b/dlls/gameux/tests/Makefile.in
@@ -0,0 +1,12 @@
+TOPSRCDIR = @top_srcdir@
+TOPOBJDIR = ../../..
+SRCDIR = @srcdir@
+VPATH = @srcdir@
+TESTDLL = gameux.dll
+IMPORTS = oleaut32 ole32 user32 kernel32
+
+C_SRCS = \
+ gameexplorer.c
+
+
+ at MAKE_TEST_RULES@
diff --git a/dlls/gameux/tests/gameexplorer.c b/dlls/gameux/tests/gameexplorer.c
new file mode 100644
index 0000000..b0016d9
--- /dev/null
+++ b/dlls/gameux/tests/gameexplorer.c
@@ -0,0 +1,59 @@
+/*
+ * IGameExplorer tests
+ *
+ * Copyright (C) 2010 Mariusz PluciÅski
+ *
+ * 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
+
+#include "initguid.h"
+
+#include "windows.h"
+#include "ole2.h"
+#include "objsafe.h"
+#include "objbase.h"
+#include "gameux.h"
+
+#include "wine/test.h"
+
+
+static void test_create( void )
+{
+ HRESULT hr;
+
+ IGameExplorer* ge = NULL;
+
+ /* interface available up from Vista */
+ hr = CoCreateInstance( &CLSID_GameExplorer, NULL, CLSCTX_INPROC_SERVER, &IID_IGameExplorer, (LPVOID*)&ge);
+ ok(ge && hr == S_OK, "IGameExplorer creating failed (result false)\n");
+ if(ge)
+ {
+ IGameExplorer_Release(ge);
+ }
+}
+
+START_TEST(gameexplorer)
+{
+ HRESULT r;
+
+ r = CoInitialize( NULL );
+ ok( r == S_OK, "failed to init COM\n");
+
+ test_create();
+
+ CoUninitialize();
+}
--
1.7.1.1
--------------010005040808030309030903--
More information about the wine-patches
mailing list