-
I have to stub a function that returns a future. So I create a promise, get a future from it and pass this future to a lambda that returns it. The lambda itself is movable, but not copyable, because t…
-
``` cpp
class TestClass
{
public:
static void create() {};
};
Mock testClass;
When(Method(testClass, create));
```
Build error: 'template' keyword not permitted here
-
### Is your feature request related to a problem? Please describe.
When doing development of APIs and clients, it is often useful to be able to create Mock API endpoints for testing/validation befo…
-
```cpp
{ // In block scope:
struct Callbacks {
virtual ~Callbacks() = default;
virtual auto on_ball_pocketed(nbs::eightball::BallId ball_id_) -> void = 0;
};
using namespace …
-
Hi,
With [Google Mock](https://github.com/google/googletest/blob/master/googlemock/README.md) we declare the actual mock class ourselves, and are thus able to add f.ex the Q_OBJECT macro. See an ex…
-
While dumping data to sync-gateway, i am getting this error:
```
[18:37:41] ✖ error: { Error: connect ECONNRESET 127.0.0.1:4985
at Object.exports._errnoException (util.js:1018:11)
at expor…
-
Hello, I want to co_return something from a mocked function. Something like:
```
// Instantiate a mock object.
Mock mock;
// Setup mock behavior.
When(Method(mock,foo)).CoReturn(1); // Method…
-
- [x] Test more versions of current compilers
- [x] Test with more standards of C++
- [x] Test with sanitizers enabled
- [x] Test on Apple Clang
- [ ] Test on MinGW
- [x] Move the MSVC tests in G…
-
**Channel**
C++ Weekly
**Topics**
There are powerful unittesting, mocking and stubbing libraries out there like gtest and gmock and others, but in order to mock a existing class, it needs a pur…
-
Hello!
I have an interface that has to be injected into an object which is going to take the ownership of the interface pointer. Here's an example
``` c++
class Interface { virtual ~Interface() {}; …