Commit 7408a3a7 authored by Qian Hong's avatar Qian Hong Committed by Alexandre Julliard

quartz/tests: Add NULL pointer tests for IGraphBuilder.

parent 682291fb
......@@ -180,6 +180,9 @@ static void test_graph_builder(void)
ok(hr == S_OK, "CoCreateInstance failed with %x\n", hr);
ok(pF != NULL, "pF is NULL\n");
hr = IGraphBuilder_AddFilter(pgraph, NULL, testFilterW);
ok(hr == E_POINTER, "IGraphBuilder_AddFilter returned %x\n", hr);
/* add the two filters to the graph */
hr = IGraphBuilder_AddFilter(pgraph, pF, testFilterW);
ok(hr == S_OK, "failed to add pF to the graph: %x\n", hr);
......@@ -204,6 +207,16 @@ static void test_graph_builder(void)
hr = IGraphBuilder_FindFilterByName(pgraph, testFilterW, NULL);
ok(hr == E_POINTER, "IGraphBuilder_FindFilterByName returned %x\n", hr);
hr = IGraphBuilder_Connect(pgraph, NULL, pIn);
ok(hr == E_POINTER, "IGraphBuilder_Connect returned %x\n", hr);
hr = IGraphBuilder_Connect(pgraph, pIn, NULL);
ok(hr == E_POINTER, "IGraphBuilder_Connect returned %x\n", hr);
hr = IGraphBuilder_Connect(pgraph, pIn, pIn);
todo_wine
ok(hr == VFW_E_CANNOT_CONNECT, "IGraphBuilder_Connect returned %x\n", hr);
if (pIn) IPin_Release(pIn);
if (pEnum) IEnumPins_Release(pEnum);
if (pF) IBaseFilter_Release(pF);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment