9 Commits

Author SHA1 Message Date
Deimos
79072f76d8 Rename invoke tasks to standardize format
I think this is going to be a better way to name invoke tasks. The
previous naming where a verb was often first made it much harder for
anyone to figure out the name of a task that affects a certain thing
without always looking through the entire list.

For example, if someone is looking for a task that affects the web
server, it's much easier to find web-server-reload than
reload-web-server.

The changes were:

- check-code-style -> code-style-check
- reload-web-server -> web-server-reload
- renew-tls-certificate -> tls-certificate-renew
- type-checking -> type-check
- update-pip-requirements -> pip-requirements-update
2020-11-03 18:09:36 -07:00
Deimos
9652dfb722 Add --full flag to invoke test
This is simpler than needing to know that --html-validation is the flag
to use to make sure that all tests are run, and can stay constant even
if we add other types of excluded-by-default tests in the future.
2020-10-09 19:16:04 -06:00
Deimos
ffde9f29a1 Use invoke tasks in git pre-push/pre-commit hooks 2020-10-07 15:25:04 -06:00
Deimos
036d46d589 Add marks to slower tests and don't run by default
This uses pytest's "markers" system to add markers to two special types
of tests:

* webtest - ones that use the WebTest library and are testing the actual
  HTTP app, instead of executing code/functions directly
* html_validation - ones that are generating HTML output (via webtest)
  and running it through the Nu HTML Checker to validate it.

The "webtest" marker is added automatically by checking whether a test
uses either of the webtest fixtures, and the html_validation one is
currently added manually to the only module that has those tests. In the
future, we could probably put HTML validation tests in their own folder
and mark them automatically based on the module's path or something
similar.

This also changes the default arguments for pytest to exclude these two
marked types of tests, and updates the git hooks so that webtests are
run pre-commit (but not HTML validation), and all tests are run
pre-push. Similar to the way we use prospector, this makes it so that
the very slow tests are only run before pushing.
2020-08-03 14:37:08 -06:00
Deimos
5eecb189ac Update mypy to 0.730
There are some new capabilities in mypy 0.730, including nicer output
formatting, which this enables. I'd also like to be able to use the
specific error-code ignoring instead of the current all-encompassing
"type: ignore" comments, but there's currently an issue with that:
https://github.com/python/mypy/issues/7562
2019-09-26 12:10:49 -06:00
Deimos
5ea8b3a1bd Add ESLint/Prettier and stylelint to git hooks 2019-06-03 18:25:13 -06:00
Chad Birch
d170962204 Replace Pylama with Prospector
Pylama is no longer maintained, and has been gradually getting slower
and slower, as well as being incompatible with Python 3.7 and newer
versions of astroid and pylint. This replaces it with Prospector, which
is being maintained by the same group as pylint and some other code
quality tools.
2018-08-29 19:28:27 -06:00
Deimos
1a2b5a8593 Add Black format check to git hooks 2018-08-13 14:33:31 -06:00
Deimos
e980ab3bda Initial open-source release 2018-07-17 13:39:29 -06:00