diff --git a/packages/binding-opcua/test/client-test.ts b/packages/binding-opcua/test/client-test.ts index 415a8dc60..30f0b0327 100644 --- a/packages/binding-opcua/test/client-test.ts +++ b/packages/binding-opcua/test/client-test.ts @@ -40,9 +40,6 @@ describe("OPCUA Client", function () { const codecSerDes = ContentSerdes.get(); codecSerDes.addCodec(new OpcuaJSONCodec()); }); - after(async () => { - await opcuaServer.shutdown(); - }); let client: OPCUAProtocolClient; before(async function () { @@ -51,6 +48,10 @@ describe("OPCUA Client", function () { after(async () => { await client.stop(); }); + // server shall stop after client + after(async () => { + await opcuaServer.shutdown(); + }); [ // 0 diff --git a/packages/binding-opcua/test/full-opcua-thing-test.ts b/packages/binding-opcua/test/full-opcua-thing-test.ts index d339d855b..f29ec5362 100644 --- a/packages/binding-opcua/test/full-opcua-thing-test.ts +++ b/packages/binding-opcua/test/full-opcua-thing-test.ts @@ -308,6 +308,10 @@ describe("Full OPCUA Thing Test", () => { opcuaServer = await startServer(); endpoint = opcuaServer.getEndpointUrl(); debug(`endpoint = ${endpoint}`); + + // adjust TD to endpoint + thingDescription.base = endpoint; + (thingDescription.opcua as unknown as { endpoint: string }).endpoint = endpoint; }); after(async () => { await opcuaServer.shutdown();