Skip to content

Commit

Permalink
Add tests, first dummy test
Browse files Browse the repository at this point in the history
  • Loading branch information
ProfMoo committed Dec 4, 2024
1 parent a5d06f9 commit 834732c
Show file tree
Hide file tree
Showing 9 changed files with 1,187 additions and 21 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ jobs:
with:
node-version: "20.x"
registry-url: "https://registry.npmjs.org"
- run: npm ci
- name: Run npm ci
run: npm ci
- name: Run linter
run: npm run lint
25 changes: 25 additions & 0 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: TypeScript Test

on:
push:
branches:
- "**" # This will trigger the workflow on every push to any branch
pull_request:

permissions:
contents: read

jobs:
lint:
name: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20.x"
registry-url: "https://registry.npmjs.org"
- name: Run npm ci
run: npm ci
- name: Run tests
run: npm run test
3 changes: 0 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,4 @@ dist/

node_modules/

# VSCode configuration
.vscode

docs/**/*.json
6 changes: 6 additions & 0 deletions .mocharc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"require": [
"ts-node/register"
],
"spec": "src/**/*.test.ts"
}
36 changes: 36 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"markdownlint.config": {
"MD033": false,
},
"editor.formatOnSave": true,
"editor.formatOnPaste": true,
"editor.formatOnType": false,
"files.autoSave": "onFocusChange",
"cSpell.words": [
"automerge",
"holesky",
"nonroutine",
"solana",
"txsigner",
"unstake"
],
"typescript.updateImportsOnFileMove.enabled": "always",
"javascript.updateImportsOnFileMove.enabled": "always",
"vs-code-prettier-eslint.prettierLast": false,
"[javascript]": {
"editor.defaultFormatter": "rvest.vs-code-prettier-eslint"
},
"[json]": {
"editor.defaultFormatter": "vscode.json-language-features"
},
"[jsonc]": {
"editor.defaultFormatter": "vscode.json-language-features"
},
"[typescript]": {
"editor.defaultFormatter": "rvest.vs-code-prettier-eslint"
},
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit"
},
"files.insertFinalNewline": true,
}
Loading

0 comments on commit 834732c

Please sign in to comment.