Commit 41f456f3 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

oleaut32/tests: Add a test for VT_NULL input for VarFormatDateTime().

parent 0a5932e1
......@@ -659,6 +659,19 @@ static void test_VarFormatCurrency(void)
VariantClear(&in);
}
static void test_VarFormatDateTime(void)
{
VARIANT in;
HRESULT hr;
BSTR str;
V_VT(&in) = VT_NULL;
str = (void *)0xdeadbeef;
hr = VarFormatDateTime(&in, 0, 0, &str);
ok(hr == S_OK, "Unexpected hr %#lx.\n", hr);
ok(!str, "Unexpected out string %p.\n", str);
}
START_TEST(varformat)
{
test_VarFormatNumber();
......@@ -667,4 +680,5 @@ START_TEST(varformat)
test_VarFormatFromTokens();
test_GetAltMonthNames();
test_VarFormatCurrency();
test_VarFormatDateTime();
}
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