summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2023-08-06 12:28:46 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2023-08-06 12:28:46 +0100
commit4a78d1ee35343f5609186a582e6352f2939acb1f (patch)
tree10d9e565abaeb81ca85c17e2b213c1b42d405613
parent[De]serializeAny[With] uses unique_ptr (diff)
downloadslicer-4a78d1ee35343f5609186a582e6352f2939acb1f.tar.bz2
slicer-4a78d1ee35343f5609186a582e6352f2939acb1f.tar.xz
slicer-4a78d1ee35343f5609186a582e6352f2939acb1f.zip
Test making deserializers on stack
-rw-r--r--slicer/test/serializers.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/slicer/test/serializers.cpp b/slicer/test/serializers.cpp
index 379551b..5e643a9 100644
--- a/slicer/test/serializers.cpp
+++ b/slicer/test/serializers.cpp
@@ -589,11 +589,11 @@ BOOST_AUTO_TEST_CASE(xml_streams)
BOOST_AUTO_TEST_CASE(invalid_enum)
{
- auto jdeserializer = std::make_shared<Slicer::JsonFileDeserializer>(rootDir / "initial" / "invalidEnum.json");
+ Slicer::JsonFileDeserializer jdeserializer {rootDir / "initial" / "invalidEnum.json"};
BOOST_REQUIRE_THROW(
Slicer::DeserializeAnyWith<TestModule::SomeNumbers>(jdeserializer), Slicer::InvalidEnumerationSymbol);
- auto xdeserializer = std::make_shared<Slicer::XmlFileDeserializer>(rootDir / "initial" / "invalidEnum.xml");
+ Slicer::XmlFileDeserializer xdeserializer {rootDir / "initial" / "invalidEnum.xml"};
BOOST_REQUIRE_THROW(
Slicer::DeserializeAnyWith<TestModule::SomeNumbers>(xdeserializer), Slicer::InvalidEnumerationSymbol);
}