Skip to content

Remove the Npgsql.DependencyInjection.Tests project - #6617

Merged
roji merged 1 commit into
npgsql:mainfrom
0xced:remove-di-tests-project
Jul 7, 2026
Merged

roji merged 1 commit into
npgsql:mainfrom
0xced:remove-di-tests-project

Conversation

@0xced

@0xced 0xced commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

Now that dependency injection has been merged into the main project (#6594) the dependency injection tests can also be moved into the main test project.

Now that dependency injection has been merged into the main project (npgsql#6594) the dependency injection tests can also be moved into the main test project.
Copilot AI review requested due to automatic review settings July 5, 2026 13:22
@0xced
0xced requested review from roji and vonzshik as code owners July 5, 2026 13:22

Copilot AI left a comment

Copy link
Copy Markdown

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 removes the standalone Npgsql.DependencyInjection.Tests test project now that dependency injection functionality has been merged into the main Npgsql project, consolidating the DI tests under the primary Npgsql.Tests project.

Changes:

  • Updates DependencyInjectionTests.cs to use the Npgsql.Tests namespace (removing the old Npgsql.DependencyInjection.Tests namespace and redundant using).
  • Deletes the test/Npgsql.DependencyInjection.Tests test project file.
  • Removes the deleted test project from the solution (Npgsql.slnx).

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
test/Npgsql.Tests/DependencyInjectionTests.cs Aligns DI test namespace with the main test assembly (Npgsql.Tests).
test/Npgsql.DependencyInjection.Tests/Npgsql.DependencyInjection.Tests.csproj Removes the now-obsolete standalone DI test project.
Npgsql.slnx Drops the removed DI test project from the solution definition.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@0xced

0xced commented Jul 6, 2026

Copy link
Copy Markdown
Contributor Author

Interesting: run 28742228054 failed with many errors related to temp_table* structures, but after applying the commit from #6614 (which was not merged), all tests are passing in run 28745764116.

@roji roji left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Makes sense, thanks for taking care of this!

@roji

roji commented Jul 6, 2026

Copy link
Copy Markdown
Member

Ah, can you please undo the unrelated process ID changes? We're looking at solving this in other ways. The problem with just injecting process IDs is that these tables will accumulate forever (they don't get cleaned up).

@0xced
0xced force-pushed the remove-di-tests-project branch from 14b2e20 to e143366 Compare July 6, 2026 11:38
Copilot AI review requested due to automatic review settings July 6, 2026 11:38

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated no new comments.

Comments suppressed due to low confidence (1)

test/Npgsql.Tests/DependencyInjectionTests.cs:6

  • ServiceCollection/BuildServiceProvider() come from the Microsoft.Extensions.DependencyInjection package. After moving these tests into test/Npgsql.Tests, that test project doesn’t appear to reference Microsoft.Extensions.DependencyInjection, so this file will fail to compile against the test project's current package set.

@0xced

0xced commented Jul 6, 2026

Copy link
Copy Markdown
Contributor Author

Sure, I just removed the last commit and force pushed. I just wanted to confirm whether my change was the cause of the failing tests or not. It seems it's unrelated. 😀

@roji
roji merged commit c61f952 into npgsql:main Jul 7, 2026
17 of 24 checks passed
@0xced
0xced deleted the remove-di-tests-project branch July 7, 2026 09:04
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.

3 participants