MCPcopy Create free account
hub / github.com/boostorg/json / testPath

Method testPath

test/value_to.cpp:583–597  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

581
582 template< class... Context >
583 static
584 void testPath( Context const& ... ctx )
585 {
586 ignore_unused( ctx... );
587#ifndef BOOST_NO_CXX17_HDR_FILESYSTEM
588 using Paths = std::vector<std::filesystem::path>;
589 value jv = value{"from/here", "to/there", "", "c:/" , "..", "../"};
590 auto paths = value_to<Paths>( jv, ctx... );
591 BOOST_TEST(
592 paths == (Paths{
593 "from/here", "to/there", "", "c:/" , "..", "../"}) );
594 BOOST_TEST_THROWS_WITH_LOCATION(
595 value_to<std::filesystem::path>( value(1), ctx... ));
596#endif // BOOST_NO_CXX17_HDR_FILESYSTEM
597 }
598
599 template< class... Context >
600 static

Callers

nothing calls this directly

Calls 1

valueClass · 0.70

Tested by

no test coverage detected