Do not use shared_ptr<Config> when listing things

This commit is contained in:
Martin Hořeňovský
2020-05-19 17:29:24 +02:00
parent fa160cf3f2
commit 458241cc90
3 changed files with 12 additions and 10 deletions

View File

@@ -273,11 +273,14 @@ namespace Catch {
applyFilenamesAsTags();
}
// Set up global config instance before we start calling into other functions
getCurrentMutableContext().setConfig(m_config);
// Create reporter(s) so we can route listings through them
auto reporter = makeReporter(m_config.get());
// Handle list request
if (list(*reporter, m_config)) {
if (list(*reporter, *m_config)) {
return 0;
}