Skip to content

Commit 15dae9f

Browse files
committed
enhance CI
1 parent fd2fcb3 commit 15dae9f

File tree

2 files changed

+19
-13
lines changed

2 files changed

+19
-13
lines changed

Makefile

+18-13
Original file line numberDiff line numberDiff line change
@@ -102,51 +102,50 @@ diff_pylint_report: pylint_report.txt
102102
diff-quality --violations=pylint pylint_report.txt
103103

104104
.coverage: $(PYSOURCES)
105-
python-coverage run --branch --source=${MODULE} tests/test_examples.py
106-
python-coverage run --append --branch --source=${MODULE} \
105+
coverage run --branch --source=${MODULE} setup.py test
106+
coverage run --append --branch --source=${MODULE} \
107107
-m schema_salad.main \
108108
--print-jsonld-context schema_salad/metaschema/metaschema.yml \
109109
> /dev/null
110-
python-coverage run --append --branch --source=${MODULE} \
110+
coverage run --append --branch --source=${MODULE} \
111111
-m schema_salad.main \
112112
--print-rdfs schema_salad/metaschema/metaschema.yml \
113113
> /dev/null
114-
python-coverage run --append --branch --source=${MODULE} \
114+
coverage run --append --branch --source=${MODULE} \
115115
-m schema_salad.main \
116116
--print-avro schema_salad/metaschema/metaschema.yml \
117117
> /dev/null
118-
python-coverage run --append --branch --source=${MODULE} \
118+
coverage run --append --branch --source=${MODULE} \
119119
-m schema_salad.main \
120120
--print-rdf schema_salad/metaschema/metaschema.yml \
121121
> /dev/null
122-
python-coverage run --append --branch --source=${MODULE} \
122+
coverage run --append --branch --source=${MODULE} \
123123
-m schema_salad.main \
124124
--print-pre schema_salad/metaschema/metaschema.yml \
125125
> /dev/null
126-
python-coverage run --append --branch --source=${MODULE} \
126+
coverage run --append --branch --source=${MODULE} \
127127
-m schema_salad.main \
128128
--print-index schema_salad/metaschema/metaschema.yml \
129129
> /dev/null
130-
python-coverage run --append --branch --source=${MODULE} \
130+
coverage run --append --branch --source=${MODULE} \
131131
-m schema_salad.main \
132132
--print-metadata schema_salad/metaschema/metaschema.yml \
133133
> /dev/null
134-
python-coverage run --append --branch --source=${MODULE} \
134+
coverage run --append --branch --source=${MODULE} \
135135
-m schema_salad.makedoc schema_salad/metaschema/metaschema.yml \
136136
> /dev/null
137137

138-
139138
coverage.xml: .coverage
140-
python-coverage xml
139+
coverage xml
141140

142141
coverage.html: htmlcov/index.html
143142

144143
htmlcov/index.html: .coverage
145-
python-coverage html
144+
coverage html
146145
@echo Test coverage of the Python code is now in htmlcov/index.html
147146

148147
coverage-report: .coverage
149-
python-coverage report
148+
coverage report
150149

151150
diff-cover: coverage-gcovr.xml coverage.xml
152151
diff-cover coverage-gcovr.xml coverage.xml
@@ -174,4 +173,10 @@ mypy: ${PYSOURCES}
174173
MYPYPATH=typeshed/2.7 mypy --py2 schema_salad
175174
#MYPYPATH=typeshed/2.7 mypy --py2 --disallow-untyped-calls schema_salad
176175

176+
jenkins:
177+
if ! test -d env ; then virtualenv env ; fi
178+
. env/bin/activate ; \
179+
${MAKE} install-dep coverage.html coverage.xml mypy pep257_report.txt \
180+
sloccount.sc pep8_report.txt pylint_report.txt
181+
177182
FORCE:

schema_salad/makedoc.py

+1
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ class MyRenderer(mistune.Renderer):
4444

4545
def __init__(self): # type: () -> None
4646
super(mistune.Renderer, self).__init__()
47+
self.options = {}
4748

4849
def header(self, text, level, raw=None):
4950
return """<h%i id="%s">%s</h%i>""" % (level, to_id(text), text, level)

0 commit comments

Comments
 (0)