Skip to content

Commit

Permalink
Merge pull request #11 from solid/update-deps
Browse files Browse the repository at this point in the history
Update dependencies
  • Loading branch information
michielbdejong authored Jul 29, 2020
2 parents a2e2b21 + b55a38c commit 2701c3c
Show file tree
Hide file tree
Showing 8 changed files with 1,379 additions and 1,412 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ sudo: false

language: node_js

node_js: "8.10"
node_js: "12"

script: npm run test
2,743 changes: 1,339 additions & 1,404 deletions package-lock.json

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"build-dist": "webpack --progress",
"dist": "npm run build-dist",
"prepare": "npm run build-dist",
"test": "mocha test",
"test": "mocha --recursive test",
"jsdoc": "jsdoc -c jsdoc.json -r"
},
"repository": {
Expand Down Expand Up @@ -46,16 +46,16 @@
"dependencies": {
"@sinonjs/text-encoding": "^0.7.1",
"base64url": "^3.0.1",
"isomorphic-webcrypto": "^2.3.2"
"isomorphic-webcrypto": "^2.3.6"
},
"devDependencies": {
"babel-cli": "^6.26.0",
"babel-preset-env": "^1.7.0",
"chai": "^4.2.0",
"chai-as-promised": "^7.1.1",
"dirty-chai": "^2.0.1",
"mocha": "^6.2.2",
"webpack": "^4.41.2",
"webpack-cli": "^3.3.10"
"mocha": "^8.0.1",
"webpack": "^4.44.0",
"webpack-cli": "^3.3.12"
}
}
2 changes: 1 addition & 1 deletion src/algorithms/RSASSA-PKCS1-v1_5.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @ignore
*/
const base64url = require('base64url')
const crypto = require('isomorphic-webcrypto')
let crypto = require('../crypto')
const TextEncoder = require('../text-encoder')

/**
Expand Down
3 changes: 3 additions & 0 deletions src/crypto.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
const imported = require('isomorphic-webcrypto')

module.exports = (imported.default ? imported.default : imported)
2 changes: 2 additions & 0 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
/**
* @module JSON Object Signing and Encryption (JOSE)
*/
const crypto = require('./crypto')
const JWA = require('./jose/JWA')
const JWK = require('./jose/JWK')
const JWKSet = require('./jose/JWKSet')
Expand All @@ -11,6 +12,7 @@ const JWS = require('./jose/JWS')
* Export
*/
module.exports = {
crypto,
JWA,
JWK,
JWKSet,
Expand Down
28 changes: 28 additions & 0 deletions test/cryptoSpec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
'use strict'

/**
* Test dependencies
*/
const chai = require('chai')
const chaiAsPromised = require('chai-as-promised')

/**
* Assertions
*/
chai.should()
chai.use(chaiAsPromised)
let expect = chai.expect

/**
* Code under test
*/
const Index = require('../src/')

/**
* Tests
*/
describe('Index', () => {
it('exports crypto', () => {
return Object.keys(Index.crypto).should.deep.equal(['subtle'])
})
})
1 change: 0 additions & 1 deletion test/mocha.opts

This file was deleted.

0 comments on commit 2701c3c

Please sign in to comment.