mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-27 22:49:56 -05:00
Improved assertions
refs https://github.com/TryGhost/Toolbox/issues/283
This commit is contained in:
parent
a1e1feb125
commit
7252f03824
1 changed files with 2 additions and 1 deletions
|
@ -73,7 +73,8 @@ describe('Webhook Service', function () {
|
|||
|
||||
assert.equal(requestStub.called, true);
|
||||
assert.equal(requestStub.args[0][0], 'http://example.com');
|
||||
assert.deepEqual(requestStub.args[0][1].body, '{"data":[1]}');
|
||||
assert.equal(requestStub.args[0][1].body, '{"data":[1]}');
|
||||
assert.deepEqual(Object.keys(requestStub.args[0][1].headers), ['Content-Length', 'Content-Type', 'Content-Version']);
|
||||
assert.equal(requestStub.args[0][1].headers['Content-Length'], 12);
|
||||
assert.equal(requestStub.args[0][1].headers['Content-Type'], 'application/json');
|
||||
assert.match(requestStub.args[0][1].headers['Content-Version'], /v\d+\.\d+/);
|
||||
|
|
Loading…
Add table
Reference in a new issue