fix: try fix empty outputs
[skip ci]
This commit is contained in:
parent
d16b97a8e9
commit
2bdb5d4eb2
2 changed files with 15 additions and 10 deletions
14
.github/workflows/tf-acc-test.yaml
vendored
14
.github/workflows/tf-acc-test.yaml
vendored
|
|
@ -42,8 +42,10 @@ jobs:
|
|||
- name: set start time
|
||||
id: start_time
|
||||
run: |
|
||||
echo "time=$(date --rfc-3339=ns)" >> ${GITHUB_ENV}
|
||||
echo "start=$(date +%s%N)" >> ${GITHUB_ENV}
|
||||
time=$(date --rfc-3339=ns)
|
||||
echo "start_time=$time" >> ${GITHUB_ENV}
|
||||
start=$(date +%s%N)
|
||||
echo "start=$start" >> ${GITHUB_ENV}
|
||||
|
||||
- name: Notify
|
||||
uses: ./.github/actions/notify
|
||||
|
|
@ -51,7 +53,7 @@ jobs:
|
|||
webhook_url: ${{ secrets.GOOGLE_WEBHOOK_URL }}
|
||||
title: "[START] Terraform Acceptance Tests"
|
||||
subtitle: "${{ forgejo.event_name }} on branch ${{ forgejo.ref }}"
|
||||
event_title: "started: ${{ steps.start_time.outputs.time }}"
|
||||
event_title: "started: ${{ steps.start_time.outputs.start_time }}"
|
||||
event_author: ${{ forgejo.actor }}
|
||||
event_body: ${{ inputs.test_file }}
|
||||
event_number: ${{ forgejo.run_number }}
|
||||
|
|
@ -93,12 +95,14 @@ jobs:
|
|||
- name: set end time
|
||||
id: end_time
|
||||
run: |
|
||||
echo "time=$(date --rfc-3339=ns)" >> ${GITHUB_ENV}
|
||||
echo "end_time=$(date --rfc-3339=ns)" >> ${GITHUB_ENV}
|
||||
end=$(date +%s%N)
|
||||
echo "end=${end}" >> ${GITHUB_ENV}
|
||||
start=${{ steps.start_time.outputs.start }}
|
||||
diff=$((end-start))
|
||||
echo "diff=${diff}"
|
||||
duration=$(printf "%s.%s" "${diff:0: -9}" "${diff: -9:3}")
|
||||
echoh "duration=${duration}"
|
||||
echo "duration=${duration}" >> ${GITHUB_ENV}
|
||||
|
||||
- name: Notify
|
||||
|
|
@ -107,7 +111,7 @@ jobs:
|
|||
webhook_url: ${{ secrets.GOOGLE_WEBHOOK_URL }}
|
||||
title: "[END] Terraform Acceptance Tests"
|
||||
subtitle: "${{ forgejo.event_name }} on branch ${{ forgejo.ref }} with status: ${{ forgejo.event_name == 'workflow_dispatch' && steps.manual_run.outputs.status || steps.automatic_run.outputs.status }}"
|
||||
event_title: "run ended: ${{ steps.end_time.outputs.time }}, duration: ${{ steps.end_time.outputs.duration }} seconds"
|
||||
event_title: "run ended: ${{ steps.end_time.outputs.end_time }}, duration: ${{ steps.end_time.outputs.duration }} seconds"
|
||||
event_author: ${{ forgejo.actor }}
|
||||
event_body: "${{ forgejo.event_name == 'workflow_dispatch' && steps.manual_run.outputs.result || steps.automatic_run.outputs.result }}"
|
||||
event_number: ${{ forgejo.event.id }}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue