@pryv/monitor 3.0.0 → 3.0.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pryv/monitor",
3
- "version": "3.0.0",
3
+ "version": "3.0.1",
4
4
  "description": "Extends `pryv` with event-driven notifications for changes on a Pryv.io account",
5
5
  "keywords": [
6
6
  "Pryv",
@@ -6,7 +6,7 @@
6
6
 
7
7
  require('./load-helpers');
8
8
 
9
- describe('Monitor', function () {
9
+ describe('[MONX] Monitor', function () {
10
10
  this.timeout(20000);
11
11
 
12
12
  before(async function () {
@@ -14,18 +14,18 @@ describe('Monitor', function () {
14
14
  await prepareAndCreateBaseStreams();
15
15
  });
16
16
 
17
- describe('init', () => {
18
- it('can be initialized with an apiEndpoint', async () => {
17
+ describe('[MINX] init', () => {
18
+ it('[MINA] can be initialized with an apiEndpoint', async () => {
19
19
  const monitor = new pryv.Monitor(apiEndpoint, { limit: 1 });
20
20
  await monitor.start();
21
21
  });
22
22
 
23
- it('can be initialized with a connection', async () => {
23
+ it('[MINB] can be initialized with a connection', async () => {
24
24
  const monitor = new pryv.Monitor(conn, { limit: 1 });
25
25
  await monitor.start();
26
26
  });
27
27
 
28
- it('throw Error on invalid apiEndpoint', async () => {
28
+ it('[MINC] throw Error on invalid apiEndpoint', async () => {
29
29
  let passed = true;
30
30
  try {
31
31
  pryv.Monitor('BlipBlop', { limit: 1 });
@@ -37,7 +37,7 @@ describe('Monitor', function () {
37
37
  });
38
38
  });
39
39
 
40
- describe('notifications', () => {
40
+ describe('[MNTX] notifications', () => {
41
41
  let monitor = null;
42
42
  beforeEach(async () => {
43
43
  monitor = new pryv.Monitor(conn, { limit: 1 });
@@ -47,7 +47,7 @@ describe('Monitor', function () {
47
47
  monitor.stop();
48
48
  });
49
49
 
50
- it('Load events at start', async function () {
50
+ it('[MNTA] Load events at start', async function () {
51
51
  let count = 0;
52
52
  monitor.on('event', function (event) {
53
53
  count++;
@@ -67,7 +67,7 @@ describe('Monitor', function () {
67
67
  expect(count).to.be.gt(0);
68
68
  });
69
69
 
70
- it('Detect new events added', async function () {
70
+ it('[MNTB] Detect new events added', async function () {
71
71
  let count = 0;
72
72
  await monitor.start();
73
73
 
@@ -7,16 +7,16 @@
7
7
  require('./load-helpers');
8
8
  require('@pryv/socket.io')(pryv);
9
9
 
10
- describe('Monitor + Socket.IO', function () {
10
+ describe('[MSKX] Monitor + Socket.IO', function () {
11
11
  this.timeout(20000);
12
12
 
13
13
  before(async () => {
14
14
  await prepareAndCreateBaseStreams();
15
15
  });
16
16
 
17
- describe('socket updates', function () {
17
+ describe('[MSUX] socket updates', function () {
18
18
  this.timeout(25000);
19
- it('Detect new events added', async function () {
19
+ it('[MSUA] Detect new events added', async function () {
20
20
  const monitor = new pryv.Monitor(apiEndpoint, { limit: 1 })
21
21
  .addUpdateMethod(new pryv.Monitor.UpdateMethod.Socket());
22
22
  await monitor.start();
@@ -47,8 +47,8 @@ describe('Monitor + Socket.IO', function () {
47
47
  });
48
48
  });
49
49
 
50
- describe('stop', () => {
51
- it('Monitor stops when requested', async function () {
50
+ describe('[MSTX] stop', () => {
51
+ it('[MSTA] Monitor stops when requested', async function () {
52
52
  this.timeout(20000);
53
53
  const monitor = new pryv.Monitor(apiEndpoint, { limit: 1 })
54
54
  .addUpdateMethod(new pryv.Monitor.UpdateMethod.Socket());
@@ -6,15 +6,15 @@
6
6
 
7
7
  require('./load-helpers');
8
8
 
9
- describe('Monitor + EventsTimer', function () {
9
+ describe('[TIMX] Monitor + EventsTimer', function () {
10
10
  this.timeout(20000);
11
11
 
12
12
  before(async () => {
13
13
  await prepareAndCreateBaseStreams();
14
14
  });
15
15
 
16
- describe('init', () => {
17
- it('throw error if timer is not inistialized with correct time', async () => {
16
+ describe('[TINX] init', () => {
17
+ it('[TINA] throw error if timer is not inistialized with correct time', async () => {
18
18
  const monitor = new pryv.Monitor(apiEndpoint, { limit: 1 });
19
19
  try {
20
20
  /* eslint-disable-next-line no-new */
@@ -26,8 +26,8 @@ describe('Monitor + EventsTimer', function () {
26
26
  });
27
27
  });
28
28
 
29
- describe('timer updates', () => {
30
- it('Detect new events added', async function () {
29
+ describe('[TUPX] timer updates', () => {
30
+ it('[TUPA] Detect new events added', async function () {
31
31
  const monitor = new pryv.Monitor(apiEndpoint, { limit: 1 })
32
32
  .addUpdateMethod(new pryv.Monitor.UpdateMethod.EventsTimer(1));
33
33
  await monitor.start();
@@ -58,8 +58,8 @@ describe('Monitor + EventsTimer', function () {
58
58
  });
59
59
  });
60
60
 
61
- describe('stop', () => {
62
- it('Monitor stops when requested', async function () {
61
+ describe('[TSTX] stop', () => {
62
+ it('[TSTA] Monitor stops when requested', async function () {
63
63
  this.timeout(20000);
64
64
  const monitor = await new pryv.Monitor(apiEndpoint, { limit: 1 })
65
65
  .addUpdateMethod(new pryv.Monitor.UpdateMethod.EventsTimer(1));