Skip to content

Commit

Permalink
feat(ci): add pkcon to pip-conda-test
Browse files Browse the repository at this point in the history
  • Loading branch information
rami3l committed Mar 14, 2023
1 parent 30eefb0 commit 54e468d
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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' }}
Expand All @@ -325,15 +325,16 @@ jobs:
toolchain: stable
override: true
- uses: Swatinem/rust-cache@v2
- run: 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
14 changes: 7 additions & 7 deletions tests/pkcon.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,23 +7,23 @@ 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$
"## }
}

#[test]
fn pkcon_q() {
test_dsl! { r##"
in -Q
in --using pkcon -Q
ou apt
"## }
}

#[test]
fn pkcon_qi() {
test_dsl! { r##"
in -Qi apt
in --using pkcon -Qi apt
ou Installed
"## }
}
Expand All @@ -33,23 +33,23 @@ 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
"## }
}

#[test]
fn pkcon_si() {
test_dsl! { r##"
in -Si wget
in --using pkcon -Si wget
ou retrieves files from the web
"## }
}

0 comments on commit 54e468d

Please sign in to comment.