From bd485939c869fc845e5971795656a6fba122c943 Mon Sep 17 00:00:00 2001 From: redshiftzero Date: Thu, 4 Jan 2018 15:35:14 -0800 Subject: [PATCH] Remove Travis CI and run pages-layout tests on Circle CI --- .travis.yml | 54 ------------------------------- molecule/aws/scripts/app-tests.sh | 6 +++- 2 files changed, 5 insertions(+), 55 deletions(-) delete mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index bad341d079..0000000000 --- a/.travis.yml +++ /dev/null @@ -1,54 +0,0 @@ ---- -# Use Ubuntu 14.04 LTS images, and explicitly require sudo. -# Relevant docs: https://docs.travis-ci.com/user/trusty-ci-environment/ -sudo: required -dist: trusty -# Pin older version of Firefox, for Selenium compatibility. Must match version -# specified in app-test role vars! -addons: - firefox: 46.0.1 - -# Setting language=generic to prevent Travis from setting up a virtualenv. -# Using a virtualenv conflicts with the global pip installation currently -# used for configuring SecureDrop, both in development and staging. -language: generic - -before_install: - - 'for e in /.packer-env/*; do echo -n "${e}: "; cat "${e}"; done' - # Removes Travis-specific PATH customizations that affect Python. - - export PATH="$(echo $PATH | tr ':' "\n" | sed '/\/opt\/python/d' | tr "\n" ":" | sed "s|::|:|g")" - - printenv | sort # dump Travis environment for debugging - - pip freeze -l -install: - # Installing Python dependencies globally, to match SecureDrop deployment. - - sudo -H pip install -r securedrop/requirements/develop-requirements.txt - # Run linting early, to fail fast. - - make --keep-going lint - # Using YAML folding operator '>' to aid in readability and avoid - # extremely long lines. - - > - printf - "[development]\nlocalhost ansible_connection=local\n[travis]\nlocalhost" - > inventory - - > - ansible-playbook -i inventory -vv --syntax-check - install_files/ansible-base/securedrop-development.yml - - > - ansible-playbook -i inventory -vv --connection=local - install_files/ansible-base/securedrop-development.yml -script: - # For some reason, redis-server does not start automatically when installed - # on Travis. I believe Travis' service machinery may be interfering. See - # http://docs.travis-ci.com/user/database-setup/#Redis - - sudo service redis-server start - # The `cd securedrop` is necessary for coverage support. Remove it below - # once #2246 is resolved. - # --pages-layout are created for selected languages only because they - # are time consuming. - # * en_US: source strings - # * fr_FR: left-to-right translations - - sh -c "export DISPLAY=:1 ; cd securedrop && PAGE_LAYOUT_LOCALES='en_US,fr_FR' pytest -v tests --page-layout" - - pip freeze -l - - SECUREDROP_TESTINFRA_TARGET_HOST=travis testinfra -v testinfra/development/ -after_success: - cd securedrop/ diff --git a/molecule/aws/scripts/app-tests.sh b/molecule/aws/scripts/app-tests.sh index 3485ded9e6..f56548a858 100644 --- a/molecule/aws/scripts/app-tests.sh +++ b/molecule/aws/scripts/app-tests.sh @@ -6,4 +6,8 @@ export DISPLAY=:1 cd "$1" || exit 1 -pytest --junit-xml=/tmp/apptest.xml --junit-prefix=apptest tests/ +# --pages-layout are created for selected languages only because they +# are time consuming. +# * en_US: source strings +# * fr_FR: left-to-right translations +PAGE_LAYOUT_LOCALES='en_US,fr_FR' pytest --pages-layout --junit-xml=/tmp/apptest.xml --junit-prefix=apptest tests/