From 6f75cbcb0da1e0dd69d953287f9e4557913220a2 Mon Sep 17 00:00:00 2001 From: rami3l Date: Tue, 14 Mar 2023 17:48:20 +0800 Subject: [PATCH] feat(ci): add `pkcon` to `pip-conda-test` --- .github/workflows/test.yml | 9 ++++++--- tests/pkcon.rs | 14 +++++++------- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index c2856a75be..be8e2ef490 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -313,7 +313,7 @@ jobs: - name: Run heavy tests run: cargo test apk --verbose -- --ignored - pip-conda-test: + pkcon-pip-conda-test: runs-on: ubuntu-latest needs: skip-check if: ${{ needs.skip-check.outputs.should_skip != 'true' }} @@ -325,15 +325,18 @@ jobs: toolchain: stable override: true - uses: Swatinem/rust-cache@v2 + - run: | + sudo apt update + sudo apt install -y packagekit packagekit-tools - name: Build run: cargo build --verbose - # - name: Run unit tests - # run: cargo test tests --verbose - name: Run smoke tests run: | + cargo test pkcon --verbose cargo test pip --verbose cargo test conda --verbose - name: Run heavy tests run: | + cargo test pkcon --verbose -- --ignored cargo test pip --verbose -- --ignored cargo test conda --verbose -- --ignored diff --git a/tests/pkcon.rs b/tests/pkcon.rs index c17a1e4a35..52773650a3 100644 --- a/tests/pkcon.rs +++ b/tests/pkcon.rs @@ -7,7 +7,7 @@ use common::*; #[should_panic(expected = "Failed with pattern `^Package: wget$`")] fn pkcon_fail() { test_dsl! { r##" - in -Si fish + in --using pkcon -Si fish ou ^Package: wget$ "## } } @@ -15,7 +15,7 @@ fn pkcon_fail() { #[test] fn pkcon_q() { test_dsl! { r##" - in -Q + in --using pkcon -Q ou apt "## } } @@ -23,7 +23,7 @@ fn pkcon_q() { #[test] fn pkcon_qi() { test_dsl! { r##" - in -Qi apt + in --using pkcon -Qi apt ou Installed "## } } @@ -33,15 +33,15 @@ fn pkcon_qi() { fn pkcon_r_s() { test_dsl! { r##" # Update package databases - in -Sy + in --using pkcon -Sy # Now installation - in -S fish --yes + in --using pkcon -S fish --yes in ! which fish ou /bin/fish # Now remove the package - in -R fish --yes + in --using pkcon -R fish --yes ou Finished "## } } @@ -49,7 +49,7 @@ fn pkcon_r_s() { #[test] fn pkcon_si() { test_dsl! { r##" - in -Si wget + in --using pkcon -Si wget ou retrieves files from the web "## } }