Skip to content
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

feat: support monorepo #13

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

IgorKhramtsov
Copy link

In my project, we are using monorepo, so the project structure looks like this:

flutter-monorepo
  melos.yaml
  packages
    -- core
    -- module 1
    -- module 2
    -- example

I open nvim from the flutter-monorepo directory, and when I try to run a test from any package, it looks like flutter test command is executed from that flutter-monorepo directory because I am getting errors like "Couldn't resolve the package ... in ..." for every import line.

This change will look for the flutter project of the test file that should be run and use it as the cwd for the command.

@lewandowski-jan
Copy link

I was getting error "No pubspec.yaml found" when trying to run nearest test in test/some_test.dart, with this change it also fixes my issue.

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