Mir

Comment 3 for bug 1316987

Revision history for this message
Alan Griffiths (alan-griffiths) wrote :

I think it is a small task to separate main() and argc, argv from stubbed_server_configuration.cpp into a new file and write a new function to go with it.

auto mtf::configuration_from_commandline()
-> shared_ptr<mo::Configuration>
{
  return std::make_shared<mo::DefaultConfiguration>(::argc, ::argv);
}

This can then be called both from StubbedServerConfiguration and any other places that need it.