mirror of
https://gitlab.com/openstapps/openstapps.git
synced 2026-03-10 00:32:25 +00:00
build: update dependencies
This commit is contained in:
@@ -22,6 +22,8 @@ import {
|
||||
SCMessage,
|
||||
SCThingUpdateResponse,
|
||||
SCThingUpdateRoute,
|
||||
SCThingType,
|
||||
SCThingOriginType,
|
||||
} from '@openstapps/core';
|
||||
import * as chai from 'chai';
|
||||
import {expect} from 'chai';
|
||||
@@ -61,7 +63,7 @@ export class ConnectorClientSpec {
|
||||
expiration: moment().add(1800, 'seconds').format(),
|
||||
source: 'foo',
|
||||
state: 'in progress',
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
uid: 'foo',
|
||||
},
|
||||
headers: {},
|
||||
@@ -72,13 +74,13 @@ export class ConnectorClientSpec {
|
||||
expect(httpClient.request).not.to.have.been.called();
|
||||
|
||||
const connectorClient = new ConnectorClient(httpClient, 'http://localhost');
|
||||
await connectorClient.bulk('message', 'foo', 1800);
|
||||
await connectorClient.bulk(SCThingType.Message, 'foo', 1800);
|
||||
|
||||
expect(httpClient.request).to.have.been.first.called.with({
|
||||
body: {
|
||||
expiration: moment().add(1800, 'seconds').format(),
|
||||
source: 'foo',
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
},
|
||||
headers: {},
|
||||
method: bulkRoute.method,
|
||||
@@ -94,7 +96,7 @@ export class ConnectorClientSpec {
|
||||
expiration: moment().add(3600, 'seconds').format(),
|
||||
source: 'foo',
|
||||
state: 'in progress',
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
uid: 'foo',
|
||||
},
|
||||
headers: {},
|
||||
@@ -105,13 +107,13 @@ export class ConnectorClientSpec {
|
||||
expect(httpClient.request).not.to.have.been.called();
|
||||
|
||||
const connectorClient = new ConnectorClient(httpClient, 'http://localhost');
|
||||
await connectorClient.bulk('message', 'foo');
|
||||
await connectorClient.bulk(SCThingType.Message, 'foo');
|
||||
|
||||
expect(httpClient.request).to.have.been.first.called.with({
|
||||
body: {
|
||||
expiration: moment().add(3600, 'seconds').format(),
|
||||
source: 'foo',
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
},
|
||||
headers: {},
|
||||
method: bulkRoute.method,
|
||||
@@ -131,8 +133,9 @@ export class ConnectorClientSpec {
|
||||
origin: {
|
||||
indexed: 'foo',
|
||||
name: 'foo',
|
||||
type: SCThingOriginType.Remote,
|
||||
},
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
uid: 'foo',
|
||||
},
|
||||
{
|
||||
@@ -144,8 +147,9 @@ export class ConnectorClientSpec {
|
||||
origin: {
|
||||
indexed: 'foo',
|
||||
name: 'foo',
|
||||
type: SCThingOriginType.Remote,
|
||||
},
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
uid: 'bar',
|
||||
},
|
||||
];
|
||||
@@ -160,7 +164,7 @@ export class ConnectorClientSpec {
|
||||
expiration: moment().add(3600, 'seconds').format(),
|
||||
source: 'copy',
|
||||
state: 'in progress',
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
uid: 'foo',
|
||||
},
|
||||
headers: {},
|
||||
@@ -190,7 +194,7 @@ export class ConnectorClientSpec {
|
||||
body: {
|
||||
expiration: moment().add(3600, 'seconds').format(),
|
||||
source: 'copy',
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
},
|
||||
headers: {},
|
||||
method: bulkRoute.method,
|
||||
@@ -216,8 +220,9 @@ export class ConnectorClientSpec {
|
||||
origin: {
|
||||
indexed: 'foo',
|
||||
name: 'foo',
|
||||
type: SCThingOriginType.Remote,
|
||||
},
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
uid: 'foo',
|
||||
},
|
||||
{
|
||||
@@ -229,8 +234,9 @@ export class ConnectorClientSpec {
|
||||
origin: {
|
||||
indexed: 'foo',
|
||||
name: 'foo',
|
||||
type: SCThingOriginType.Remote,
|
||||
},
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
uid: 'bar',
|
||||
},
|
||||
];
|
||||
@@ -245,7 +251,7 @@ export class ConnectorClientSpec {
|
||||
expiration: moment().add(3600, 'seconds').format(),
|
||||
source: 'stapps-api',
|
||||
state: 'in progress',
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
uid: 'foo',
|
||||
},
|
||||
headers: {},
|
||||
@@ -275,7 +281,7 @@ export class ConnectorClientSpec {
|
||||
body: {
|
||||
expiration: moment().add(3600, 'seconds').format(),
|
||||
source: 'stapps-api',
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
},
|
||||
headers: {},
|
||||
method: bulkRoute.method,
|
||||
@@ -310,8 +316,9 @@ export class ConnectorClientSpec {
|
||||
origin: {
|
||||
indexed: 'foo',
|
||||
name: 'foo',
|
||||
type: SCThingOriginType.Remote,
|
||||
},
|
||||
type: 'message',
|
||||
type: SCThingType.Message,
|
||||
uid: 'foo',
|
||||
};
|
||||
|
||||
@@ -333,7 +340,7 @@ export class ConnectorClientSpec {
|
||||
headers: {},
|
||||
method: thingUpdateRoute.method,
|
||||
url: new URL('http://localhost' + thingUpdateRoute.getUrlFragment({
|
||||
TYPE: 'message',
|
||||
TYPE: SCThingType.Message,
|
||||
UID: 'foo',
|
||||
})),
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user