MCPcopy Create free account
hub / github.com/apache/qpid-proton / applyCommandLine

Method applyCommandLine

tests/include/catch.hpp:13461–13484  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13459 }
13460
13461 int Session::applyCommandLine( int argc, char const * const * argv ) {
13462 if( m_startupExceptions )
13463 return 1;
13464
13465 auto result = m_cli.parse( clara::Args( argc, argv ) );
13466 if( !result ) {
13467 config();
13468 getCurrentMutableContext().setConfig(m_config);
13469 Catch::cerr()
13470 << Colour( Colour::Red )
13471 << "\nError(s) in input:\n"
13472 << Column( result.errorMessage() ).indent( 2 )
13473 << "\n\n";
13474 Catch::cerr() << "Run with -? for usage\n" << std::endl;
13475 return MaxExitCode;
13476 }
13477
13478 if( m_configData.showHelp )
13479 showHelp();
13480 if( m_configData.libIdentify )
13481 libIdentify();
13482 m_config.reset();
13483 return 0;
13484 }
13485
13486#if defined(CATCH_CONFIG_WCHAR) && defined(_WIN32) && defined(UNICODE)
13487 int Session::applyCommandLine( int argc, wchar_t const * const * argv ) {

Callers

nothing calls this directly

Calls 8

ArgsClass · 0.85
ColourClass · 0.85
ColumnClass · 0.85
setConfigMethod · 0.80
errorMessageMethod · 0.80
parseMethod · 0.45
indentMethod · 0.45
resetMethod · 0.45

Tested by

no test coverage detected