in BoostTestAdapter/Boost/Runner/BoostTest162Runner.cs [88:122]
private BoostTestRunnerCommandLineArgs AdaptArguments(BoostTestRunnerCommandLineArgs args)
{
// Boost Test for Boost 1.62 causes an incorrect cast issue with the --log_sink (and --report_sink) command line argument
if (args.Log != Sink.StandardOutput)
{
// Make use of environment variables instead of command-line
// arguments to retain support for Boost Test in Boost 1.61
string logSink = args.Log.ToString();
if (args.Log != Sink.StandardError)
{
// Remove the ':' used as the volume separator since the Boost Test framework interprets it as a logger separator
logSink = ((Path.IsPathRooted(logSink) && (logSink[1] == ':')) ? logSink.Substring(2) : logSink);
}
// BOOST_TEST_LOGGER (--logger) overrides --log_sink, --log_format and --log_level
args.Environment["BOOST_TEST_LOGGER"] = string.Format(
CultureInfo.InvariantCulture,
"{0},{1},{2}",
BoostTestRunnerCommandLineArgs.OutputFormatToString(args.LogFormat),
BoostTestRunnerCommandLineArgs.LogLevelToString(args.LogLevel),
logSink
);
}
// Boost Test (Boost 1.62) --report_sink workaround - force report output to standard error due to cast issue with --report_sink
args.Report = Sink.StandardError;
if (string.IsNullOrEmpty(args.StandardErrorFile))
{
args.StandardErrorFile = TestPathGenerator.Generate(this.Source, FileExtensions.StdErrFile);
}
return args;
}