fixed GH #1462: AbstractConfiguration::getUInt does not parse hex numbers

This commit is contained in:
Guenter Obiltschnig
2016-10-24 09:41:49 +02:00
parent a1657d5e1b
commit 1f3b53298c
3 changed files with 13 additions and 10 deletions

View File

@@ -89,6 +89,7 @@ void AbstractConfigurationTest::testGetInt()
assert (pConf->getInt("prop4.int1") == 42);
assert (pConf->getInt("prop4.int2") == -42);
assert (pConf->getInt("prop4.hex") == 0x1f);
assert (pConf->getUInt("prop4.hex") == 0x1f);
assert (pConf->getInt("ref2") == 42);
try
@@ -114,6 +115,8 @@ void AbstractConfigurationTest::testGetInt64()
assert (pConf->getInt64("prop4.bigint1") == std::numeric_limits<Int64>::max());
assert (pConf->getInt64("prop4.bigint2") == std::numeric_limits<Int64>::min());
assert (pConf->getUInt64("prop4.biguint") == std::numeric_limits<UInt64>::max());
assert (pConf->getInt64("prop4.hex") == 0x1f);
assert (pConf->getUInt64("prop4.hex") == 0x1f);
assert (pConf->getInt64("ref2") == 42);
try