Skip to content

Commit

Permalink
Merge pull request #413 from GridPlus/dl/modularclient
Browse files Browse the repository at this point in the history
  • Loading branch information
douglance authored Jul 5, 2022
2 parents 6e76260 + c633a39 commit 0af6532
Show file tree
Hide file tree
Showing 106 changed files with 48,905 additions and 33,384 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,8 @@ jobs:
- name: Run linter
run: npm run lint

- name: Run tests
run: npm run test

- name: Build project
run: npm run build

# TODO: Separate the tests that can be run without a lattice
# and run those tests here.
# - name: Run tests
# run: npm run test
111 changes: 66 additions & 45 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -1,78 +1,99 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "test-all",
"type": "node",
"args": ["run", "${relativeFile}"],
"autoAttachChildProcesses": true,
"console": "integratedTerminal",
"name": "Debug Current Test File",
"program": "${workspaceRoot}/node_modules/vitest/vitest.mjs",
"request": "launch",
"skipFiles": ["<node_internals>/**", "**/node_modules/**"],
"smartStep": true,
"type": "pwa-node"
},
{
"console": "integratedTerminal",
"cwd": "${workspaceFolder}",
"runtimeExecutable": "npm",
"runtimeArgs": ["run-script", "test"],
"envFile": "${workspaceFolder}/.env",
"console": "integratedTerminal"
"name": "Unit Tests - All",
"request": "launch",
"runtimeArgs": ["run-script", "test"],
"runtimeExecutable": "npm",
"type": "node"
},
{
"name": "test-btc",
"type": "node",
"request": "launch",
"console": "integratedTerminal",
"cwd": "${workspaceFolder}",
"runtimeExecutable": "npm",
"runtimeArgs": ["run-script", "test-btc"],
"envFile": "${workspaceFolder}/.env",
"console": "integratedTerminal"
"name": "E2E Tests - All",
"request": "launch",
"runtimeArgs": ["run-script", "e2e"],
"runtimeExecutable": "npm",
"type": "node"
},
{
"name": "test-eth-msg",
"type": "node",
"request": "launch",
"console": "integratedTerminal",
"cwd": "${workspaceFolder}",
"runtimeExecutable": "npm",
"runtimeArgs": ["run-script", "test-eth-msg"],
"envFile": "${workspaceFolder}/.env",
"console": "integratedTerminal"
"name": "E2E Tests - General",
"request": "launch",
"runtimeArgs": ["run-script", "e2e-gen"],
"runtimeExecutable": "npm",
"type": "node"
},
{
"name": "test-kv",
"type": "node",
"request": "launch",
"console": "integratedTerminal",
"cwd": "${workspaceFolder}",
"runtimeExecutable": "npm",
"runtimeArgs": ["run-script", "test-kv"],
"envFile": "${workspaceFolder}/.env",
"console": "integratedTerminal"
"name": "E2E Tests - Bitcoin",
"request": "launch",
"runtimeArgs": ["run-script", "e2e-btc"],
"runtimeExecutable": "npm",
"type": "node"
},
{
"name": "test-non-exportable",
"type": "node",
"request": "launch",
"console": "integratedTerminal",
"cwd": "${workspaceFolder}",
"runtimeExecutable": "npm",
"runtimeArgs": ["run-script", "test-non-exportable"],
"envFile": "${workspaceFolder}/.env",
"console": "integratedTerminal"
"name": "E2E Tests - Signing",
"request": "launch",
"runtimeArgs": ["run-script", "e2e-sign"],
"runtimeExecutable": "npm",
"type": "node"
},
{
"name": "test-signing",
"type": "node",
"request": "launch",
"console": "integratedTerminal",
"cwd": "${workspaceFolder}",
"runtimeExecutable": "npm",
"runtimeArgs": ["run-script", "test-signing"],
"envFile": "${workspaceFolder}/.env",
"console": "integratedTerminal"
"name": "E2E Tests - Key-Value",
"request": "launch",
"runtimeArgs": ["run-script", "e2e-kv"],
"runtimeExecutable": "npm",
"type": "node"
},
{
"name": "test-wallet-jobs",
"type": "node",
"request": "launch",
"console": "integratedTerminal",
"cwd": "${workspaceFolder}",
"envFile": "${workspaceFolder}/.env",
"name": "E2E Tests - Non-Exportable Card",
"request": "launch",
"runtimeArgs": ["run-script", "e2e-ne"],
"runtimeExecutable": "npm",
"runtimeArgs": ["run-script", "test-wallet-jobs"],
"type": "node"
},
{
"console": "integratedTerminal",
"cwd": "${workspaceFolder}",
"envFile": "${workspaceFolder}/.env",
"console": "integratedTerminal"
"name": "E2E Tests - Wallet Jobs",
"request": "launch",
"runtimeArgs": ["run-script", "e2e-wj"],
"runtimeExecutable": "npm",
"type": "node"
}
]
],
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0"
}
2 changes: 1 addition & 1 deletion docs/docs/testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ The following options can be used after `env` with any test.
| `REUSE_KEY` | Must be `1` | Indicates we will be creating a new pairing with a Lattice and stashing that connection |
| `DEVICE_ID` | A six character string | The device ID of the target Lattice |
| `name` | Any 5-25 character string (default="SDK Test") | The name of the pairing you will create |
| `baseUrl` | Any URL (default="https://signing.gridplus.io") | URL describing where to send HTTP requests. Should be changed if your Lattice is on non-default message routing infrastructure. |
| `baseUrl` | Any URL (default="https://signing.gridpl.us") | URL describing where to send HTTP requests. Should be changed if your Lattice is on non-default message routing infrastructure. |

## Setting up the `.env` file

Expand Down
2 changes: 1 addition & 1 deletion docs/docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const config = {
{
entryPoints: ['../src'],
entryPointStrategy: 'expand',
exclude: [...excludedFiles, '../src/types/**'],
exclude: [...excludedFiles, '../src/types/**', '**/__test__/**'],
tsconfig: '../tsconfig.json',
watch: process.env.TYPEDOC_WATCH,
excludeInternal: true,
Expand Down
Loading

0 comments on commit 0af6532

Please sign in to comment.