diff options
author | Michael Stahl <mstahl@redhat.com> | 2017-04-11 15:39:56 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2017-04-11 16:56:39 +0200 |
commit | 5722b815fa34422595407e83029fb41583f13894 (patch) | |
tree | fe9e008564b4baaa1c7438abc638e07b8a0a6546 /sw | |
parent | 8bf9432b8aa9bf22fc20ba5faaf09386e77ee178 (diff) |
sw: let getProperty fail more helpfully
Change-Id: Ibca942235060c5b3a6215325e262bacbc464f2a4
Diffstat (limited to 'sw')
-rw-r--r-- | sw/qa/extras/inc/swmodeltestbase.hxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/sw/qa/extras/inc/swmodeltestbase.hxx b/sw/qa/extras/inc/swmodeltestbase.hxx index c4cbeebad1d3..e2ce0f5a9cd8 100644 --- a/sw/qa/extras/inc/swmodeltestbase.hxx +++ b/sw/qa/extras/inc/swmodeltestbase.hxx @@ -425,7 +425,9 @@ protected: T data; if (!css::uno::fromAny(properties->getPropertyValue(name), &data)) { - CPPUNIT_FAIL("the property is of unexpected type or void"); + OString const msg("the property is of unexpected type or void: " + + OUStringToOString(name, RTL_TEXTENCODING_UTF8)); + CPPUNIT_FAIL(msg.getStr()); } return data; } @@ -437,7 +439,9 @@ protected: T data = T(); if (!(properties->getPropertyValue(name) >>= data)) { - CPPUNIT_FAIL("the property is of unexpected type or void"); + OString const msg("the property is of unexpected type or void: " + + OUStringToOString(name, RTL_TEXTENCODING_UTF8)); + CPPUNIT_FAIL(msg.getStr()); } return data; } |