Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Split workflow into PR and nightly #146

Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
189 changes: 189 additions & 0 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,189 @@
name: Nightly testing workflows for colcon-bundle
on:
# Build at minute 43 hour 17 (9:43am PST)
# Minutes was chosen randomly
schedule:
- cron: '43 17 * * *'
zmichaels11 marked this conversation as resolved.
Show resolved Hide resolved

jobs:
tox_unittest:
runs-on: ubuntu-18.04
env:
TOXENV: unittest
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Setup Python
uses: actions/setup-python@v1
with:
python-version: 3.5
- name: Install dependencies
run: |
sudo apt update && sudo apt install -y enchant
pip install -U tox setuptools==44.0.0
- name: Run tests
run: tox
- name: Log Test Failure
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'failure'
if: failure() && github.event_name == 'schedule'
- name: Log Test Success
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'success'
if: success() && github.event_name == 'schedule'
zmichaels11 marked this conversation as resolved.
Show resolved Hide resolved

backwards_compatability_test:
zmichaels11 marked this conversation as resolved.
Show resolved Hide resolved
runs-on: ubuntu-18.04
env:
TOXENV: py35-pypi
ROS_DISTRO: kinetic
TEST: backwards
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Setup Python
uses: actions/setup-python@v1
with:
python-version: 3.5
- name: Install dependencies
run: |
sudo apt update && sudo apt install -y enchant
pip install -U tox setuptools==44.0.0
- name: Run tests
run: tox
- name: Log Test Failure
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'failure'
if: failure() && github.event_name == 'schedule'
- name: Log Test Success
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'success'
if: success() && github.event_name == 'schedule'

double_test:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is "double" test and how is it not handled by the matrix in ros1_tests

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not quite sure what it does; the purpose of this PR was to improve the GitHub workflow by refactoring what we currently have.

I've opened the issue: #148 to resolve this

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all right - i see now that this is a full duplicate of the PR one plus cloudwatch. it feels really fragile to be completely duplicated with one difference, let's move forward as long as you're brainstorming how to deduplicate

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I can skip steps using if, opening a PR to test this

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Opened PR #149 which skips AWS configuration instead of duplicating work. I'll close this PR out if that workflow is working and its agreed upon that its a better solution.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@zmichaels11 @emersonknapp See the .travis.yml to understand what each of these tests are doing. Each one is matrix of the tests using a specific Docker build.

runs-on: ubuntu-18.04
env:
TOXENV: py35-pypi
ROS_DISTRO: melodic
TEST: double
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Setup Python
uses: actions/setup-python@v1
with:
python-version: 3.5
- name: Install dependencies
run: |
sudo apt update && sudo apt install -y enchant
pip install -U tox setuptools==44.0.0
- name: Run tests
run: tox
- name: Log Test Failure
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'failure'
if: failure() && github.event_name == 'schedule'
- name: Log Test Success
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'success'
if: success() && github.event_name == 'schedule'

ros1_tests:
runs-on: ubuntu-18.04
strategy:
matrix:
toxenv: [py35-pypi, py35-github]
ros_distro: [melodic, kinetic]
env:
TOXENV: ${{ matrix.toxenv }}
ROS_DISTRO: ${{ matrix.ros_distro }}
TEST: backwards
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Setup Python
uses: actions/setup-python@v1
with:
python-version: 3.5
- name: Install dependencies
run: |
sudo apt update && sudo apt install -y enchant
pip install -U tox setuptools==44.0.0
- name: Run tests
run: tox
- name: Log Test Failure
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'failure'
if: failure() && github.event_name == 'schedule'
- name: Log Test Success
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'success'
if: success() && github.event_name == 'schedule'

ros2_tests:
runs-on: ubuntu-18.04
env:
TOXENV: py35-pypi
ROS_DISTRO: dashing
TEST: create
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Setup Python
uses: actions/setup-python@v1
with:
python-version: 3.5
- name: Install dependencies
run: |
sudo apt update && sudo apt install -y enchant
pip install -U tox setuptools==44.0.0
- name: Run tests
run: tox
- name: Log Test Failure
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'failure'
if: failure() && github.event_name == 'schedule'
- name: Log Test Success
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'success'
if: success() && github.event_name == 'schedule'
84 changes: 1 addition & 83 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
name: Testing workflows for colcon-bundle
name: PR testing workflows for colcon-bundle
on:
pull_request:
schedule:
- cron: '43 17 * * *'

jobs:
tox_unittest:
Expand All @@ -12,12 +10,6 @@ jobs:
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Setup Python
uses: actions/setup-python@v1
with:
Expand All @@ -28,16 +20,6 @@ jobs:
pip install -U tox setuptools==44.0.0
- name: Run tests
run: tox
- name: Log Test Failure
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'failure'
if: failure() && github.event_name == 'schedule'
- name: Log Test Success
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'success'
if: success() && github.event_name == 'schedule'

backwards_compatability_test:
runs-on: ubuntu-18.04
Expand All @@ -48,12 +30,6 @@ jobs:
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Setup Python
uses: actions/setup-python@v1
with:
Expand All @@ -64,16 +40,6 @@ jobs:
pip install -U tox setuptools==44.0.0
- name: Run tests
run: tox
- name: Log Test Failure
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'failure'
if: failure() && github.event_name == 'schedule'
- name: Log Test Success
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'success'
if: success() && github.event_name == 'schedule'

double_test:
runs-on: ubuntu-18.04
Expand All @@ -84,12 +50,6 @@ jobs:
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Setup Python
uses: actions/setup-python@v1
with:
Expand All @@ -100,16 +60,6 @@ jobs:
pip install -U tox setuptools==44.0.0
- name: Run tests
run: tox
- name: Log Test Failure
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'failure'
if: failure() && github.event_name == 'schedule'
- name: Log Test Success
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'success'
if: success() && github.event_name == 'schedule'

ros1_tests:
runs-on: ubuntu-18.04
Expand All @@ -124,12 +74,6 @@ jobs:
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Setup Python
uses: actions/setup-python@v1
with:
Expand All @@ -140,16 +84,6 @@ jobs:
pip install -U tox setuptools==44.0.0
- name: Run tests
run: tox
- name: Log Test Failure
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'failure'
if: failure() && github.event_name == 'schedule'
- name: Log Test Success
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'success'
if: success() && github.event_name == 'schedule'

ros2_tests:
runs-on: ubuntu-18.04
Expand All @@ -160,12 +94,6 @@ jobs:
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Setup Python
uses: actions/setup-python@v1
with:
Expand All @@ -176,13 +104,3 @@ jobs:
pip install -U tox setuptools==44.0.0
- name: Run tests
run: tox
- name: Log Test Failure
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'failure'
if: failure() && github.event_name == 'schedule'
- name: Log Test Success
uses: ros-tooling/action-cloudwatch-metrics@0.0.1
with:
status: 'success'
if: success() && github.event_name == 'schedule'