<commit_before>// require("babel-polyfill");
var expect = require('chai').expect;
var td = require('testdouble')

const WebCrypto = require('node-webcrypto-ossl');
const webcrypto = new WebCrypto();
global.crypto = webcrypto;

const { Jose, JoseJWE } = require('jose-jwe-jws');

const myLib = require('../dist/index');
console.log(myLib);
const { adder } = myLib({Jose, JoseJWE});
// const { jwk2cryptoKey, transformData, adder } = myLib({Jose, JoseJWE});

const jwk = {
  kty: 'RSA',
  e: 'AQAB',
  x5t: '<KEY>',
  kid: '<KEY>',
  x5c: [
    {}
  ],
  n: '<KEY>'
}
const testData = JSON.stringify({
  bla: 'hi',
  blub: 5,
});

describe('adder', function () {
  it('should calculate the sum of 2 numbers', function () {
    expect(adder(3,5)).to.equal(8);
  });
});

// describe.skip('asb-jwk', function () {
//   describe('jwk2cryptoKey', function () {
//     it('should be a function', function () {
//       expect(jwk2cryptoKey).to.be.a('function');
//     });
//     it('should return object', async function () {
//       const ck = await jwk2cryptoKey(jwk);
//       expect(ck).to.be.a('object');
//     });
//   });
//   describe('transformData', function () {
//     it('should be a function', function () {
//       expect(transformData).to.be.a('function');
//     });
//     it('should return object with required properties', async function () {
//       const ck = await jwk2cryptoKey(jwk);
//       ck.usages.push('encrypt');
//       console.log(ck);
//       const transformedData = await transformData(testData, ck);
//       console.log(transformedData);
//       expect(transformedData).to.be.a('object');
//       expect(transformedData).to.have.property('jwe');
//       expect(transformedData).to.have.property('data');
//     })
//   });
// });
<commit_msg>test(uncommented native npm package):<commit_after>// require("babel-polyfill");
var expect = require('chai').expect;
var td = require('testdouble')

// const WebCrypto = require('node-webcrypto-ossl');
// const webcrypto = new WebCrypto();
// global.crypto = webcrypto;

// const { Jose, JoseJWE } = require('jose-jwe-jws');

const myLib = require('../dist/index');
// const { adder } = myLib({Jose, JoseJWE});
const { adder } = myLib();
// const { jwk2cryptoKey, transformData, adder } = myLib({Jose, JoseJWE});

const jwk = {
  kty: 'RSA',
  e: 'AQAB',
  x5t: 'jeylBXdohTJCn6a87uvMHj-p7_k',
  kid: 'imdznevy-3vujwmkq7vyrgwhubzrm3-<KEY>',
  x5c: [
    {}
  ],
  n: '<KEY>'
}
const testData = JSON.stringify({
  bla: 'hi',
  blub: 5,
});

describe('adder', function () {
  it('should calculate the sum of 2 numbers', function () {
    expect(adder(3,5)).to.equal(8);
  });
});

// describe.skip('asb-jwk', function () {
//   describe('jwk2cryptoKey', function () {
//     it('should be a function', function () {
//       expect(jwk2cryptoKey).to.be.a('function');
//     });
//     it('should return object', async function () {
//       const ck = await jwk2cryptoKey(jwk);
//       expect(ck).to.be.a('object');
//     });
//   });
//   describe('transformData', function () {
//     it('should be a function', function () {
//       expect(transformData).to.be.a('function');
//     });
//     it('should return object with required properties', async function () {
//       const ck = await jwk2cryptoKey(jwk);
//       ck.usages.push('encrypt');
//       console.log(ck);
//       const transformedData = await transformData(testData, ck);
//       console.log(transformedData);
//       expect(transformedData).to.be.a('object');
//       expect(transformedData).to.have.property('jwe');
//       expect(transformedData).to.have.property('data');
//     })
//   });
// });

{'fraction_non_alphanumeric': 0.20802620802620803, 'fraction_numerical': 0.008463008463008462, 'mean_word_length': 3.0441501103752757, 'pattern_counts': {'":': 0, '<': 8, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '185692', 'n_tokens_mistral': 1298, 'n_tokens_neox': 1245, 'n_words': 239}