Closed MatsJakobsson closed 5 years ago
Hello @MatsJakobsson and thanks for opening this.
Up until 2.5.0 the constructor for CosmosResponse was public and I accidentally set it back to internal. The idea was that if people wanted to wrap their CosmosDB responses with this single response object, they should be able to. I don't know how this will be in 3.0 but for now I am changing back to public as it would be a breaking change.
This should allow you to to create the object on your Mocking framework's Returns
method. Does that sound ok?
Wow! You are fast! :)
Sounds great! An interface would be even more flexible, but a public constructor would simplify a lot.
Thanks!
Public constructors added back in 2.6.2. Feel free to upgrade. Donāt forget to read the response handling sector of the readme page.
Yeah I think Iāll have to rethink some appoaches in 3.0, this one included. The end goal would be an interface but I canāt massively change interfaces without a major release atm.
Thanks for raising this issue and thanks for using Cosmonaut. Closing this for now. Feel free to open a new issue if you find some problem.
Hi,
Is it possible to rewrite so that AddAsync (and similiar) in ICosmosStore returns some form of interface instead of CosmosResponse. This would simplify mocking/testing a lot.
Many thanks!