|
|
|
|
|
|
|
|
}; |
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
struct ConditialThrowOnCopyMock |
|
|
|
|
|
|
|
|
struct ConditionalThrowOnCopyMock |
|
|
{ |
|
|
{ |
|
|
explicit ConditialThrowOnCopyMock(Handle h, bool throwOnCopyMock) : handle(h), |
|
|
|
|
|
|
|
|
explicit ConditionalThrowOnCopyMock(Handle h, bool throwOnCopyMock) : handle(h), |
|
|
shouldThrow(throwOnCopyMock) |
|
|
shouldThrow(throwOnCopyMock) |
|
|
{ |
|
|
{ |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
ConditialThrowOnCopyMock(const ConditialThrowOnCopyMock& other) : handle(other.handle), |
|
|
|
|
|
|
|
|
ConditionalThrowOnCopyMock(const ConditionalThrowOnCopyMock& other) : handle(other.handle), |
|
|
shouldThrow(other.shouldThrow) |
|
|
shouldThrow(other.shouldThrow) |
|
|
{ |
|
|
{ |
|
|
if( shouldThrow == true ) |
|
|
if( shouldThrow == true ) |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
ConditialThrowOnCopyMock(ConditialThrowOnCopyMock&&) = default; |
|
|
|
|
|
|
|
|
ConditionalThrowOnCopyMock(ConditionalThrowOnCopyMock&&) = default; |
|
|
|
|
|
|
|
|
ConditialThrowOnCopyMock& operator=(const ConditialThrowOnCopyMock& other) |
|
|
|
|
|
|
|
|
ConditionalThrowOnCopyMock& operator=(const ConditionalThrowOnCopyMock& other) |
|
|
{ |
|
|
{ |
|
|
if( &other != this ) |
|
|
if( &other != this ) |
|
|
{ |
|
|
{ |
|
|
|
|
|
|
|
|
return *this; |
|
|
return *this; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
ConditialThrowOnCopyMock& operator=(ConditialThrowOnCopyMock&&) = default; |
|
|
|
|
|
|
|
|
ConditionalThrowOnCopyMock& operator=(ConditionalThrowOnCopyMock&&) = default; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Handle handle; |
|
|
Handle handle; |