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

Try GitHub Actions by migrating updater-gui-tests and rust jobs #6732

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all 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
53 changes: 0 additions & 53 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,27 +94,6 @@ jobs:
DOCKER_BUILD_ARGUMENTS="--cache-from securedrop-test-focal-py3:${fromtag:-latest}" securedrop/bin/dev-shell \
bash -c "/opt/venvs/securedrop-app-code/bin/pip3 install --require-hashes -r requirements/python3/develop-requirements.txt && make -C .. lint"

rust:
# Keep version in sync with rust-toolchain.toml
docker:
- image: rust:1.69.0
environment:
# TODO: Remove after we're on Rust 1.70
CARGO_REGISTRIES_CRATES_IO_PROTOCOL: "sparse"
steps:
- checkout
- run:
name: Install dependencies
command: |
apt-get update && apt-get install make --yes
rustup component add rustfmt
rustup component add clippy
- run:
name: Lint and test Rust code
command: |
make rust-lint
make rust-test

app-tests:
machine:
image: ubuntu-2004:202010-01
Expand Down Expand Up @@ -247,25 +226,6 @@ jobs:
command: |
cd admin; make test

updater-gui-tests:
docker:
- image: debian:bullseye
steps:
- checkout
- run:
name: Install dependencies
command: |
apt update && apt-get install -y libqt5designer5 python3-venv
cd journalist_gui
python3 -m venv .venv/ && source .venv/bin/activate
pip install --require-hashes -r dev-requirements.txt
- run:
name: Run tests
command: |
cd journalist_gui
source .venv/bin/activate
QT_QPA_PLATFORM=offscreen python3 test_gui.py -v

static-analysis-and-no-known-cves:
machine:
image: ubuntu-2004:202010-01
Expand Down Expand Up @@ -378,10 +338,6 @@ workflows:
context:
- circleci-slack
<<: *slack-fail-post-step
- rust:
context:
- circleci-slack
<<: *slack-fail-post-step
- app-tests:
filters:
branches:
Expand Down Expand Up @@ -413,15 +369,6 @@ workflows:
context:
- circleci-slack
<<: *slack-fail-post-step
- updater-gui-tests:
filters:
branches:
ignore:
- /i18n-.*/
- /update-builder-.*/
context:
- circleci-slack
<<: *slack-fail-post-step
- static-analysis-and-no-known-cves:
requires:
- lint
Expand Down
42 changes: 42 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: CI
on: [push, pull_request]
defaults:
run:
shell: bash

jobs:
rust:
runs-on: ubuntu-latest
# Keep version in sync with rust-toolchain.toml
container: rust:1.69.0
env:
# TODO: Remove after we're on Rust 1.70
CARGO_REGISTRIES_CRATES_IO_PROTOCOL: "sparse"
steps:
- uses: actions/checkout@v3
- name: Install dependencies
run: |
apt-get update && apt-get install make --yes
rustup component add rustfmt
rustup component add clippy
- name: Lint and test Rust code
run: |
make rust-lint
make rust-test

updater-gui-tests:
runs-on: ubuntu-latest
container: debian:bullseye
steps:
- uses: actions/checkout@v3
- name: Install dependencies
run: |
apt-get update && apt-get install -y libqt5designer5 python3-venv
cd journalist_gui
python3 -m venv .venv/ && source .venv/bin/activate
pip install --require-hashes -r dev-requirements.txt
- name: Run tests
run: |
cd journalist_gui
source .venv/bin/activate
QT_QPA_PLATFORM=offscreen python3 test_gui.py -v