Skip to content

Commit

Permalink
Test parallelization stuff. (#31650)
Browse files Browse the repository at this point in the history
This is the content analogue of space-wizards/RobustToolbox#5412

Made Content.Tests run tests parallelized, which doesn't really seem to matter much.

I tried to make Content.IntegrationTest more aggressively parallelized but ran into dotnet/runtime#107197 so we need to shelve that. Added a comment explaining as such.
  • Loading branch information
PJB3005 authored and sleepyyapril committed Dec 23, 2024
1 parent 9b6527b commit 5f6701b
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 6 deletions.
8 changes: 8 additions & 0 deletions Content.IntegrationTests/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
[assembly: Parallelizable(ParallelScope.Children)]

// I don't know why this parallelism limit was originally put here.
// I *do* know that I tried removing it, and ran into the following .NET runtime problem:
// https://github.com/dotnet/runtime/issues/107197
// So we can't really parallelize integration tests harder either until the runtime fixes that,
// *or* we fix serv3 to not spam expression trees.
[assembly: LevelOfParallelism(3)]
2 changes: 0 additions & 2 deletions Content.IntegrationTests/PoolManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@
using Robust.Shared.Timing;
using Robust.UnitTesting;

[assembly: LevelOfParallelism(3)]

namespace Content.IntegrationTests;

/// <summary>
Expand Down
5 changes: 1 addition & 4 deletions Content.IntegrationTests/PoolManagerTestEventHandler.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@

[assembly: Parallelizable(ParallelScope.Children)]

namespace Content.IntegrationTests;
namespace Content.IntegrationTests;

[SetUpFixture]
public sealed class PoolManagerTestEventHandler
Expand Down
3 changes: 3 additions & 0 deletions Content.Tests/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
using NUnit.Framework;

[assembly: Parallelizable(ParallelScope.Fixtures)]

0 comments on commit 5f6701b

Please sign in to comment.