mardi 23 décembre 2014

Mocking throwing mongoDb exceptions in Clojure

I want to overwrite my function to throw com.mongodb.MongoException$DuplicateKey. But that class needs some object called com.mongodb.CommandResult in its constructor.


Problem is with that com.mongodb.CommandResult. No matter what I am trying to do, I end up with:



No matching ctor found for class com.mongodb.CommandResult



getConstructors says it has no constructor. But if I try to do it without parameters it's the same... Could someone point what am I doing wrong?


Aucun commentaire:

Enregistrer un commentaire