-
Notifications
You must be signed in to change notification settings - Fork 2
/
circle.yml
85 lines (84 loc) · 4.08 KB
/
circle.yml
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
85
dependencies:
pre:
- "[ -d ~/maps ] || mkdir ~/maps"
- wget -c -O ~/maps/europe-belgium.bin https://769-32646075-gh.circle-artifacts.com/0/tmp/circle-artifacts.ZNELIQ8/europe-belgium.bin
- wget -c -O ~/maps/europe-france.bin https://767-32646075-gh.circle-artifacts.com/0/tmp/circle-artifacts.sJikzpP/europe-france.bin
- wget -c -O ~/maps/us-west.bin https://772-32646075-gh.circle-artifacts.com/0/tmp/circle-artifacts.9SaS25u/us-west.bin
- sudo apt-get update > /dev/null 2> /dev/null
- sudo apt-get install cmake
- sudo apt-get install libpng12-dev
# - sudo apt-get install libgtk2.0-dev
- sudo apt-get install librsvg2-bin
- sudo apt-get install libfreetype6-dev
- sudo apt-get install libdbus-glib-1-dev
- sudo apt-get install g++
- sudo pip install pyyaml
- sudo pip install junit-xml
- git clone https://github.com/navit-gps/navit.git
- git checkout $CIRCLE_BRANCH:
pwd: navit/
- mkdir bin
- cmake ../navit -Dgraphics/qt_qpainter:BOOL=FALSE -Dgui/qml:BOOL=FALSE:
pwd: bin
- make -j32:
pwd: bin
cache_directories:
- "~/assets/"
test:
post:
- sed -i -e 's@name="Local GPS" profilename="car" enabled="yes" active="1"@name="Local GPS" profilename="car" enabled="no" active="0"@' navit.xml:
pwd: bin/navit/
- sed -i -e 's@name="Demo" profilename="car" enabled="no" active="yes"@name="Demo" profilename="car" enabled="yes" active="yes" refresh="1"@' navit.xml:
pwd: bin/navit/
- sed -i -e 's@type="internal" enabled@type="internal" fullscreen="1" font_size="350" enabled@' navit.xml:
pwd: bin/navit/
- sed -i -e 's@libbinding_dbus.so" active="no"@libbinding_dbus.so" active="yes"@' navit.xml:
pwd: bin/navit/
- sed -i -e 's@name="Car" nightlayout="Car-dark"@name="Car"@' navit.xml:
pwd: bin/navit/
# FIXME : maps should be defined in the yaml and managed via the python script
- echo '<map type="binfile" data="~/maps/us-west.bin" />' > maps/us-west.xml:
pwd: bin/navit/
- echo '<map type="binfile" data="~/maps/europe-austria.bin" />' > maps/austria.xml:
pwd: bin/navit/
- echo '<map type="binfile" data="~/maps/europe-belgium.bin" />' > maps/belgium.xml:
pwd: bin/navit/
- echo '<map type="binfile" data="~/maps/europe-france.bin" />' > maps/france.xml:
pwd: bin/navit/
- echo '<map type="binfile" data="~/maps/europe-germany.bin" />' > maps/germany.xml:
pwd: bin/navit/
- echo '<map type="binfile" data="~/maps/europe-italy.bin" />' > maps/italy.xml:
pwd: bin/navit/
- echo '<map type="binfile" data="~/maps/europe-lithuania.bin" />' > maps/lithuania.xml:
pwd: bin/navit/
- echo '<map type="binfile" data="~/maps/europe-netherlands.bin" />' > maps/netherlands.xml:
pwd: bin/navit/
- echo '<map type="binfile" data="~/maps/europe-poland.bin" />' > maps/poland.xml:
pwd: bin/navit/
- echo '<map type="binfile" data="~/maps/europe-spain.bin" />' > maps/spain.xml:
pwd: bin/navit/
- echo '<map type="binfile" data="~/maps/europe-switzerland.bin" />' > maps/switzerland.xml:
pwd: bin/navit/
- echo 'navit.mapset.map[@description=="Navigation"].active=1;' > gui_internal.txt:
pwd: bin/navit/
- ./navit:
pwd: bin/navit/
background: true
- python test.py $CIRCLE_ARTIFACTS $CIRCLE_TEST_REPORTS "metric"
- dbus-send --print-reply --session --dest=org.navit_project.navit /org/navit_project/navit/default_navit org.navit_project.navit.navit.quit
- sed -i -e 's/navit center=/navit imperial="1" center=/' navit.xml:
pwd: bin/navit/
- ./navit:
pwd: bin/navit/
background: true
- python test.py $CIRCLE_ARTIFACTS $CIRCLE_TEST_REPORTS "imperial"
- dbus-send --print-reply --session --dest=org.navit_project.navit /org/navit_project/navit/default_navit org.navit_project.navit.navit.quit
deployment:
publish_tests_results:
branch: gh-tests
owner: navit-gps
commands:
- git checkout -b gh-pages
- cp $CIRCLE_ARTIFACTS/test.md index.md
- git add index.md
- git push