Skip to content

Commit eee14f1

Browse files
committed
add precommit and break out the requirements-test dependencies
1 parent 0d5ec9e commit eee14f1

File tree

4 files changed

+15
-12
lines changed

4 files changed

+15
-12
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ This is the repository for the BuildingSync Validator web application.
2424
```
2525
1. Install Django and associated requirements:
2626
```bash
27-
pip install -r requirements.txt
27+
pip install -r requirements-test.txt
2828
```
2929
1. Initialize the database:
3030
```bash

requirements-test.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
-r requirements.txt
2+

requirements.txt

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,12 @@ stopit==1.1.2
1010
xmlschema==1.0.15
1111
xmltodict==0.12.0
1212

13+
# string matching
14+
jellyfish==0.7.1
15+
16+
# schematron runner from TestSuite repo
17+
testsuite==0.1.3
18+
1319
# production deployment
1420
uWSGI==2.0.22
1521

@@ -18,9 +24,4 @@ autopep8==1.4.4
1824
coveralls==2.2.0
1925
coverage==5.0.1
2026
tox==3.14.1
21-
22-
# string matching
23-
jellyfish==0.7.1
24-
25-
# schematron runner from TestSuite repo
26-
testsuite==0.1.3
27+
pre-commit==3.4.0

tox.ini

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ exclude = .git,.tox,conf.py,structure.py,main/docker.py
66
[tox]
77
skipsdist = True
88
envlist =
9-
python,
9+
precommit,
1010
flake8
1111

1212
[testenv:python]
@@ -17,9 +17,9 @@ passenv=
1717
TRAVIS_JOB_ID
1818
TRAVIS_BRANCH
1919
commands = coverage run manage.py test
20-
deps = -r{toxinidir}/requirements.txt
20+
deps = -r{toxinidir}/requirements-test.txt
2121

22-
[testenv:flake8]
22+
[testenv:precommit]
2323
basepython = python
24-
deps = flake8
25-
commands = flake8 {toxinidir}
24+
commands = pre-commit run --all-files
25+
deps = -r{toxinidir}/requirements-test.txt

0 commit comments

Comments
 (0)