Browse Source

Update dev dependencies

Set idea language to ES6
Run tests against dist
master
Nicolas Dextraze 2 years ago
parent
commit
bbf25ee8b5
23 changed files with 5906 additions and 7570 deletions
  1. +1
    -1
      .idea/misc.xml
  2. +5862
    -7529
      package-lock.json
  3. +6
    -5
      package.json
  4. +2
    -2
      test/appendToStream_test.js
  5. +1
    -1
      test/cluster/dns_test.js
  6. +1
    -1
      test/cluster/gossipSeeds_test.js
  7. +1
    -1
      test/common/base_test.js
  8. +2
    -2
      test/connection_test.js
  9. +2
    -2
      test/deleteStream_test.js
  10. +1
    -1
      test/metadata_test.js
  11. +2
    -2
      test/persistentSubscription_test.js
  12. +2
    -2
      test/projections_test.js
  13. +2
    -2
      test/readAllEventsBackward_test.js
  14. +2
    -2
      test/readAllEventsForward_test.js
  15. +2
    -2
      test/readEvent_test.js
  16. +2
    -2
      test/readStreamEventsBackward_test.js
  17. +2
    -2
      test/readStreamEventsForward_test.js
  18. +2
    -2
      test/subscribeToAllFrom_test.js
  19. +2
    -2
      test/subscribeToAll_test.js
  20. +2
    -2
      test/subscribeToStreamFrom_test.js
  21. +2
    -2
      test/subscribeToStream_test.js
  22. +1
    -1
      test/transactions_test.js
  23. +4
    -2
      webpack.config.js

+ 1
- 1
.idea/misc.xml View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="JavaScriptSettings">
<option name="languageLevel" value="ES5" />
<option name="languageLevel" value="ES6" />
</component>
</project>

+ 5862
- 7529
package-lock.json
File diff suppressed because it is too large
View File


+ 6
- 5
package.json View File

@@ -51,10 +51,11 @@
"uuid": "^3.0.1"
},
"devDependencies": {
"@types/long": "^3.0.31",
"@types/node": "^6.0.47",
"jsdoc": "^3.5.5",
"nodeunit": "^0.11.1",
"webpack": "^3.3.0"
"@types/long": "^3.0.32",
"@types/node": "^12.12.5",
"jsdoc": "^3.6.3",
"nodeunit": "^0.11.3",
"webpack": "^4.41.2",
"webpack-cli": "^3.3.10"
}
}

+ 2
- 2
test/appendToStream_test.js View File

@@ -1,5 +1,5 @@
var uuid = require('uuid');
var client = require('../src/client');
var client = require('../lib/dist');
var Long = require('long');

var ANY_VERSION = Long.fromNumber(client.expectedVersion.any);
@@ -63,7 +63,7 @@ module.exports = {
test.expect(2);
const largeData = Buffer.alloc(3 * 1024 *1024, " ");
const event = client.createJsonEventData(uuid.v4(), {a: largeData.toString()}, null, 'largePayloadEvent');
this.conn.appendToStream(this.testStreamName, ANY_VERSION, event)
.then(function(result) {
test.areEqual("result.nextExpectedVersion", result.nextExpectedVersion, Long.fromNumber(0));


+ 1
- 1
test/cluster/dns_test.js View File

@@ -1,4 +1,4 @@
var client = require('../../src/client');
var client = require('../../lib/dist');
var uuid = require('uuid');

var settings = {


+ 1
- 1
test/cluster/gossipSeeds_test.js View File

@@ -1,4 +1,4 @@
var client = require('../../src/client');
var client = require('../../lib/dist');
var uuid = require('uuid');

var settings = {


+ 1
- 1
test/common/base_test.js View File

@@ -1,6 +1,6 @@
var util = require('util');
var uuid = require('uuid');
var client = require('../../src/client');
var client = require('../../lib/dist');
var FileLogger = require('../../src/common/log/fileLogger');
var NoopLogger = require('../../src/common/log/noopLogger');



+ 2
- 2
test/connection_test.js View File

@@ -1,4 +1,4 @@
var client = require('../src/client.js');
var client = require('../lib/dist');
var GossipSeed = require('../src/gossipSeed');

var testBase = require('./common/base_test');
@@ -97,4 +97,4 @@ if (withSsl) {
}
}

testBase.init(module.exports, false);
testBase.init(module.exports, false);

+ 2
- 2
test/deleteStream_test.js View File

@@ -1,5 +1,5 @@
var uuid = require('uuid');
var client = require('../src/client');
var client = require('../lib/dist');
var Long = require('long');

module.exports = {
@@ -102,4 +102,4 @@ module.exports = {
}
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 1
- 1
test/metadata_test.js View File

@@ -1,4 +1,4 @@
var client = require('../src/client');
var client = require('../lib/dist');
const Long = require('long');

const EMPTY_VERSION = Long.fromNumber(client.expectedVersion.emptyStream);


+ 2
- 2
test/persistentSubscription_test.js View File

@@ -1,6 +1,6 @@
var util = require('util');
var uuid = require('uuid');
var client = require('../src/client');
var client = require('../lib/dist');
const adminCredentials = new client.UserCredentials("admin", "changeit");

function createRandomEvent() {
@@ -78,4 +78,4 @@ module.exports = {
}
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 2
- 2
test/projections_test.js View File

@@ -1,4 +1,4 @@
const client = require('../src/client');
const client = require('../lib/dist');
const userCredentials = new client.UserCredentials('admin', 'changeit');

const log = new client.NoopLogger();
@@ -44,4 +44,4 @@ module.exports = {
.catch(test.done);
}
//TODO: other tests
};
};

+ 2
- 2
test/readAllEventsBackward_test.js View File

@@ -1,6 +1,6 @@
var util = require('util');
var uuid = require('uuid');
var client = require('../src/client');
var client = require('../lib/dist');

const numberOfStreams = 20;
const maxBatch = 10;
@@ -72,4 +72,4 @@ module.exports = {
}
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 2
- 2
test/readAllEventsForward_test.js View File

@@ -1,6 +1,6 @@
var util = require('util');
var uuid = require('uuid');
var client = require('../src/client');
var client = require('../lib/dist');

const numberOfStreams = 20;
const maxBatch = 10;
@@ -73,4 +73,4 @@ module.exports = {
}
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 2
- 2
test/readEvent_test.js View File

@@ -1,5 +1,5 @@
var uuid = require('uuid');
var client = require('../src/client');
var client = require('../lib/dist');
var Long = require('long');

var NOSTREAM_VERSION = Long.fromNumber(client.expectedVersion.noStream);
@@ -142,4 +142,4 @@ module.exports = {
},
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 2
- 2
test/readStreamEventsBackward_test.js View File

@@ -1,5 +1,5 @@
var uuid = require('uuid');
var client = require('../src/client');
var client = require('../lib/dist');
var Long = require('long');

const streamSize = 100;
@@ -109,4 +109,4 @@ module.exports = {
}
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 2
- 2
test/readStreamEventsForward_test.js View File

@@ -1,5 +1,5 @@
var uuid = require('uuid');
var client = require('../src/client');
var client = require('../lib/dist');
var Long = require('long');

const streamSize = 100;
@@ -108,4 +108,4 @@ module.exports = {
}
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 2
- 2
test/subscribeToAllFrom_test.js View File

@@ -1,6 +1,6 @@
var util = require('util');
var uuid = require('uuid');
var client = require('../src/client');
var client = require('../lib/dist');
const allCredentials = new client.UserCredentials("admin", "changeit");

function createRandomEvent() {
@@ -180,4 +180,4 @@ module.exports = {
}
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 2
- 2
test/subscribeToAll_test.js View File

@@ -1,5 +1,5 @@
const uuid = require('uuid');
const client = require('../src/client');
const client = require('../lib/dist');
const allCredentials = new client.UserCredentials("admin", "changeit");

function delay(ms) {
@@ -69,4 +69,4 @@ module.exports = {
}
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 2
- 2
test/subscribeToStreamFrom_test.js View File

@@ -1,5 +1,5 @@
var uuid = require('uuid');
var client = require('../src/client');
var client = require('../lib/dist');
var Long = require('long');

function createRandomEvent() {
@@ -134,4 +134,4 @@ module.exports = {
}
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 2
- 2
test/subscribeToStream_test.js View File

@@ -1,5 +1,5 @@
const uuid = require('uuid');
const client = require('../src/client');
const client = require('../lib/dist');
const Long = require('long');

function delay(ms) {
@@ -70,4 +70,4 @@ module.exports = {
}
};

require('./common/base_test').init(module.exports);
require('./common/base_test').init(module.exports);

+ 1
- 1
test/transactions_test.js View File

@@ -1,6 +1,6 @@
var uuid = require('uuid');
var Long = require('long');
var client = require('../src/client');
var client = require('../lib/dist');

var ANY_VERSION = Long.fromNumber(client.expectedVersion.any);
var NOSTREAM_VERSION = Long.fromNumber(client.expectedVersion.noStream);


+ 4
- 2
webpack.config.js View File

@@ -1,8 +1,10 @@
module.exports = {
mode: "none",
entry: "./src/client.js",
target: "node",
output: {
filename: "./lib/dist.js",
path: process.env.PWD + "/lib",
filename: "dist.js",
libraryTarget: "commonjs2"
},
externals: [
@@ -11,4 +13,4 @@ module.exports = {
"../messages/clientMessage": "../src/messages/clientMessage"
}
]
};
};

Loading…
Cancel
Save