forked from ploneintranet/ploneintranet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
jenkins.cfg
84 lines (75 loc) · 2.12 KB
/
jenkins.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
[buildout]
extends =
buildout.d/base.cfg
buildout.d/quaive-eggs.cfg
buildout.d/solr.cfg
package-name = ${buildout:base-package-name}
package-extras = [solr,develop,test]
develop = .
extensions = mr.developer
always-checkout = true
parts +=
jenkins-test
flake8
code-analysis
createcoverage
coverage-report
allow-picked-versions = false
[instance]
http-address = 6680
event-log-custom =
<logfile>
path ${buildout:directory}/var/log/instance.log
level ERROR
</logfile>
[scripts]
eggs = ${buildout:package-name} ${buildout:package-extras}
[jenkins-test]
recipe = collective.recipe.template
input = inline:
#!/bin/bash
set -e
set -v
ps aux|grep ~$(whoami)
source bin/activate
# First we check for pep8 in case anyone
# decided to disable their pre-commit hooks ;)
bin/code-analysis
echo "Current settings for LC_CTYPE, LC_ALL, LANG:"
echo $LC_CTYPE
echo $LC_ALL
echo $LANG
export PATH=/opt/src/buildout.python/python-2.7/bin:$PATH
export LC_CTYPE=en_US.UTF-8
export LC_ALL=en_US.UTF-8
export LANG=en_US.UTF-8
export ROBOTSUITE_LOGLEVEL=ERROR
echo "Locale variables were set to:"
echo $LC_CTYPE
echo $LC_ALL
echo $LANG
echo $PATH
echo "ROBOTSUITE_LOGLEVEL was set to:"
echo $ROBOTSUITE_LOGLEVEL
firefox -v
# Run fastest diff tester - in dry-run mode for now
bin/fastest --dry-run
# Remove old results
echo "Erase old coverage results."
bin/coverage erase
# Collect test coverage results for all packages
echo "Run test coverage analysis for all packages."
bin/coverage run -p --source=src bin/test $@ || exit 1
echo "Create test coverage report."
# Combine all package analysis
bin/coverage combine
# Generates a "coverage.xml" file that Jenkins can read and process from the
# ".coverage" file that the coverage report created.
bin/coverage xml -i -o ${buildout:directory}/parts/test/coverage.xml
echo "Test coverage report finished."
deactivate
output = ${buildout:directory}/bin/jenkins-test
mode = 755
[coverage]
recipe = zc.recipe.egg
eggs = coverage