Skip to content

Commit 4da5940

Browse files
authored
Adjust to support type stripping (#389)
1 parent bb3cdb0 commit 4da5940

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

test/samlTests.spec.ts

+5-3
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,10 @@ describe("saml.ts", function () {
2929
let getKeyInfosAsPemSpy: sinon.SinonSpy;
3030

3131
beforeEach(function () {
32-
getKeyInfosAsPemSpy = sinon.spy(SAML.prototype, <never>"getKeyInfosAsPem");
33-
sinon.stub(SAML.prototype, <never>"processValidlySignedPostRequestAsync").resolves(null);
32+
getKeyInfosAsPemSpy = sinon.spy(SAML.prototype, "getKeyInfosAsPem" as never);
33+
sinon
34+
.stub(SAML.prototype, "processValidlySignedPostRequestAsync" as unknown as keyof SAML)
35+
.resolves(null);
3436
});
3537

3638
afterEach(function () {
@@ -132,7 +134,7 @@ describe("saml.ts", function () {
132134
it("will fail if 'cert' is a callback which returns invalid value", async () => {
133135
const cert: IdpCertCallback = (cb) => {
134136
setTimeout(() => {
135-
cb(null, <never>null);
137+
cb(null, null as never);
136138
}, 0);
137139
};
138140

0 commit comments

Comments
 (0)