Migrated Config and IConfig to shared_ptr (from Ptr)

This commit is contained in:
Phil Nash
2017-04-25 20:18:02 +01:00
parent 41afd0c3d4
commit 338ba6b9ba
10 changed files with 32 additions and 32 deletions

View File

@@ -21,6 +21,8 @@ namespace Catch {
struct IGeneratorsForTest;
struct IConfig;
using IConfigPtr = std::shared_ptr<IConfig const>;
struct IContext
{
virtual ~IContext();
@@ -29,7 +31,7 @@ namespace Catch {
virtual IRunner* getRunner() = 0;
virtual size_t getGeneratorIndex( std::string const& fileInfo, size_t totalSize ) = 0;
virtual bool advanceGeneratorsForCurrentTest() = 0;
virtual Ptr<IConfig const> getConfig() const = 0;
virtual IConfigPtr getConfig() const = 0;
};
struct IMutableContext : IContext
@@ -37,7 +39,7 @@ namespace Catch {
virtual ~IMutableContext();
virtual void setResultCapture( IResultCapture* resultCapture ) = 0;
virtual void setRunner( IRunner* runner ) = 0;
virtual void setConfig( Ptr<IConfig const> const& config ) = 0;
virtual void setConfig( IConfigPtr const& config ) = 0;
};
IContext& getCurrentContext();