-
Notifications
You must be signed in to change notification settings - Fork 17
integration test suite #91
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
integration test suite #91
Conversation
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
pelikhan
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@copilot apply comments
- add a "build" target in makefile that run script/build
.github/workflows/integration.yml
Outdated
| GITHUB_TOKEN: "" | ||
| GH_TOKEN: "" | ||
|
|
||
| - name: Install gh CLI |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this step
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed the "Install gh CLI" step from the workflow. (78b652d)
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
pelikhan
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@copilot apply comments
- add org test as well
…efile target Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
|
@copilot build the executable and run the tests. make sure the integration test executable is NOT |
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Built the executable and ran the tests successfully. Changed the integration test binary name from |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces an integration test suite to validate the functionality of the compiled CLI binary against live endpoints. The test infrastructure includes authentication handling, timeout management, and basic validation of command outputs.
- Adds integration tests for
listandruncommands with graceful authentication fallback - Creates build and test automation through Makefile targets
- Implements CI/CD workflow for automated integration testing
Reviewed Changes
Copilot reviewed 6 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| integration/integration_test.go | Core test implementation with binary execution and command validation |
| integration/go.mod | Go module definition for test dependencies |
| integration/README.md | Documentation for running and understanding integration tests |
| Makefile | Build and integration test automation targets |
| DEV.md | Updated development documentation to include integration testing |
| .github/workflows/integration.yml | CI workflow for automated integration testing |
Comments suppressed due to low confidence (3)
integration/integration_test.go:83
- The model version 'openai/gpt-4.1' may not exist. Consider using a well-known stable model version like 'openai/gpt-4' or 'openai/gpt-3.5-turbo' to ensure test reliability.
hasExpectedContent := strings.Contains(lowerOut, "openai/gpt-4.1")
integration/integration_test.go:90
- The model version 'openai/gpt-4.1-nano' may not exist. Consider using a verified model name to prevent test failures due to invalid model references.
stdout, _, err := runCommand(t, "run", "openai/gpt-4.1-nano", "say 'pain' in french")
integration/integration_test.go:98
- The model version 'openai/gpt-4.1-nano' may not exist. Consider using a verified model name to prevent test failures due to invalid model references.
stdout, _, err := runCommand(t, "run", "openai/gpt-4.1-nano", "say 'pain' in french", "--org", "github")
sgoedecke
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, I think this is a good idea, as long as we keep the request count low and only trigger this on pushes to main. Good choice of 4.1-nano, so we're not consuming the more-popular 4.1 rate limit.
yes I figured a run push:main is cheap since we rarely push in this branch. |
Basic test infrastructure to run the compiled cli and check that the LLM call succeeds. Currently tests "list", and "run" (org/non-org).
These tests are meant to make sure that the happy path of integration tests works.