Skip to content

Commit

Permalink
chore: Update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
wsdt committed Apr 29, 2024
1 parent ca855c1 commit b50b493
Show file tree
Hide file tree
Showing 11 changed files with 5,031 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs

name: Run tests

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

jobs:
build:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [18.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm i
- run: npm test
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
node_modules
build
dist
.idea

/coverage/lcov-report
/coverage/coverage-summary.json
/coverage/lcov.info
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
# aws-kms
Generic AWS KMS Signing library supporting a variety of networks (incl. with strict replay protection).

## Testing
Right now this package is being tested in the LightBridge repository.
24 changes: 24 additions & 0 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
const { defaults } = require('jest-config')

/** @type {import('jest').Config} */
const config = {
moduleFileExtensions: [
...defaults.moduleFileExtensions,
'mts',
'cts',
'd.ts',
],
preset: 'ts-jest',
testEnvironment: 'node',
transform: {
'node_modules/variables/.+\\.(j|t)sx?$': 'ts-jest',
},
transformIgnorePatterns: ['node_modules/(?!variables/.*)'],
coverageReporters: [
"json-summary",
"text",
"lcov"
]
}

module.exports = config
48 changes: 48 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{
"name": "@bobanetwork/aws-kms",
"version": "1.0.0",
"description": "AWS KMS signing library with strict replay protection support.",
"main": "./dist/index.js",
"types": "./dist/index.d.ts",
"files": [
"dist"
],
"scripts": {
"build": "tsup",
"test": "jest",
"test:coverage": "npm test -- --coverage --collectCoverageFrom='src/**/*.ts' && jest-coverage-badges"
},
"repository": {
"type": "git",
"url": "git+https://github.com/bobanetwork/aws-kms.git"
},
"author": "Enya Labs",
"license": "MIT",
"bugs": {
"url": "https://github.com/bobanetwork/aws-kms/issues"
},
"homepage": "https://github.com/bobanetwork/aws-kms#readme",
"dependencies": {
"@aws-sdk/client-kms": "3.363.0",
"@bobanetwork/light-bridge-chains": "1.1.2",
"@ethereumjs/common": "3.2.0",
"@ethereumjs/tx": "4.2.0",
"@ethersproject/keccak256": "5.7.0",
"@ethersproject/providers": "^5.7.2",
"@types/jest": "^29.5.12",
"asn1.js": "5.4.1",
"bn.js": "5.2.1",
"ethereumjs-util": "7.1.5",
"ethers": "^5.5.4",
"node-fetch": "^2.6.1",
"ts-jest": "^29.1.2"
},
"devDependencies": {
"@types/node": "^16.18.62",
"@types/node-fetch": "^2.6.11",
"jest": "^29.7.0",
"jest-coverage-badges": "^1.1.2",
"tsup": "^8.0.2",
"typescript": "^5.4.2"
}
}
Loading

0 comments on commit b50b493

Please sign in to comment.