Skip to content

Debug tests are really slow #132

@samihuutoniemi

Description

@samihuutoniemi

We have a few hundred unit tests testing our backend, testing a lot of EF Core 6 code. Until recently, we used EntityFrameworkCore.AutoFixture to solve this. But we changed to EntityFrameworkCore.Testing as it can handle raw SQL. And all tests work great now.

The in-memory database is seeded in a method that inserts quite a lot of data into quite many tables. It works and is really quick when the tests are run. It's only executed once. Running only a single test takes around 12 seconds including seeding db.

But when debugging a single test, it takes about 42 seconds. Clocking the method seeding the database, I can see that part takes ~30 seconds.

So the question is: Is there anything that can be done to make debugging faster? This was not a problem in the other library.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions