mirror of
https://github.com/jambonz/jambonz-feature-server.git
synced 2025-12-19 04:17:44 +00:00
fix tests
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
"type": "sip",
|
||||
"number": "sip:1617333456@sip.trunk1.com",
|
||||
"auth": {
|
||||
"user": "foo",
|
||||
"username": "foo",
|
||||
"password": "bar"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,13 +13,13 @@ test('app payload parsing tests', (t) => {
|
||||
let task = makeTask(logger, require('./data/good/sip-decline'));
|
||||
t.ok(task.name === 'sip:decline', 'parsed sip:decline');
|
||||
|
||||
t.throws(errInvalidInstruction, /invalid instruction/, 'throws error for invalid instruction');
|
||||
t.throws(errInvalidInstruction, /malformed jambonz application payload/, 'throws error for invalid instruction');
|
||||
t.throws(errUnknownProperty, /unknown property/, 'throws error for invalid instruction');
|
||||
t.throws(errMissingProperty, /missing value/, 'throws error for missing required property');
|
||||
t.throws(errInvalidType, /invalid data type/, 'throws error for invalid data type');
|
||||
t.throws(errBadEnum, /must be one of/, 'throws error for invalid enum');
|
||||
t.throws(errBadPayload, /invalid instruction payload/, 'throws error for invalid payload with multiple keys');
|
||||
t.throws(errBadPayload2, /invalid instruction payload/, 'throws error for invalid payload that is not an object');
|
||||
t.throws(errBadPayload, /malformed jambonz application payload/, 'throws error for invalid payload with multiple keys');
|
||||
t.throws(errBadPayload2, /malformed jambonz application payload/, 'throws error for invalid payload that is not an object');
|
||||
|
||||
task = makeTask(logger, require('./data/good/dial-phone'));
|
||||
t.ok(task.name === 'dial', 'parsed dial phone');
|
||||
|
||||
Reference in New Issue
Block a user