test, docs: Add a linter for testing markdown, and fix up our docs

While writing docs, I couldn't remember what the correct style was
supposed to be, and I remember someone complaining about this
previously, so I decided to add a linter! I excluded a bunch of annoying
style rules, but if we find more we can add those to the list too.

Hopefully this gives us a more consistent feel throughout.
This commit is contained in:
James Shubin
2018-02-21 22:11:03 -05:00
parent 837388ae4e
commit cffdb06181
18 changed files with 313 additions and 44 deletions

View File

@@ -1,12 +1,18 @@
# Development
This document contains some additional information and help regarding developing `mgmt`. Useful tools, conventions, etc.
This document contains some additional information and help regarding
developing `mgmt`. Useful tools, conventions, etc.
Be sure to read [quick start guide](docs/quick-start-guide.md) first.
## Testing
This project has both unit tests in the form of golang tests and integration tests using shell scripting.
Native golang tests are preferred over tests written in our shell testing framework. Please see https://golang.org/pkg/testing/ for more information.
This project has both unit tests in the form of golang tests and integration
tests using shell scripting.
Native golang tests are preferred over tests written in our shell testing
framework. Please see [https://golang.org/pkg/testing/](https://golang.org/pkg/testing/)
for more information.
To run all tests:
@@ -14,9 +20,13 @@ To run all tests:
make test
```
There is a library of quick and small integration tests for the language and YAML related things, check out [`test/shell/`](/test/shell). Adding a test is as easy as copying one of the files in [`test/shell/`](/test/shell) and adapting it.
There is a library of quick and small integration tests for the language and
YAML related things, check out [`test/shell/`](/test/shell). Adding a test is as
easy as copying one of the files in [`test/shell/`](/test/shell) and adapting
it.
This test suite won't run by default (unless when on CI server) and needs to be called explictly using:
This test suite won't run by default (unless when on CI server) and needs to be
called explictly using:
```
make test-shell
@@ -28,4 +38,5 @@ Or run an individual shell test using:
make test-shell-load0
```
Tip: you can use TAB completion with `make` to quickly get a list of possible individual tests to run.
Tip: you can use TAB completion with `make` to quickly get a list of possible
individual tests to run.