Commit 8ad509ed authored by Alistair Leslie-Hughes's avatar Alistair Leslie-Hughes Committed by Alexandre Julliard

msxml3: Accept NormalizeAttributeValues property.

parent 6634b315
......@@ -73,6 +73,7 @@ static const WCHAR PropValueXSLPatternW[] = {'X','S','L','P','a','t','t','e','r'
static const WCHAR PropertyResolveExternalsW[] = {'R','e','s','o','l','v','e','E','x','t','e','r','n','a','l','s',0};
static const WCHAR PropertyAllowXsltScriptW[] = {'A','l','l','o','w','X','s','l','t','S','c','r','i','p','t',0};
static const WCHAR PropertyAllowDocumentFunctionW[] = {'A','l','l','o','w','D','o','c','u','m','e','n','t','F','u','n','c','t','i','o','n',0};
static const WCHAR PropertyNormalizeAttributeValuesW[] = {'N','o','r','m','a','l','i','z','e','A','t','t','r','i','b','u','t','e','V','a','l','u','e','s',0};
/* Anything that passes the test_get_ownerDocument()
* tests can go here (data shared between all instances).
......@@ -3108,6 +3109,7 @@ static HRESULT WINAPI domdoc_setProperty(
lstrcmpiW(p, PropertyNewParserW) == 0 ||
lstrcmpiW(p, PropertyResolveExternalsW) == 0 ||
lstrcmpiW(p, PropertyAllowXsltScriptW) == 0 ||
lstrcmpiW(p, PropertyNormalizeAttributeValuesW) == 0 ||
lstrcmpiW(p, PropertyAllowDocumentFunctionW) == 0)
{
/* Ignore */
......
......@@ -12792,6 +12792,44 @@ static void test_transformNodeToObject(void)
free_bstrs();
}
static void test_normalize_attribute_values(void)
{
IXMLDOMDocument2 *doc;
VARIANT var;
HRESULT hr;
if (!is_clsid_supported(&CLSID_DOMDocument60, &IID_IXMLDOMDocument2))
{
win_skip("NormalizeAttributeValues is not supported.\n");
return;
}
doc = create_document_version(60, &IID_IXMLDOMDocument2);
V_VT(&var) = VT_I2;
V_I2(&var) = 10;
hr = IXMLDOMDocument2_getProperty(doc, _bstr_("NormalizeAttributeValues"), &var);
todo_wine {
ok(hr == S_OK, "Failed to get property value, hr %#x.\n", hr);
ok(V_VT(&var) == VT_BOOL, "Unexpected property value type, vt %d.\n", V_VT(&var));
ok(V_BOOL(&var) == VARIANT_FALSE, "Unexpected property value.\n");
}
V_VT(&var) = VT_BOOL;
V_BOOL(&var) = VARIANT_TRUE;
hr = IXMLDOMDocument2_setProperty(doc, _bstr_("NormalizeAttributeValues"), var);
ok(hr == S_OK, "Failed to set property, hr %#x.\n", hr);
V_VT(&var) = VT_I2;
V_I2(&var) = 10;
hr = IXMLDOMDocument2_getProperty(doc, _bstr_("NormalizeAttributeValues"), &var);
todo_wine {
ok(hr == S_OK, "Failed to get property value, hr %#x.\n", hr);
ok(V_VT(&var) == VT_BOOL, "Unexpected property value type, vt %d.\n", V_VT(&var));
ok(V_BOOL(&var) == VARIANT_TRUE, "Unexpected property value.\n");
}
IXMLDOMDocument2_Release(doc);
}
START_TEST(domdoc)
{
HRESULT hr;
......@@ -12875,6 +12913,7 @@ START_TEST(domdoc)
test_url();
test_merging_text();
test_transformNodeToObject();
test_normalize_attribute_values();
test_xsltemplate();
test_xsltext();
......
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