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

Update ghpr_mysql_test.groovy #3026

Merged
merged 2 commits into from
Jul 12, 2024
Merged
Changes from 1 commit
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
3 changes: 3 additions & 0 deletions pipelines/PingCAP-QE/tidb-test/latest/ghpr_mysql_test.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,9 @@ pipeline {
always {
junit(testResults: "**/result.xml")
}
unsuccessful {
archiveArtifacts artifacts: "tidb-test/mysql_test/mysql-test.out", fingerprint: true
lance6716 marked this conversation as resolved.
Show resolved Hide resolved
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestion: Add a file existence check before archiving artifacts to prevent errors [Best practice, importance: 9]

Suggested change
unsuccessful {
archiveArtifacts artifacts: "tidb-test/mysql_test/mysql-test.out", fingerprint: true
}
unsuccessful {
if (fileExists('tidb-test/mysql_test/mysql-test.out')) {
archiveArtifacts artifacts: "tidb-test/mysql_test/mysql-test.out", fingerprint: true
}
}

}
}
}
Expand Down