chore: update travis

This commit is contained in:
Vasco Santos 2021-04-07 11:41:08 +02:00
parent 3061d4751e
commit 99a405d331
5 changed files with 17 additions and 9 deletions

View File

@ -1,3 +0,0 @@
module.exports = {
bundlesize: { maxSize: '124kB' }
}

View File

@ -1,15 +1,19 @@
language: node_js
cache: npm
branches:
only:
- master
- /^release\/.*$/
stages:
- check
- test
- cov
node_js:
- '12'
- '14'
- 'lts/*'
- 'node'
os:
- linux
@ -23,7 +27,7 @@ jobs:
include:
- stage: check
script:
- npx aegir build --bundlesize
- npx aegir build --no-types
- npx aegir dep-check
- npm run lint

View File

@ -18,7 +18,7 @@
],
"scripts": {
"lint": "aegir lint",
"build": "npm run build:proto && aegir build",
"build": "npm run build:proto && aegir build --no-types",
"build:proto": "pbjs -t static-module -w commonjs --force-number --no-verify --no-delimited --no-create --no-beautify --no-defaults --lint eslint-disable -o src/keys/keys.js ./src/keys/keys.proto",
"test": "aegir test",
"test:node": "aegir test -t node",
@ -67,6 +67,11 @@
"sinon": "^10.0.0",
"util": "^0.12.3"
},
"aegir": {
"build": {
"bundlesizeMax": "118kB"
}
},
"engines": {
"node": ">=12.0.0"
},

View File

@ -20,7 +20,7 @@ const ErrMissingSecp256K1 = {
code: 'ERR_MISSING_PACKAGE'
}
function typeToKey(type) {
function typeToKey (type) {
const key = supportedKeys[type.toLowerCase()]
if (!key) {
const supported = Object.keys(supportedKeys).join(' / ')

View File

@ -1,3 +1,5 @@
syntax = "proto3";
enum KeyType {
RSA = 0;
Ed25519 = 1;