Skip to content

Conversation

@cte
Copy link
Collaborator

@cte cte commented Jan 31, 2025

Description

Clean up our integration tests a bit and run them in CI.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Checklist:

  • My code follows the patterns of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation

Additional context

Related Issues

Reviewers


Important

Add integration tests to CI workflow, update pre-commit hooks, and enhance ClineProvider for testing.

  • CI/CD:
    • Add integration-test job to .github/workflows/code-qa.yml to run integration tests on ubuntu-latest.
    • Add workflow_dispatch to trigger CI manually.
  • Pre-commit:
    • Update .husky/pre-commit to run npm run compile, npm run lint, and npm run check-types.
  • Configuration:
    • Add .env.integration.example for integration test environment variables.
    • Add tsconfig.integration.json for integration test TypeScript configuration.
    • Add flake.nix and flake.lock for Nix development environment.
  • Testing:
    • Add test:integration script in package.json to run integration tests.
    • Add src/test/task.test.ts for task-related integration tests.
    • Update src/test/extension.test.ts to include environment variable checks.
  • Code Changes:
    • Update ClineProvider in ClineProvider.ts to support integration tests with viewLaunched and messages getters.

This description was created by Ellipsis for 2e094b4. It will automatically update as commits are pushed.

@changeset-bot
Copy link

changeset-bot bot commented Jan 31, 2025

⚠️ No Changeset found

Latest commit: 75bf341

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@ColemanRoo
Copy link
Contributor

Heads up, I have this branch from earlier this week: https://github.com/RooVetGit/Roo-Code/tree/feature/integrationTestCI
I ran into issues getting the tests to run in GHAs because it seems like the webview never became available or was accessible.

The test worked 100% of the time locally...

@cte
Copy link
Collaborator Author

cte commented Jan 31, 2025

@ColemanRoo - It's working! https://github.com/RooVetGit/Roo-Code/actions/runs/13082391740/job/36508410859?pr=691

Might be b/c I'm using MacOS; I haven't tried using Linux like your branch does.

@ColemanRoo
Copy link
Contributor

@ColemanRoo - It's working! https://github.com/RooVetGit/Roo-Code/actions/runs/13082391740/job/36508410859?pr=691

Might be b/c I'm using MacOS; I haven't tried using Linux like your branch does.

Awesome! I was trying to avoid using MacOS since those runners cost more, but if that's what makes this work, I think we should go for it.

// secrets

private async storeSecret(key: SecretKey, value?: string) {
public async storeSecret(key: SecretKey, value?: string) {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

We call this from the integration test, so it has to be public, but it seems like it shouldn't be. I'll try to clean this up in a follow-up.

@cte
Copy link
Collaborator Author

cte commented Feb 1, 2025

@mrubens - I think this is ready to go if you have time to take a quick look.

@cte
Copy link
Collaborator Author

cte commented Feb 1, 2025

Awesome! I was trying to avoid using MacOS since those runners cost more, but if that's what makes this work, I think we should go for it.

🤔 - Seems to work on both MacOS and Ubuntu: https://github.com/RooVetGit/Roo-Code/actions/runs/13083240642/job/36510729987?pr=691

We can just use Ubuntu if it's cheaper.

@cte cte merged commit 8ce5f9a into main Feb 1, 2025
5 checks passed
@cte cte deleted the cte/integration-tests branch February 1, 2025 00:51
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.

4 participants