diff --git a/test/pitytest11/src/PityUnit.hh b/test/pitytest11/src/PityUnit.hh index 0c04e55..e75ab16 100644 --- a/test/pitytest11/src/PityUnit.hh +++ b/test/pitytest11/src/PityUnit.hh @@ -25,7 +25,7 @@ namespace pEp { // * returns 0 using TestFunction = std::function&, TestContext*)>; - // Constructors are private + // Constructors PityUnit() = delete; explicit PityUnit( const std::string& name, @@ -41,6 +41,11 @@ namespace pEp { ExecutionMode exec_mode = ExecutionMode::FUNCTION); PityUnit(const PityUnit &rhs); + + // copy-assign + PityUnit& operator=(const PityUnit& rhs); + + // clone PityUnit *clone() override; // Read-Only diff --git a/test/pitytest11/src/PityUnit.hxx b/test/pitytest11/src/PityUnit.hxx index 122940d..4439d1e 100644 --- a/test/pitytest11/src/PityUnit.hxx +++ b/test/pitytest11/src/PityUnit.hxx @@ -54,6 +54,14 @@ namespace pEp { _test_func = rhs._test_func; } + template + PityUnit &PityUnit::operator=(const PityUnit &rhs) + { + _perspective = rhs._perspective; + _test_func = rhs._test_func; + return *this; + } + template PityUnit *PityUnit::clone() {