3 on: [ push, pull_request ]
19 - uses: actions/checkout@v2
24 uses: shivammathur/setup-php@v2
32 echo "::set-output name=date::$(/bin/date -u "+%Y%W")"
35 - uses: actions/cache@v2
38 {{ github.workspace }}/data/country_osm_grid.sql.gz
39 {{ github.workspace }}/monaco-latest.osm.pbf
40 key: nominatim-data-${{ steps.get-date.outputs.date }}
42 - uses: ./.github/actions/setup-postgresql
44 postgresql-version: ${{ matrix.postgresql }}
45 postgis-version: ${{ matrix.postgis }}
46 - uses: ./.github/actions/build-nominatim
48 - name: Install test prerequsites
49 run: sudo apt-get install -y -qq php-codesniffer pylint python3-pytest python3-behave
52 run: phpcs --report-width=120 .
54 - name: Python linting
57 - name: PHP unit tests
59 working-directory: test/php
61 - name: Python unit tests
62 run: pytest test/python
65 run: behave -DREMOVE_TEMPLATE=1 --format=progress3
66 working-directory: test/bdd
72 - uses: actions/checkout@v2
79 echo "::set-output name=date::$(/bin/date -u "+%Y%W")"
82 - uses: actions/cache@v2
85 {{ github.workspace }}/data/country_osm_grid.sql.gz
86 {{ github.workspace }}/monaco-latest.osm.pbf
87 key: nominatim-data-${{ steps.get-date.outputs.date }}
89 - uses: ./.github/actions/setup-postgresql
91 postgresql-version: 13
93 - uses: ./.github/actions/build-nominatim
95 - name: Create configuration
97 echo "NOMINATIM_PYOSMIUM_BINARY=/usr/lib/python3-pyosmium/pyosmium-get-changes" >> .env
98 working-directory: build
100 - name: Download import data
102 if [ ! -f monaco-latest.osm.pbf ]; then
103 wget --no-verbose https://download.geofabrik.de/europe/monaco-latest.osm.pbf
108 run: ./nominatim import --osm-file ../monaco-latest.osm.pbf
109 working-directory: build
111 - name: Import special phrases
112 run: ./nominatim special-phrases --from-wiki | psql -d nominatim
113 working-directory: build
116 run: ./nominatim check-database
117 working-directory: build
121 ./nominatim replication --init
122 ./nominatim replication --once
123 working-directory: build
125 - name: Run reverse-only import
128 php ./nominatim import --osm-file ../monaco-latest.osm.pbf --reverse-only
129 working-directory: build