From 083b5dcd6937987ac23e8316c36e793ce78eec47 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Fri, 24 Jul 2015 22:42:29 +0200 Subject: travis-ci: Use container-based infrastructure The new travis infrastructure is container-based and does not allow the use of sudo, but travis allows to install whitelisted apt packages (http://docs.travis-ci.com/user/migrating-from-legacy/). --- .travis.yml | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index b868e83b1..7df53364c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,3 +1,4 @@ +sudo: false language: python matrix: include: @@ -26,3 +27,15 @@ notifications: channels: - "irc.freenode.org#bcfg2" use_notice: true +addons: + apt: + packages: + - swig + - libxml2-utils + - yum + - libaugeas0 + - augeas-lenses + - libacl1-dev + - libssl-dev + - python-gamin + - python-selinux -- cgit v1.2.3-1-g7c22 From 08f7ebc85d51932635d16c420e99d547d4a7eb81 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Fri, 24 Jul 2015 22:44:28 +0200 Subject: travis-ci: Enable cache for pip The new container-based infrastructure allow public projects to use the cache system to speed up the build. --- .travis.yml | 5 +++++ 1 file changed, 5 insertions(+) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index 7df53364c..4f96bc5b8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -39,3 +39,8 @@ addons: - libssl-dev - python-gamin - python-selinux +cache: + directories: + - $HOME/.cache/pip +before_cache: + - rm -f $HOME/.cache/pip/log/debug.log -- cgit v1.2.3-1-g7c22 From c5529d8979672d4cf92d4ba54ce01256ca1d0842 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Wed, 20 Jul 2016 21:47:17 +0200 Subject: travis-ci: Cache common xml schema files --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index 4f96bc5b8..c8f0c4c71 100644 --- a/.travis.yml +++ b/.travis.yml @@ -42,5 +42,7 @@ addons: cache: directories: - $HOME/.cache/pip + - $HOME/.cache/xml before_cache: - rm -f $HOME/.cache/pip/log/debug.log + - rm -f $HOME/.cache/xml/catalog.xml -- cgit v1.2.3-1-g7c22 From 4f3cb4335c6d934c34d851efa587c525e6fcd876 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Thu, 23 Mar 2017 20:19:34 +0100 Subject: travis-ci: Cache wheels for python deps The python dependencies are only build once to create the wheel and cached using the travis-ci infrastructure. All builds afterwards will be faster because the cached version is used. --- .travis.yml | 1 + 1 file changed, 1 insertion(+) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index c8f0c4c71..f51637ccd 100644 --- a/.travis.yml +++ b/.travis.yml @@ -42,6 +42,7 @@ addons: cache: directories: - $HOME/.cache/pip + - $HOME/.cache/wheels - $HOME/.cache/xml before_cache: - rm -f $HOME/.cache/pip/log/debug.log -- cgit v1.2.3-1-g7c22 From d5f24fed13339d01424c4f7748c239ae33e0b606 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Sat, 25 Jul 2015 01:32:05 +0200 Subject: travis-ci: Also run tests with python2.4 and python2.5 --- .travis.yml | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index f51637ccd..6a061b233 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,14 +2,15 @@ sudo: false language: python matrix: include: + - env: PYTHON=2.4 + - env: PYTHON=2.5 - python: "2.6" - env: WITH_OPTIONAL_DEPS=no TEST_SPHINX=no - - python: "2.6" - env: WITH_OPTIONAL_DEPS=yes TEST_SPHINX=no - - python: "2.7_with_system_site_packages" - env: WITH_OPTIONAL_DEPS=no TEST_SPHINX=no + - python: "2.7" - python: "2.7_with_system_site_packages" env: WITH_OPTIONAL_DEPS=yes TEST_SPHINX=yes +before_install: + - testsuite/prepare-python.sh + - if test -d "$HOME/custom-virtualenv/"; then source "$HOME/custom-virtualenv/bin/activate"; fi install: - testsuite/install.sh - pip install -e . @@ -29,7 +30,13 @@ notifications: use_notice: true addons: apt: + sources: + - deadsnakes packages: + - python2.4 + - python2.4-dev + - python2.5 + - python2.5-dev - swig - libxml2-utils - yum -- cgit v1.2.3-1-g7c22 From 73045f451a8cdfb0c48e87e736c3b6a28b22f6fb Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Wed, 22 Mar 2017 20:20:40 +0100 Subject: testsuite: Server requires Python2.6 We do not want to run the test for the Server with Python2.4 and Python2.5 and use the nose-exclude plugin to disable the Server tests based on the directory. We do not even want to import the modules of the Server, as it might not be possible anymore (missing dependencies or invalid syntax). nose-exclude-0.2 breaks compatibility with Python2.5 and below (it is using the "with open(..):" syntax), so we have to stick to the last version below. --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index 6a061b233..33cd0f022 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,8 +2,8 @@ sudo: false language: python matrix: include: - - env: PYTHON=2.4 - - env: PYTHON=2.5 + - env: PYTHON=2.4 NOSE_EXCLUDE_DIRS=testsuite/Testsrc/Testlib/TestServer + - env: PYTHON=2.5 NOSE_EXCLUDE_DIRS=testsuite/Testsrc/Testlib/TestServer - python: "2.6" - python: "2.7" - python: "2.7_with_system_site_packages" -- cgit v1.2.3-1-g7c22 From a1135d1eaaca9bd07c587ddbd0ce9faa04601216 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Wed, 22 Mar 2017 20:34:56 +0100 Subject: travis-ci: Only install packages if required The build dependencies for the optional dependencies should only be installed if we like to test with optional dependencies. To keep the .travis.yml clean we use yaml anchors and references. --- .travis.yml | 51 +++++++++++++++++++++++++++++++++------------------ 1 file changed, 33 insertions(+), 18 deletions(-) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index 33cd0f022..17d3bf58c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,13 +1,42 @@ sudo: false language: python + +packages: &build_deps_optional + - swig + - libxml2-utils + - yum + - libaugeas0 + - augeas-lenses + - libacl1-dev + - libssl-dev + matrix: include: - env: PYTHON=2.4 NOSE_EXCLUDE_DIRS=testsuite/Testsrc/Testlib/TestServer + addons: + apt: + sources: [deadsnakes] + packages: [python2.4, python2.4-dev] - env: PYTHON=2.5 NOSE_EXCLUDE_DIRS=testsuite/Testsrc/Testlib/TestServer + addons: + apt: + sources: [deadsnakes] + packages: [python2.5, python2.5-dev, libbluetooth-dev] + - python: "2.6" + - python: "2.6" + env: WITH_OPTIONAL_DEPS=yes + addons: + apt: + packages: *build_deps_optional + - python: "2.7" - python: "2.7_with_system_site_packages" env: WITH_OPTIONAL_DEPS=yes TEST_SPHINX=yes + addons: + apt: + packages: [*build_deps_optional, python-gamin, python-selinux] + before_install: - testsuite/prepare-python.sh - if test -d "$HOME/custom-virtualenv/"; then source "$HOME/custom-virtualenv/bin/activate"; fi @@ -18,39 +47,25 @@ script: - nosetests testsuite after_failure: - pip freeze + branches: except: - maint-1.2 - 1.1.0-stable + notifications: email: chris.a.st.pierre@gmail.com irc: channels: - "irc.freenode.org#bcfg2" use_notice: true -addons: - apt: - sources: - - deadsnakes - packages: - - python2.4 - - python2.4-dev - - python2.5 - - python2.5-dev - - swig - - libxml2-utils - - yum - - libaugeas0 - - augeas-lenses - - libacl1-dev - - libssl-dev - - python-gamin - - python-selinux + cache: directories: - $HOME/.cache/pip - $HOME/.cache/wheels - $HOME/.cache/xml + before_cache: - rm -f $HOME/.cache/pip/log/debug.log - rm -f $HOME/.cache/xml/catalog.xml -- cgit v1.2.3-1-g7c22 From 730ef612d9bbd9fc94a8e5d916831a91af033868 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Wed, 22 Mar 2017 21:03:21 +0100 Subject: travis-ci: Show skipped tests For the test environment with all optional dependencies, we want to run all tests. So let's print all skipped tests. --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index 17d3bf58c..118adc92b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -29,6 +29,7 @@ matrix: addons: apt: packages: *build_deps_optional + script: nosetests --show-skipped testsuite - python: "2.7" - python: "2.7_with_system_site_packages" @@ -36,6 +37,7 @@ matrix: addons: apt: packages: [*build_deps_optional, python-gamin, python-selinux] + script: nosetests --show-skipped testsuite before_install: - testsuite/prepare-python.sh -- cgit v1.2.3-1-g7c22 From b456b30113b0f5474f39415df7eaf0b2d08825f8 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Tue, 28 Mar 2017 17:02:20 +0200 Subject: travis-ci: New python-augeas version requires libaugeas-dev The new python-augeas version builds a "C Foreign Function Interface" for libaugeas and do not load the library with dlopen at runtime anymore. So libaugeas-dev is required as build dependencies. --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index 118adc92b..dd8c9defd 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,7 +5,7 @@ packages: &build_deps_optional - swig - libxml2-utils - yum - - libaugeas0 + - libaugeas-dev - augeas-lenses - libacl1-dev - libssl-dev -- cgit v1.2.3-1-g7c22 From adf2d9f060a629071abe325e3b4b882e5893e858 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Wed, 29 Mar 2017 13:37:09 +0200 Subject: travis-ci: Use default emails notification address The default email notifications should be sufficient: > By default, a build email is sent to the committer and the author, > but only if they have access to the repository the commit was > pushed to. --- .travis.yml | 1 - 1 file changed, 1 deletion(-) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index dd8c9defd..542ac2337 100644 --- a/.travis.yml +++ b/.travis.yml @@ -56,7 +56,6 @@ branches: - 1.1.0-stable notifications: - email: chris.a.st.pierre@gmail.com irc: channels: - "irc.freenode.org#bcfg2" -- cgit v1.2.3-1-g7c22 From 17d83c675874ce7fff32c382b6d47af1628d45fc Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Thu, 17 Aug 2017 16:30:32 +0200 Subject: travis-ci: Enable Python3 tests, but allow it to fail --- .travis.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index 542ac2337..12fdddea6 100644 --- a/.travis.yml +++ b/.travis.yml @@ -39,6 +39,18 @@ matrix: packages: [*build_deps_optional, python-gamin, python-selinux] script: nosetests --show-skipped testsuite + - python: "3.5" + env: WITH_OPTIONAL_DEPS=yes + addons: + apt: + packages: *build_deps_optional + script: nosetests --show-skipped testsuite + + allow_failures: + - python: "3.5" + + fast_finish: true + before_install: - testsuite/prepare-python.sh - if test -d "$HOME/custom-virtualenv/"; then source "$HOME/custom-virtualenv/bin/activate"; fi -- cgit v1.2.3-1-g7c22 From 57e4c9e500b0c1094548d8a16699117cedb07598 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Thu, 17 Aug 2017 16:37:08 +0200 Subject: travis-ci: Simplified test script --- .travis.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index 12fdddea6..4d5d00f4a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -29,7 +29,6 @@ matrix: addons: apt: packages: *build_deps_optional - script: nosetests --show-skipped testsuite - python: "2.7" - python: "2.7_with_system_site_packages" @@ -37,14 +36,12 @@ matrix: addons: apt: packages: [*build_deps_optional, python-gamin, python-selinux] - script: nosetests --show-skipped testsuite - python: "3.5" env: WITH_OPTIONAL_DEPS=yes addons: apt: packages: *build_deps_optional - script: nosetests --show-skipped testsuite allow_failures: - python: "3.5" @@ -58,7 +55,7 @@ install: - testsuite/install.sh - pip install -e . script: - - nosetests testsuite + - testsuite/test.sh after_failure: - pip freeze -- cgit v1.2.3-1-g7c22 From d4e6925334c2db366dca85bf04b38ecf73a5af70 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Thu, 17 Aug 2017 16:51:11 +0200 Subject: travis-ci: Use the new default dist Since 2017-07-18 the default dist is changing to trusty[1]. Just using the new default before the switch. 1: https://blog.travis-ci.com/2017-07-11-trusty-as-default-linux-is-coming --- .travis.yml | 1 + 1 file changed, 1 insertion(+) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index 4d5d00f4a..022201bab 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,4 +1,5 @@ sudo: false +dist: trusty language: python packages: &build_deps_optional -- cgit v1.2.3-1-g7c22 From 0fdabbcb4668d5f70f76c08a6e3216c5542e7457 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Thu, 17 Aug 2017 21:32:52 +0200 Subject: travis-ci: Fix "with_system_site_packages" The "with_system_site_packages" virtualenv seems to be missing the pymodules directory containing python modules installed with the python-support debian helper. So we use the default environment and manually add the references to the system-wide python packages. --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.travis.yml') diff --git a/.travis.yml b/.travis.yml index 022201bab..af365b9d9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -32,8 +32,8 @@ matrix: packages: *build_deps_optional - python: "2.7" - - python: "2.7_with_system_site_packages" - env: WITH_OPTIONAL_DEPS=yes TEST_SPHINX=yes + - python: "2.7" + env: WITH_OPTIONAL_DEPS=yes WITH_SYSTEM_SITE_PACKAGES=yes TEST_SPHINX=yes addons: apt: packages: [*build_deps_optional, python-gamin, python-selinux] -- cgit v1.2.3-1-g7c22