Skip to content

Commit

Permalink
fix test project name and key
Browse files Browse the repository at this point in the history
  • Loading branch information
sycured committed Jul 31, 2023
1 parent d9cc40c commit 1fde768
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 13 deletions.
11 changes: 6 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,11 +66,11 @@ jobs:
rustup self update
rustup update --no-self-update
curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash
cargo binstall -y cargo-quickinstall
cargo binstall -y --force cargo-quickinstall
- name: Audit check
run: |
cargo binstall -y cargo-audit
cargo binstall -y --force cargo-audit
cargo audit --json > $HOME/audit.json || exit 0
- name: Check a local package and all of its dependencies for errors
Expand All @@ -87,12 +87,12 @@ jobs:

- name: Outdated check
run: |
cargo binstall -y cargo-outdated
cargo binstall -y --force cargo-outdated
cargo outdated --depth 1 --format json > $HOME/outdated.json
- name: Udeps check
run: |
cargo binstall -y cargo-udeps
cargo binstall -y --force cargo-udeps
cargo +nightly udeps --quiet --workspace --all-features --all-targets --output json > $HOME/udeps.json || exit 0
- name: Clippy check
Expand All @@ -102,7 +102,7 @@ jobs:
- name: Sonar converter
run: |
cargo binstall -y cargo-sonar
cargo binstall -y --force cargo-sonar
cargo sonar --issues audit,clippy,outdated,udeps --audit-path $HOME/audit.json --clippy-path $HOME/clippy.json --outdated-path $HOME/outdated.json --udeps-path $HOME/udeps.json --issues-path $HOME/sonar.json
- name: Setup sonarqube
Expand Down Expand Up @@ -156,6 +156,7 @@ jobs:
- name: Run tests.sh
run: ./tests.sh
env:
GIT_ACTION_RUN_NUMBER: ${{ github.run_number }}
JIRA_DOMAIN: ${{ secrets.JIRA_DOMAIN }}
JIRA_USER: ${{ secrets.JIRA_USER }}
JIRA_TOKEN: ${{ secrets.JIRA_TOKEN }}
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/security_audit_cron.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@ jobs:
rustup self update
rustup update --no-self-update
curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash
cargo binstall -y cargo-quickinstall
cargo binstall -y --force cargo-quickinstall
- name: Audit check
run: |
cargo binstall -y cargo-audit
cargo binstall -y --force cargo-audit
cargo audit --json > $HOME/audit.json || exit 0
- name: Check a local package and all of its dependencies for errors
Expand All @@ -58,12 +58,12 @@ jobs:

- name: Outdated check
run: |
cargo binstall -y cargo-outdated
cargo binstall -y --force cargo-outdated
cargo outdated --depth 1 --format json > $HOME/outdated.json
- name: Udeps check
run: |
cargo binstall -y cargo-udeps
cargo binstall -y --force cargo-udeps
cargo +nightly udeps --quiet --workspace --all-features --all-targets --output json > $HOME/udeps.json || exit 0
- name: Clippy check
Expand All @@ -73,7 +73,7 @@ jobs:
- name: Sonar converter
run: |
cargo binstall -y cargo-sonar
cargo binstall -y --force cargo-sonar
cargo sonar --issues audit,clippy,outdated,udeps --audit-path $HOME/audit.json --clippy-path $HOME/clippy.json --outdated-path $HOME/outdated.json --udeps-path $HOME/udeps.json --issues-path $HOME/sonar.json
- name: Setup sonarqube
Expand Down
2 changes: 1 addition & 1 deletion test_project_destroy.exp
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ if {$force_conservative} {
set timeout -1
spawn $env(JIRA_CLI) project delete_project $env(JIRA_PROJECT_KEY)
match_max 100000
expect -exact "Are you sure you want to delete the project key: CITS? \[y/n\] \[?25l"
expect -exact "Are you sure you want to delete the project key: $env(JIRA_PROJECT_KEY)? \[y/n\] \[?25l"
send -- "y"
expect eof
5 changes: 3 additions & 2 deletions tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@

set -e
export JIRA_CLI="./target/debug/jira_cli"
export JIRA_PROJECT_KEY="CITS"
export JIRA_PROJECT_NAME="ci-$GIT_ACTION_RUN_NUMBER"
export JIRA_PROJECT_KEY="CI$GIT_ACTION_RUN_NUMBER"
export JIRA_VERSION_NAME="v0.0.0"

# version
Expand Down Expand Up @@ -37,7 +38,7 @@ echo "$JIRA_USER_ACCOUNT_ID"
# project
## create
echo "project create"
$JIRA_CLI project create citest CITS "$JIRA_USER_ACCOUNT_ID"
$JIRA_CLI project create $JIRA_PROJECT_NAME $JIRA_PROJECT_KEY "$JIRA_USER_ACCOUNT_ID"
## get_id
echo "project get_id"
$JIRA_CLI project get_id $JIRA_PROJECT_KEY
Expand Down

0 comments on commit 1fde768

Please sign in to comment.