Skip to content

Commit

Permalink
remove commented code
Browse files Browse the repository at this point in the history
  • Loading branch information
gilv93 committed Sep 30, 2024
1 parent b3caa97 commit 01d4aa2
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 46 deletions.
6 changes: 0 additions & 6 deletions lib/recurly/risk/three-d-secure/three-d-secure.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,12 +110,6 @@ export class ThreeDSecure extends RiskConcern {
// return finishedPreflights.concat([{ processor: type, gateway_code, results}]);
return {
tokenType: finishedPreflights.tokenType || tokenType,
// risk: {
// processor: gatewayType,
// gateway_code,
// risk
// // finishedPreflights.risk.concat(risk)
// }
risk: finishedPreflights.risk.concat({
processor: gatewayType,
gateway_code,
Expand Down
14 changes: 0 additions & 14 deletions test/unit/risk.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,20 +85,6 @@ describe('Risk', function () {
});
});

// it('appends proactive data to the preflight request when enabled', function (done) {
// const { recurly, sandbox, bin } = this;
// recurly.config.risk.threeDSecure.proactive.enabled = true;
// recurly.config.risk.threeDSecure.proactive.gateway_code = 'test-gateway-code';
// recurly.config.risk.threeDSecure.proactive.amount = 0.00
// sandbox.spy(recurly.request, 'get');
// Risk.preflight({ recurly, bin })
// .done(results => {
// assert(recurly.request.get.calledOnce);
// assert(recurly.request.get.calledWithMatch({ route: '/risk/preflights?proactive=true&gatewayCode=test-gateway-code' }));
// done();
// });
// });

describe('when some results are timeouts', function () {
beforeEach(function () {
this.stubPreflightResults = { risk: [
Expand Down
26 changes: 0 additions & 26 deletions test/unit/risk/three-d-secure.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -242,32 +242,6 @@ describe('ThreeDSecure', function () {
});
});

// describe('when a proactiveTokenId is provided', function () {
// it('throws an error if it is not valid', function (done) {
// const { risk } = this;
// const threeDSecure = new ThreeDSecure({ risk, proactiveTokenId: 'invalid-token-id' });

// threeDSecure.on('error', err => {
// assert.strictEqual(err.code, 'not-found');
// assert.strictEqual(err.message, 'Token not found');
// done();
// });
// });

// it('calls onStrategyDone when a strategy completes', function (done) {
// const { sandbox, threeDSecure } = this;
// const example = { arbitrary: 'test-payload' };
// sandbox.spy(threeDSecure, 'onStrategyDone');

// threeDSecure.whenReady(() => {
// threeDSecure.strategy.emit('done', example);
// assert(threeDSecure.onStrategyDone.calledOnce);
// assert(threeDSecure.onStrategyDone.calledWithMatch(example));
// done();
// });
// });
// });

describe('challengeWindowSize', function() {
it('validates', function () {
const challengeWindowSize = 'xx';
Expand Down

0 comments on commit 01d4aa2

Please sign in to comment.