Skip to content

Commit

Permalink
update README.md regarding running tests
Browse files Browse the repository at this point in the history
[skip ci]
  • Loading branch information
marefr authored Feb 9, 2018
1 parent e672604 commit fae9eb5
Showing 1 changed file with 17 additions and 2 deletions.
19 changes: 17 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,11 @@ In your custom.ini uncomment (remove the leading `;`) sign. And set `app_mode =

### Running tests

- You can run backend Golang tests using "go test ./pkg/...".
- Execute all frontend tests with "npm run test"
#### Frontend
Execute all frontend tests
```bash
$ npm run test
```

Writing & watching frontend tests (we have two test runners)

Expand All @@ -92,6 +95,18 @@ Writing & watching frontend tests (we have two test runners)
- Start watcher: `npm run karma`
- Karma+Mocha runs all files that end with the name "_specs.ts".

#### Backend
```bash
# Run Golang tests using sqlite3 as database (default)
$ go test ./pkg/...

# Run Golang tests using mysql as database - convenient to use /docker/block/mysql_tests
$ GRAFANA_TEST_DB=mysql go test ./pkg/...

# Run Golang tests using postgres as database - convenient to use /docker/blocks/postgres_tests
$ GRAFANA_TEST_DB=postgres go test ./pkg/...
```

## Contribute

If you have any idea for an improvement or found a bug, do not hesitate to open an issue.
Expand Down

0 comments on commit fae9eb5

Please sign in to comment.