lordofthejars / nosql-unit

NoSQL Unit is a JUnit extension that helps you write NoSQL unit tests.
Other
383 stars 123 forks source link

Update MongoDB driver to 3.0 #133

Open ChrisDeBruyne opened 9 years ago

ChrisDeBruyne commented 9 years ago

We can't run our tests anymore since some methodes have been removed. Like :

java.lang.NoSuchMethodError: com.mongodb.DB.isAuthenticated()Z at com.lordofthejars.nosqlunit.mongodb.MongoOperation.getMongoDb(MongoOperation.java:122)

lordofthejars commented 9 years ago

Yes This would be a big impact on code upgrading to mongo driver 3.0. Currently I am working to implementing Neo4j2.x

I will need to see what's happening with MongoDb3.0. Of course feel free to collaborate.

ChrisDeBruyne commented 9 years ago

Would like to, but your master branch is unstable now. What commit is best to branch from? On 8 May 2015 15:19, "Alex Soto" notifications@github.com wrote:

Yes This would be a big impact on code upgrading to mongo driver 3.0. Currently I am working to implementing Neo4j2.x

I will need to see what's happening with MongoDb3.0. Of course feel free to collaborate.

— Reply to this email directly or view it on GitHub https://github.com/lordofthejars/nosql-unit/issues/133#issuecomment-100230029 .

lordofthejars commented 9 years ago

Well it is unstable because of neo4j, I will try to fix this weekend, but you can work with mongoDB module without any problem and just run these tests.

El dv., 8 maig 2015 a les 17:26, ChrisDeBruyne (notifications@github.com) va escriure:

Would like to, but your master branch is unstable now. What commit is best to branch from? On 8 May 2015 15:19, "Alex Soto" notifications@github.com wrote:

Yes This would be a big impact on code upgrading to mongo driver 3.0. Currently I am working to implementing Neo4j2.x

I will need to see what's happening with MongoDb3.0. Of course feel free to collaborate.

— Reply to this email directly or view it on GitHub < https://github.com/lordofthejars/nosql-unit/issues/133#issuecomment-100230029

.

— Reply to this email directly or view it on GitHub https://github.com/lordofthejars/nosql-unit/issues/133#issuecomment-100272711 .

ChrisDeBruyne commented 9 years ago

I was checking out the tests and noticed that you use Fongo (https://github.com/fakemongo/fongo) This is a problem because Fongo also does not support the new Java driver. So unless you decide to drop Fongo and use the real deal in your unit tests, I'm stuck :-(

lordofthejars commented 9 years ago

Everything done. Next release will contain MongoDB support.

paulovictorv commented 9 years ago

I'm really sorry to revive an old issue, but is there any updates on this? I've noticed that the only problem seems to be Fongo.

I've added an exclusion to 1.5.10 version of Fongo, and manually added the latest 2.0.2 and everything is running smooth.

ricardozanini commented 9 years ago

In fact, there's a problem with DBRef instances too: java.lang.NoSuchMethodError: com.mongodb.DBRef.getRef()Ljava/lang/String;

I am getting this error within @UsingDataSet and my data files pointing to each other through $ref attributes. I saw that this issue is already addressed in the new version, though. Waiting for this new release as well. :)

Thanks for your time and work with this lib, lord. But I just want to get this registered for others looking for this problem too. Downgrade to Mongo 2 is impossible for me at this time.

jschutijzer commented 8 years ago

Do you have any idea when the next release will be? We need the upgrade urgently :)

lordofthejars commented 7 years ago

Now tests are integrated with mongo 3.3.X, I will release this night.

lordofthejars commented 7 years ago

Released 0.12.0, now waiting to be sync to maven central.