namespace Febe.Tests.Support;
/// Set-up of the whole test assembly.
[TestClass]
public static class TestAssembly
{
///
/// The parallel tests (method level, see MSTestSettings.cs) block pool threads in several places: gates, barriers,
/// synchronous database work. On a runner with 2-4 cores the pool starts with as many threads as cores and adds more
/// only slowly, so a continuation another test waits for may start seconds late (#46). A larger minimum lets the
/// pool grow at once; it changes nothing in the code under test.
///
[AssemblyInitialize]
public static void Initialize(TestContext context)
{
ThreadPool.GetMinThreads(out var workers, out var completion);
ThreadPool.SetMinThreads(Math.Max(workers, 64), Math.Max(completion, 64));
}
}