Skip to content
Permalink
Browse files

bump Qt to 5.9 (#6482)

* Update test masks

* update test masks

* fix bad regex in parse_dash_results

* update test masks

* [Travis] bump Qt to 5.9  (#6355)

* bump Qt to 5.9 and SIP to 4.19.7 by using coming Bionic as base Docker image for dependencies
* automatically build QGIS Docker image on cron jobs

* update test mask
  • Loading branch information
3nids committed Feb 28, 2018
1 parent f60149b commit e82e52172a002feebde0fadb37b3bbb3480d5ddd
Showing with 114 additions and 70 deletions.
  1. +27 −7 .ci/travis/linux/before_script.sh
  2. +1 −0 .ci/travis/linux/docker-build-test.sh
  3. +17 −2 .ci/travis/linux/script.sh
  4. +0 −10 .docker/Dockerfile-build-test
  5. +46 −0 .docker/qgis.dockerfile
  6. +14 −8 .docker/{Dockerfile → qgis3-build-deps.dockerfile}
  7. +4 −1 .travis.yml
  8. +0 −38 Dockerfile
  9. +1 −0 python/plugins/processing/tests/testdata/gdal_algorithm_tests.yaml
  10. +1 −1 scripts/parse_dash_results.py
  11. +3 −3 tests/src/python/test_qgsdistancearea.py
  12. BIN ...a/control_images/annotations/expected_annotation_fillstyle/expected_annotation_fillstyle_mask.png
  13. BIN ...tdata/control_images/annotations/expected_annotation_margins/expected_annotation_margins_mask.png
  14. BIN tests/testdata/control_images/annotations/expected_html_annotation/expected_html_annotation_mask.png
  15. BIN ...s/testdata/control_images/annotations/expected_html_feature/travis/expected_html_feature_mask.png
  16. BIN ...stdata/control_images/annotations/expected_html_nofeature/travis/expected_html_nofeature_mask.png
  17. BIN tests/testdata/control_images/annotations/expected_relative_style/expected_relative_style_mask.png
  18. BIN tests/testdata/control_images/annotations/expected_svg_annotation/expected_svg_annotation_mask.png
  19. BIN ...ata/control_images/annotations/expected_text_annotation/default/expected_text_annotation_mask.png
  20. BIN .../control_images/composer_map/expected_layoutmap_rasterized/expected_layoutmap_rasterized_mask.png
  21. BIN tests/testdata/control_images/effects/expected_painteffect_blur/expected_painteffect_blur_mask.png
  22. BIN ...a/control_images/effects/expected_painteffect_dropshadow/expected_painteffect_dropshadow_mask.png
  23. BIN tests/testdata/control_images/effects/expected_painteffect_stack/expected_painteffect_stack_mask.png
  24. BIN .../testdata/control_images/expected_svgcache_changed_after/expected_svgcache_changed_after_mask.png
  25. BIN ...estdata/control_images/expected_svgcache_changed_before/expected_svgcache_changed_before_mask.png
  26. BIN tests/testdata/control_images/qgis_server/WMS_GetMap_Annotations/WMS_GetMap_Annotations_mask.png
  27. BIN tests/testdata/control_images/qgis_server/WMS_GetMap_Mode_1bit/WMS_GetMap_Mode_1bit_mask.png
  28. BIN tests/testdata/control_images/qgis_server/WMS_GetMap_Mode_8bit/WMS_GetMap_Mode_8bit_mask.png
  29. BIN tests/testdata/control_images/qgis_server/WMS_GetMap_StyleCustom/WMS_GetMap_StyleCustom_mask.png
  30. BIN tests/testdata/control_images/qgis_server/WMS_GetPrint_Basic/WMS_GetPrint_Basic_mask.png
  31. BIN tests/testdata/control_images/qgis_server/WMS_GetPrint_Grid/WMS_GetPrint_Grid_mask.png
  32. BIN tests/testdata/control_images/qgis_server/WMS_GetPrint_Highlight/WMS_GetPrint_Highlight_mask.png
  33. BIN .../testdata/control_images/qgis_server/WMS_GetPrint_LabelUpdated/WMS_GetPrint_LabelUpdated_mask.png
  34. BIN tests/testdata/control_images/qgis_server/WMS_GetPrint_Legend/WMS_GetPrint_Legend_mask.png
  35. BIN tests/testdata/control_images/qgis_server/WMS_GetPrint_Opacity/WMS_GetPrint_Opacity_mask.png
  36. BIN tests/testdata/control_images/qgis_server/WMS_GetPrint_Rotation/WMS_GetPrint_Rotation_mask.png
  37. BIN tests/testdata/control_images/qgis_server/WMS_GetPrint_Scale/WMS_GetPrint_Scale_mask.png
  38. BIN tests/testdata/control_images/qgis_server/WMS_GetPrint_Selection/WMS_GetPrint_Selection_mask.png
  39. BIN tests/testdata/control_images/qgis_server/WMS_GetPrint_StyleCustom/WMS_GetPrint_StyleCustom_mask.png
  40. BIN .../testdata/control_images/qgis_server/WMS_GetPrint_StyleDefault/WMS_GetPrint_StyleDefault_mask.png
@@ -17,24 +17,44 @@ set -e

pushd .docker

echo "travis_fold:start:docker"
echo "travis_fold:start:travis_env"
echo "${bold}${endbold}"
echo "TRAVIS_BRANCH $TRAVIS_BRANCH"
echo "TRAVIS_EVENT_TYPE $TRAVIS_EVENT_TYPE"
echo "DOCKER_TAG $DOCKER_TAG"
echo "DOCKER_DEPS_PUSH $DOCKER_DEPS_PUSH"
echo "DOCKER_DEPS_IMAGE_REBUILD $DOCKER_DEPS_IMAGE_REBUILD"
echo "DOCKER_QGIS_IMAGE_BUILD_PUSH $DOCKER_QGIS_IMAGE_BUILD_PUSH"
echo "QGIS_LAST_BUILD_SUCCESS $QGIS_LAST_BUILD_SUCCESS"
echo "travis_fold:end:travis_env"


echo "travis_fold:start:docker_build"
echo "${bold}Docker build deps${endbold}"
docker --version
docker-compose --version
docker-compose -f $DOCKER_COMPOSE config
#docker pull ubuntu:16.04
if [[ $DOCKER_QGIS_IMAGE_BUILD_PUSH =~ false ]]; then
docker-compose --version
docker-compose -f $DOCKER_COMPOSE config
fi

docker pull "qgis/qgis3-build-deps:${DOCKER_TAG}" || true
if [[ $DOCKER_DEPS_IMAGE_REBUILD =~ true ]]; then
docker build --no-cache -t "qgis/qgis3-build-deps:${DOCKER_TAG}" .
else
docker build --cache-from "qgis/qgis3-build-deps:${DOCKER_TAG}" -t "qgis/qgis3-build-deps:${DOCKER_TAG}" .
docker build --cache-from "qgis/qgis3-build-deps:${DOCKER_TAG}" -t "qgis/qgis3-build-deps:${DOCKER_TAG}" -f qgis3-build-deps.dockerfile .
fi
echo "travis_fold:end:docker"
echo "travis_fold:end:docker_build"

echo "travis_fold:start:docker_push"
echo "${bold}Docker push deps${endbold}"
# image should be pushed even if QGIS build fails
# but push is achieved only on branches (not for PRs)
if [[ $DOCKER_PUSH =~ true ]]; then
if [[ $DOCKER_DEPS_PUSH =~ true ]]; then
echo "push to qgis/qgis3-build-deps:${DOCKER_TAG}"
docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD"
#docker tag "qgis/qgis3-build-deps:${DOCKER_TAG}" "qgis/qgis3-build-deps:latest"
docker push "qgis/qgis3-build-deps:${DOCKER_TAG}"
fi
echo "travis_fold:end:docker_push"

popd
@@ -39,6 +39,7 @@ echo "travis_fold:start:cmake"
echo "${bold}Running cmake...${endbold}"
cmake \
-GNinja \
-DWITH_3D=ON \
-DWITH_STAGED_PLUGINS=ON \
-DWITH_GRASS=OFF \
-DSUPPRESS_QT_WARNINGS=ON \
@@ -15,8 +15,23 @@

set -e

DIR=$(git rev-parse --show-toplevel)/.docker


mkdir -p $CCACHE_DIR

docker-compose -f $DOCKER_COMPOSE run --rm qgis-deps
if [[ $DOCKER_QGIS_IMAGE_BUILD_PUSH =~ true ]]; then
DIR=$(git rev-parse --show-toplevel)/.docker
pushd ${DIR}
echo "${bold}Building QGIS Docker image '${DOCKER_TAG}'...${endbold}"
docker build --build-arg CACHE_DIR=/root/.ccache \
--build-arg DOCKER_TAG=${DOCKER_TAG} \
--cache-from "qgis/qgis:${DOCKER_TAG}" \
-t "qgis/qgis:${DOCKER_TAG}" \
-f qgis.dockerfile ..
echo "${bold}Pushing image to docker hub...${endbold}"
docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD"
docker push "qgis/qgis:${DOCKER_TAG}"
popd
else
docker-compose -f $DOCKER_COMPOSE run --rm qgis-deps
fi

This file was deleted.

@@ -0,0 +1,46 @@

# CACHE_TAG is provided by Docker cloud
# see https://docs.docker.com/docker-cloud/builds/advanced/
# using ARG in FROM requires min v17.05.0-ce
ARG DOCKER_TAG=latest
ARG CACHE_DIR

FROM qgis/qgis3-build-deps:${DOCKER_TAG}
MAINTAINER Denis Rouzaud <denis@opengis.ch>

ENV CC=/usr/lib/ccache/clang
ENV CXX=/usr/lib/ccache/clang++
ENV QT_SELECT=5
ENV LANG=C.UTF-8

COPY . /usr/src/QGIS

COPY ${CACHE_DIR} /root/.ccache
ENV CCACHE_DIR=/root/.ccache
RUN ccache -M 1G

WORKDIR /usr/src/QGIS/build

RUN cmake \
-GNinja \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DWITH_DESKTOP=OFF \
-DWITH_SERVER=ON \
-DWITH_3D=ON \
-DWITH_BINDINGS=ON \
-DBINDINGS_GLOBAL_INSTALL=ON \
-DWITH_STAGED_PLUGINS=ON \
-DWITH_GRASS=ON \
-DSUPPRESS_QT_WARNINGS=ON \
-DDISABLE_DEPRECATED=ON \
-DENABLE_TESTS=OFF \
-DWITH_QSPATIALITE=ON \
-DWITH_QWTPOLAR=OFF \
-DWITH_APIDOC=OFF \
-DWITH_ASTYLE=OFF \
.. \
&& ninja install \
&& rm -rf /usr/src/QGIS

WORKDIR /
@@ -1,18 +1,21 @@
FROM ubuntu:16.04
MAINTAINER Denis Rouzaud <denis.rouzaud@gmail.com>
FROM ubuntu:18.04
MAINTAINER Denis Rouzaud <denis@opengis.ch>

LABEL Description="Docker container with QGIS dependencies" Vendor="QGIS.org" Version="1.0"

# && echo "deb http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu xenial main" >> /etc/apt/sources.list \
# && echo "deb-src http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu xenial main" >> /etc/apt/sources.list \
# && apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 314DF160 \

RUN apt-get update \
&& apt-get install -y software-properties-common \
&& add-apt-repository ppa:ubuntugis/ubuntugis-unstable \
&& apt-get update \
&& apt-get install -y \
bison \
ca-certificates \
ccache \
clang \
# cmake \
cmake \
curl \
dh-python \
flex \
@@ -29,6 +32,7 @@ RUN apt-get update \
libproj-dev \
libqca-qt5-2-dev \
libqca-qt5-2-plugins \
libqt53drender5 \
libqt5opengl5-dev \
libqt5scintilla2-dev \
libqt5sql5-sqlite \
@@ -66,6 +70,11 @@ RUN apt-get update \
python3-sip-dev \
python3-termcolor \
python3-yaml \
qt3d5-dev \
qt3d-assimpsceneimport-plugin \
qt3d-defaultgeometryloader-plugin \
qt3d-gltfsceneio-plugin \
qt3d-scene2d-plugin \
qt5keychain-dev \
qtbase5-dev \
qtpositioning5-dev \
@@ -88,10 +97,7 @@ RUN apt-get update \
future \
termcolor \
&& apt-get autoremove -y python3-pip python2.7 \
&& apt-get clean \
&& curl -s -S -O https://cmake.org/files/v3.10/cmake-3.10.1-Linux-x86_64.tar.gz \
&& tar --strip-components=1 -zx -f cmake-3.10.1-Linux-x86_64.tar.gz -C /usr/local \
&& rm cmake-3.10.1-Linux-x86_64.tar.gz
&& apt-get clean

RUN echo "alias python=python3" >> ~/.bash_aliases

@@ -9,8 +9,11 @@ matrix:
- TRAVIS_CONFIG=linux
- DOCKER_COMPOSE=${TRAVIS_BUILD_DIR}/.docker/docker-compose.travis.yml
- DOCKER_TAG=$( [[ $TRAVIS_REPO_SLUG =~ qgis/QGIS ]] && echo $TRAVIS_BRANCH | sed 's/master/latest/' || echo "latest" )
- DOCKER_PUSH=$( [[ $TRAVIS_REPO_SLUG =~ qgis/QGIS ]] && [[ $TRAVIS_PULL_REQUEST =~ false ]] && echo "true" || echo "false" )
- DOCKER_DEPS_PUSH=$( [[ $TRAVIS_REPO_SLUG =~ qgis/QGIS ]] && [[ $TRAVIS_EVENT_TYPE =~ push ]] && echo "true" || echo "false" )
- DOCKER_DEPS_IMAGE_REBUILD=$( [[ $TRAVIS_COMMIT_MESSAGE =~ '[docker] update dependencies' ]] && echo "true" || echo "false" )
# on cron job, QGIS image is built and push without testing
- DOCKER_QGIS_IMAGE_BUILD_PUSH=$( [[ $TRAVIS_REPO_SLUG =~ qgis/QGIS ]] && [[ $TRAVIS_EVENT_TYPE =~ cron ]] && echo "true" || echo "false" )
- QGIS_LAST_BUILD_SUCCESS=true # TODO use API to know if last build succeed https://developer.travis-ci.com/resource/builds
- CCACHE_DIR=${HOME}/.ccache
dist: trusty
sudo: false

This file was deleted.

@@ -250,6 +250,7 @@ tests:
hash:
- aca7c839c679613f4910cbdea660359f1551c104c57fea9a61795668
- 57e2bc100ec9836e2aa7df4ccf6b5715bd3f3524a524ce47bec52f68
- e607570f34b1c61bc622751b324023b67642b657ef4b91a80d9057cb
type: rasterhash

- algorithm: gdal:gridnearestneighbor
@@ -159,7 +159,7 @@ def parse_url(self, url):

images = {}
for img in measurement_img:
m = re.search('Rendered Image (.*?)\s', img.get('alt'))
m = re.search('Rendered Image (.*?)(\s|$)', img.get('alt'))
test_name = m.group(1)
rendered_image = img.get('src')
images[test_name] = '{}/{}'.format(dash_url, rendered_image)
@@ -600,18 +600,18 @@ def testFormatDistance(self):
self.assertEqual(QgsDistanceArea.formatDistance(1.5, 3, QgsUnitTypes.DistanceKilometers, False), '1.500 km')
self.assertEqual(QgsDistanceArea.formatDistance(0.5, 3, QgsUnitTypes.DistanceKilometers, True), '0.500 km')
self.assertEqual(QgsDistanceArea.formatDistance(0.5, 3, QgsUnitTypes.DistanceKilometers, False), '500.000 m')
self.assertEqual(QgsDistanceArea.formatDistance(6000, 0, QgsUnitTypes.DistanceFeet, True), '6,000 ft')
self.assertEqual(QgsDistanceArea.formatDistance(6000, 0, QgsUnitTypes.DistanceFeet, True), '6000 ft')
self.assertEqual(QgsDistanceArea.formatDistance(6000, 3, QgsUnitTypes.DistanceFeet, False), '1.136 mi')
self.assertEqual(QgsDistanceArea.formatDistance(300, 0, QgsUnitTypes.DistanceFeet, True), '300 ft')
self.assertEqual(QgsDistanceArea.formatDistance(300, 0, QgsUnitTypes.DistanceFeet, False), '300 ft')
self.assertEqual(QgsDistanceArea.formatDistance(3000, 0, QgsUnitTypes.DistanceYards, True), '3,000 yd')
self.assertEqual(QgsDistanceArea.formatDistance(3000, 0, QgsUnitTypes.DistanceYards, True), '3000 yd')
self.assertEqual(QgsDistanceArea.formatDistance(3000, 3, QgsUnitTypes.DistanceYards, False), '1.705 mi')
self.assertEqual(QgsDistanceArea.formatDistance(300, 0, QgsUnitTypes.DistanceYards, True), '300 yd')
self.assertEqual(QgsDistanceArea.formatDistance(300, 0, QgsUnitTypes.DistanceYards, False), '300 yd')
self.assertEqual(QgsDistanceArea.formatDistance(1.5, 3, QgsUnitTypes.DistanceMiles, True), '1.500 mi')
self.assertEqual(QgsDistanceArea.formatDistance(1.5, 3, QgsUnitTypes.DistanceMiles, False), '1.500 mi')
self.assertEqual(QgsDistanceArea.formatDistance(0.5, 3, QgsUnitTypes.DistanceMiles, True), '0.500 mi')
self.assertEqual(QgsDistanceArea.formatDistance(0.5, 0, QgsUnitTypes.DistanceMiles, False), '2,640 ft')
self.assertEqual(QgsDistanceArea.formatDistance(0.5, 0, QgsUnitTypes.DistanceMiles, False), '2640 ft')
self.assertEqual(QgsDistanceArea.formatDistance(0.5, 1, QgsUnitTypes.DistanceNauticalMiles, True), '0.5 NM')
self.assertEqual(QgsDistanceArea.formatDistance(0.5, 1, QgsUnitTypes.DistanceNauticalMiles, False), '0.5 NM')
self.assertEqual(QgsDistanceArea.formatDistance(1.5, 1, QgsUnitTypes.DistanceNauticalMiles, True), '1.5 NM')
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.

0 comments on commit e82e521

Please sign in to comment.
You can’t perform that action at this time.