From 03c87cb7cbf873d41f0fa5be263d9564309fe7f8 Mon Sep 17 00:00:00 2001 From: Jenny Fothergill Date: Mon, 30 Nov 2020 15:38:05 -0700 Subject: [PATCH 1/2] add azure yml based on mbuild's --- azure-pipelines.yml | 73 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 azure-pipelines.yml diff --git a/azure-pipelines.yml b/azure-pipelines.yml new file mode 100644 index 00000000..f4073fa1 --- /dev/null +++ b/azure-pipelines.yml @@ -0,0 +1,73 @@ +trigger: + branches: + include: + - master + +pr: + autoCancel: true + branches: + include: + - master + +schedules: +- cron: "0 0 * * *" + displayName: Daily midnight build for master + branches: + include: + - master + always: true + + +stages: + - stage: Test + jobs: + - job: NoBleeding + strategy: + matrix: + Python36Ubuntu: + imageName: 'ubuntu-latest' + python.version: 3.6 + Python37Ubuntu: + imageName: 'ubuntu-latest' + python.version: 3.7 + Python36macOS: + imageName: 'macOS-latest' + python.version: 3.6 + Python37macOS: + imageName: 'macOS-latest' + python.version: 3.7 + + pool: + vmImage: $(imageName) + + steps: + - bash: echo "##vso[task.prependpath]$CONDA/bin" + displayName: Add Conda to path + + - bash: sudo chown -R $USER $CONDA + condition: eq( variables['Agent.OS'], 'Darwin' ) + displayName: Take ownership of conda installation + + - bash: | + conda config --set always_yes yes --set changeps1 no + displayName: Add relavent Channels + + - bash: | + conda update -c defaults conda + conda update --all + conda env create -n test-environment python=$(python.version) --file environment.yml + + source activate test-environment + pip install -e . + displayName: Create Conda env, Activate, Install dependencies, Install Branch + + - bash: | + source activate test-environment + pip install pytest-azurepipelines + python -m pytest -v --pyargs msibi --cov=msibi + displayName: Run Tests + + - bash: | + coveralls + condition: and( eq( variables['Agent.OS'], 'Linux' ), eq( variables['python.version'], '3.7' ) ) + displayName: Upload Coverage Report From e76263b7acad48a5d19359a22914e9c1634ab20a Mon Sep 17 00:00:00 2001 From: Jenny Fothergill Date: Wed, 24 Mar 2021 11:02:08 -0600 Subject: [PATCH 2/2] remove travis --- .travis.yml | 25 ------------------------- devtools/travis-ci/install.sh | 17 ----------------- 2 files changed, 42 deletions(-) delete mode 100755 .travis.yml delete mode 100755 devtools/travis-ci/install.sh diff --git a/.travis.yml b/.travis.yml deleted file mode 100755 index 147ad8ba..00000000 --- a/.travis.yml +++ /dev/null @@ -1,25 +0,0 @@ -language: generic - -sudo: false - -matrix: - include: - - { os: linux, env: PYTHON_VERSION=2.7 } - - { os: linux, env: PYTHON_VERSION=3.5 } - - { os: linux, env: PYTHON_VERSION=3.6 } - - { os: osx, env: PYTHON_VERSION=2.7 } - - { os: osx, env: PYTHON_VERSION=3.5 } - -install: - - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install md5sha1sum; fi - - source devtools/travis-ci/install.sh - - conda config --set always_yes yes --set changeps1 no - - conda env create -n test-environment python=$PYTHON_VERSION -f environment.yml - - source activate test-environment - - pip install -e . - -script: - - pytest -v --cov=msibi --cov-report= --pyargs msibi - -after_success: - - coveralls diff --git a/devtools/travis-ci/install.sh b/devtools/travis-ci/install.sh deleted file mode 100755 index 2a7c9872..00000000 --- a/devtools/travis-ci/install.sh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/bash - -if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then MINICONDA=Miniconda3-latest-MacOSX-x86_64.sh; fi -if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then MINICONDA=Miniconda3-latest-Linux-x86_64.sh; fi - -MINICONDA_MD5=$(curl -s https://repo.continuum.io/miniconda/ | grep -A3 $MINICONDA | sed -n '4p' | sed -n 's/ *\(.*\)<\/td> */\1/p') -wget https://repo.continuum.io/miniconda/$MINICONDA -if [[ $MINICONDA_MD5 != $(md5sum $MINICONDA | cut -d ' ' -f 1) ]]; then - echo "Miniconda MD5 mismatch" - exit 1 -fi -bash $MINICONDA -b -rm -f $MINICONDA - -export PATH=$HOME/miniconda3/bin:$PATH - -conda update -yq conda