File tree 2 files changed +17
-1
lines changed 2 files changed +17
-1
lines changed Original file line number Diff line number Diff line change 6
6
strategy :
7
7
matrix :
8
8
python-version : [3.7, 3.8, 3.9]
9
+ node-version : [14.x, 15.x]
9
10
services :
10
11
redis :
11
12
image : redis
@@ -33,12 +34,18 @@ jobs:
33
34
with :
34
35
python-version : ${{ matrix.python-version }}
35
36
37
+ - name : Use Node.js ${{ matrix.node-version }}
38
+ uses : actions/setup-node@v2
39
+ with :
40
+ node-version : ${{ matrix.node-version }}
41
+
36
42
- name : Install dependencies & set up configuration
37
43
run : |
38
44
python -m pip install --upgrade pip
39
45
pip install -r requirements.txt
40
46
pip install pycodestyle coverage
41
47
ln -s configuration.testing.py netbox/netbox/configuration.py
48
+ yarn --cwd netbox/project-static
42
49
43
50
- name : Build documentation
44
51
run : mkdocs build
47
54
run : python netbox/manage.py collectstatic --no-input
48
55
49
56
- name : Check PEP8 compliance
50
- run : pycodestyle --ignore=W504,E501 netbox/
57
+ run : pycodestyle --ignore=W504,E501 --exclude=node_modules netbox/
58
+
59
+ - name : Check UI ESLint, TypeScript, and Prettier Compliance
60
+ run : yarn --cwd netbox/project-static validate
51
61
52
62
- name : Run tests
53
63
run : coverage run --source="netbox/" netbox/manage.py test netbox/
Original file line number Diff line number Diff line change @@ -34,6 +34,12 @@ if [ $? != 0 ]; then
34
34
EXIT=1
35
35
fi
36
36
37
+ echo " Checking UI ESLint, TypeScript, and Prettier compliance..."
38
+ yarn --cwd " $PWD /netbox/project-static" validate
39
+ if [ $? != 0 ]; then
40
+ EXIT=1
41
+ fi
42
+
37
43
if [ $EXIT != 0 ]; then
38
44
printf " ${RED} COMMIT FAILED${NOCOLOR} \n"
39
45
fi
You can’t perform that action at this time.
0 commit comments