Skip to content

Commit 985c9b8

Browse files
Fixed failure tests that could erroneously pass even if no error was thrown
1 parent 304554f commit 985c9b8

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

test/specs/refs.spec.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,7 @@ describe('$Refs object', function () {
248248
.then(function ($refs) {
249249
$refs.get('definitions/name.yaml#/');
250250
})
251+
.then(helper.shouldNotGetCalled)
251252
.catch(function (err) {
252253
expect(err).to.be.an.instanceOf(Error);
253254
expect(err.message).to.equal(
@@ -276,6 +277,7 @@ describe('$Refs object', function () {
276277
.then(function ($refs) {
277278
$refs.get('foo-bar.yaml#/some/value');
278279
})
280+
.then(helper.shouldNotGetCalled)
279281
.catch(function (err) {
280282
expect(err).to.be.an.instanceOf(Error);
281283
expect(err.message).to.equal(
@@ -291,6 +293,7 @@ describe('$Refs object', function () {
291293
.then(function ($refs) {
292294
$refs.get('external.yaml#/foo/bar');
293295
})
296+
.then(helper.shouldNotGetCalled)
294297
.catch(function (err) {
295298
expect(err).to.be.an.instanceOf(Error);
296299
expect(err.message).to.equal(
@@ -336,6 +339,7 @@ describe('$Refs object', function () {
336339
.then(function ($refs) {
337340
$refs.set('foo-bar.yaml#/some/path', 'some value');
338341
})
342+
.then(helper.shouldNotGetCalled)
339343
.catch(function (err) {
340344
expect(err).to.be.an.instanceOf(Error);
341345
expect(err.message).to.equal(

0 commit comments

Comments
 (0)