Skip to content

test: add unit tests for GetInstallLocation#2040

Merged
chmouel merged 1 commit intotektoncd:mainfrom
chmouel:unittest-params-install_test
Apr 14, 2025
Merged

test: add unit tests for GetInstallLocation#2040
chmouel merged 1 commit intotektoncd:mainfrom
chmouel:unittest-params-install_test

Conversation

@chmouel
Copy link
Copy Markdown
Member

@chmouel chmouel commented Apr 11, 2025

  • Add test cases to verify retrieving installation namespace and version
  • Test edge cases for deployments with and without version labels
  • Ensure proper error handling when no deployments are found

Changes

Submitter Checklist

  • 📝 Ensure your commit message is clear and informative. Refer to the How to write a git commit message guide. Include the commit message in the PR body rather than linking to an external site (e.g., Jira ticket).

  • ♽ Run make test lint before submitting a PR to avoid unnecessary CI processing. Consider installing pre-commit and running pre-commit install in the repository root for an efficient workflow.

  • ✨ We use linters to maintain clean and consistent code. Run make lint before submitting a PR. Some linters offer a --fix mode, executable with make fix-linters (ensure markdownlint and golangci-lint are installed).

  • 📖 Document any user-facing features or changes in behavior.

  • 🧪 While 100% coverage isn't required, we encourage unit tests for code changes where possible.

  • 🎁 If feasible, add an end-to-end test. See README for details.

  • 🔎 Address any CI test flakiness before merging, or provide a valid reason to bypass it (e.g., token rate limitations).

  • If adding a provider feature, fill in the following details:

    • GitHub App
    • GitHub Webhook
    • Gitea/Forgejo
    • GitLab
    • Bitbucket Cloud
    • Bitbucket Data Center

    (update the provider documentation accordingly)

* Add test cases to verify retrieving installation namespace and version
* Test edge cases for deployments with and without version labels
* Ensure proper error handling when no deployments are found
Copilot AI review requested due to automatic review settings April 11, 2025 12:13
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.

@PuneetPunamiya
Copy link
Copy Markdown
Member

LGTM

@zakisk
Copy link
Copy Markdown
Member

zakisk commented Apr 11, 2025

/test go-testing

@zakisk
Copy link
Copy Markdown
Member

zakisk commented Apr 12, 2025

/lgtm

@chmouel
Copy link
Copy Markdown
Member Author

chmouel commented Apr 14, 2025

/merge

@chmouel chmouel added this pull request to the merge queue Apr 14, 2025
Merged via the queue into tektoncd:main with commit 16234d8 Apr 14, 2025
7 of 9 checks passed
@chmouel chmouel deleted the unittest-params-install_test branch April 14, 2025 07:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants