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
Split SQL Server functional tests into two projects #32953
base: main
Are you sure you want to change the base?
Conversation
{ | ||
protected override Assembly TargetAssembly { get; } = typeof(SqlServerComplianceTest).Assembly; | ||
} | ||
// public class SqlServerComplianceTest : RelationalComplianceTestBase |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will fix this if we decide to take this change.
This isn't the way I'd like us to go, as it creates an "arbitrary" split in our tests. But, on the other hand, it's a very straightforward way of making them faster. So, unless we stop using xunit, this looks like the most practical approach. |
Also, on my devbox it's less than 10% improvement. As an alternative, can you try adding this to |
I generally agree... It's a cool thing, but given that our tests already run really fast I'm not sure it's worth it...
Another idea if we think reducing test runtime is valuable enough - we could try to fully understand what exactly is going on inside that makes the tests run faster when split across assemblies (I think at this point it's mainly an empirical thing we don't actually understand). This may lead us to tweaks which could improve the perf without splitting the assembly. I also saw some tooling at some point which is designed specifically to show the concurrency inside your test sessions, e.g. as a way to locate stragglers, problematic tests, etc. |
What if I could come up with a reason to do a non-arbitrary split? Like an advantage of having all the query tests in one place, and all the non-query tests in another place? :-) Another thought. What if I am able to do make it continue to be a single test except with a certain solution/filter where it runs as two?
Yes, totally. |
I could try to create a simple repro without tests that either uses one process or multiple processes to slam the database. |
One additional thought on this - isn't there a risk of the two SQL Server test projects running in parallel and stepping over each other's toes, e.g. both trying to create the Northwind database at the same time etc.? Could be another reason to not split... |
Improves total test execution time by:
This is for all tests, excluding Cosmos. That is, 128,062 passed and 1,482 skipped.