Sage-Bionetworks / synapsePythonClient

Programmatic interface to Synapse services for Python
https://www.synapse.org
Apache License 2.0
65 stars 67 forks source link

[SYNPY-1470] Remove SonarCloud's dependency on test job #1095

Closed danlu1 closed 1 month ago

danlu1 commented 1 month ago

Problem: Currently, sonarcloud only executes when tests pass, but even if tests fail, it's valuable for sonarcloud to execute.

Solution: Let SonarCloud scan always run no matter what status of the previous steps. Add a separate step to check if coverage report exist, if not, skip downloading coverage report. Run Override Coverage Source Path for Sonar, only if the coverage report download step has succeeded.

Testing:

  1. Skip downloading the coverage report when the coverage report does not exist
  2. The SonarCloud scan runs even though Override Coverage Source Path for Sonar fails. Screenshot 2024-05-09 at 8 45 42 PM
  3. Skip Override Coverage Source Path for Sonar when the coverage report does not exist. Screenshot 2024-05-10 at 9 08 14 AM