From bf623ed931b8e2f130425b42f0e79f484928f5cd Mon Sep 17 00:00:00 2001 From: Sean Bright Date: Thu, 15 Jun 2017 14:32:08 +0000 Subject: [PATCH] sip.js: Additional tests for updated/added methods --- types/sip.js/sip.js-tests.ts | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/types/sip.js/sip.js-tests.ts b/types/sip.js/sip.js-tests.ts index 44f61fea25..df6d47c7bc 100644 --- a/types/sip.js/sip.js-tests.ts +++ b/types/sip.js/sip.js-tests.ts @@ -7,11 +7,12 @@ const logConnector = (level: string, category: string, label: string, content: s const uaWithConfig: SIP.UA = new SIP.UA({ uri: "wss://uri", - wsServers: ["s1", "s2"], + wsServers: ["s1", "s2", { ws_uri: "s3", weight: 1 }], allowLegacyNotifications: true, authenticationFactory: mediaHandler, authorizationUser: "user", autostart: true, + autostop: false, connectionRecoveryMaxInterval: 1, connectionRecoveryMinInterval: 1, displayName: "name", @@ -93,3 +94,12 @@ ua.on('invite', (session: SIP.Session) => { session.on('rejected', (response) => {}); }); ua.on('message', (message: SIP.Message) => { }); + +session.hold({ + extraHeaders: [""], + eventHandlers: { + succeeded: () => {} + } +}); + +ua.start().stop();