I want to test my java code that uses the couchbase java client, but without test it on a real cluster.
I wondered if there’s any in-memory cluster I can check it with (some kind of mock to the cluster), in order to run my unit tests.
actually there is nothing officially supported. What you can do and what I’d recommend is probably you want to mock the Bucket interface with Mockito or something and return the values that you’re expecting - if you want to unit test the interface.
I tried to use the project you wrote here, the problem is, that my code (DAO) actually suppose to talk to existing cluster and perform some operations about it, like get buckets and insert documents and I’m searching for “in memory server” or “cluster from code”, a real way to mock the couchbase cluster instead of really create a real one.