Skip to content

Commit c85fac1

Browse files
flexponsivebnfinet
authored andcommitted
docs: add instructions for running tests (on terminal / in vscode) to CONTRIBUTING.md
1 parent a047ce6 commit c85fac1

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

CONTRIBUTING.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,27 @@
1+
# Setting up a Development Environment
2+
3+
## Running Tests
4+
5+
```bash
6+
export VOUCH_ROOT=`pwd` # if not using GOPATH
7+
./do.sh test
8+
```
9+
10+
After running these tests manually once (which creates a test key pair), it is possible to run the tests with VSCode Test Explorer.
11+
12+
To get it to work, we must set some environment variables in `.vscode/settings.json` which otherwise would be set by `do.sh`:
13+
14+
```json
15+
{
16+
"go.testEnvVars": {
17+
"VOUCH_ROOT": "${workspaceFolder}",
18+
"VOUCH_CONFIG": "${workspaceFolder}/config/testing/test_config.yml",
19+
"TEST_PRIVATE_KEY_FILE": "${workspaceFolder}/config/testing/rsa.key",
20+
"TEST_PUBLIC_KEY_FILE": "${workspaceFolder}/config/testing/rsa.pub",
21+
}
22+
}
23+
```
24+
125
### Contributing to Vouch Proxy by submitting a Pull Request
226

327
**_I really love Vouch Proxy! I wish it did XXXX..._**

0 commit comments

Comments
 (0)