Skip to content

Add baseline unit tests and PR CI for bot utilities + manager auth#41

Merged
kashifulhaque merged 3 commits intomainfrom
copilot/add-tests-for-codebase
Jan 18, 2026
Merged

Add baseline unit tests and PR CI for bot utilities + manager auth#41
kashifulhaque merged 3 commits intomainfrom
copilot/add-tests-for-codebase

Conversation

Copy link
Contributor

Copilot AI commented Jan 18, 2026

The repo had no test suite and PRs to main did not run tests. This introduces initial coverage and a PR workflow that executes the test suites.

  • Python utilities: added unittest coverage for LLM helpers, chat message shaping, emoji/sticker replacement, cache behavior, and singleton behavior.
  • Go manager: added auth middleware test coverage for missing/invalid/valid bearer tokens.
  • CI: new PR workflow runs Python and Go tests with read-only permissions.

Example test coverage:

result = prepare_chat_messages(prompt="describe", image=b"image")
assert result[0]["content"][1]["image_url"]["url"].startswith("data:image/jpeg;base64,")
Original prompt

Go through the entire codebase and write tests. When a PR is created (to merge to main, as pushing to main is blocked), it should run that test suite in GitHub workflow.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 2 commits January 18, 2026 16:48
Co-authored-by: kashifulhaque <37375667+kashifulhaque@users.noreply.github.com>
Co-authored-by: kashifulhaque <37375667+kashifulhaque@users.noreply.github.com>
Copilot AI changed the title [WIP] Add tests for entire codebase and workflow integration Add baseline unit tests and PR CI for bot utilities + manager auth Jan 18, 2026
Copilot AI requested a review from kashifulhaque January 18, 2026 16:57
Copy link
Member

@kashifulhaque kashifulhaque left a comment

Choose a reason for hiding this comment

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

LGTM

@kashifulhaque kashifulhaque marked this pull request as ready for review January 18, 2026 17:10
Copilot AI review requested due to automatic review settings January 18, 2026 17:10
@kashifulhaque kashifulhaque review requested due to automatic review settings January 18, 2026 17:10
@kashifulhaque kashifulhaque merged commit c268f42 into main Jan 18, 2026
7 checks passed
@kashifulhaque kashifulhaque deleted the copilot/add-tests-for-codebase branch January 18, 2026 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants