Skip to content

Add notebook dependency completion coverage - #3899

Open
Brun3y (BrUn3y) wants to merge 2 commits into
microsoft:mainfrom
BrUn3y:test/notebook-dependency-completions-1768
Open

Brun3y (BrUn3y) wants to merge 2 commits into
microsoft:mainfrom
BrUn3y:test/notebook-dependency-completions-1768

Conversation

@BrUn3y

Copy link
Copy Markdown

Add notebook dependency completion coverage

Description

Adds the missing language-service coverage for completions in notebooks connected to a Q# project with package dependencies.

The new integration test uses a virtual file system containing a project and a local dependency. It verifies that:

  • exported items from the dependency are offered as notebook completions;
  • selecting the completion adds the expected package-qualified import; and
  • an explicitly imported item is completed without adding a duplicate import.

Closes #1768.

Validation

  • cargo fmt --all --check
  • cargo test -p qsls
  • cargo clippy -p qsls --tests -- -D warnings

@BrUn3y

Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree

@BrUn3y

Copy link
Copy Markdown
Author

Andrew Casey (@amcasey) could you please review this PR? I've resolved the merge conflict with the latest main, preserving both the notebook dependency completion coverage and the updated upstream diagnostic test.

Validation on the updated branch:

  • cargo fmt --all --check
  • cargo test --locked -p qsls — 586 passed, 2 ignored
  • cargo clippy --locked -p qsls --tests -- -D warnings

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approval recommended

No active review issues are identified for the notebook dependency completion coverage and test-helper changes.

No open issues 🎉

What changed in this PR

Adds language-service test coverage for notebooks connected to Q# projects with package dependencies, addressing #1768.

Changes:

  • Verifies dependency exports appear in notebook completions with the expected package-qualified import, and that already imported items do not trigger duplicate imports.
  • Extracts an update-handler helper that accepts a custom virtual file system while preserving the existing default helper.
File Description
source/​language_service/​src/​tests.rs Adds notebook dependency completion coverage and a reusable custom-file-system test helper.

Review effort: Balanced

This branch has not been deployed

No deployments
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.

Notebook imports and completions from package dependencies needs new unit tests

3 participants