sharedb-mongo 3.0.0 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/test.yml +1 -1
- package/package.json +4 -4
- package/test/test_mongo.js +4 -3
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sharedb-mongo",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0",
|
|
4
4
|
"description": "MongoDB database adapter for ShareDB",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"dependencies": {
|
|
7
7
|
"mongodb": "^3.1.13 || ^4.0.0 || ^5.0.0",
|
|
8
|
-
"sharedb": "^1.9.1 || ^2.0.0 || ^3.0.0"
|
|
8
|
+
"sharedb": "^1.9.1 || ^2.0.0 || ^3.0.0 || ^4.0.0"
|
|
9
9
|
},
|
|
10
10
|
"devDependencies": {
|
|
11
11
|
"async": "^3.2.4",
|
|
@@ -19,8 +19,8 @@
|
|
|
19
19
|
"mongodb5": "npm:mongodb@^5.0.0",
|
|
20
20
|
"nyc": "^14.1.1",
|
|
21
21
|
"ot-json1": "^1.0.1",
|
|
22
|
-
"sharedb-mingo-memory": "^1.
|
|
23
|
-
"sinon": "^
|
|
22
|
+
"sharedb-mingo-memory": "^1.0.0 || ^2.0.0 || ^3.0.0",
|
|
23
|
+
"sinon": "^9.2.4",
|
|
24
24
|
"sinon-chai": "^3.7.0"
|
|
25
25
|
},
|
|
26
26
|
"scripts": {
|
package/test/test_mongo.js
CHANGED
|
@@ -334,9 +334,10 @@ describe('mongo db', function() {
|
|
|
334
334
|
});
|
|
335
335
|
|
|
336
336
|
it('$mapReduce queries should work when allowJavaScriptQuery == true', function(done) {
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
337
|
+
// This function was removed in mongodb5:
|
|
338
|
+
// https://github.com/mongodb/node-mongodb-native/pull/3511
|
|
339
|
+
var mapReduceSupported = typeof this.db.mongo.collection('test').mapReduce === 'function';
|
|
340
|
+
if (!mapReduceSupported) {
|
|
340
341
|
return done();
|
|
341
342
|
}
|
|
342
343
|
var snapshots = [
|