Skip to content

[Bug]: Timeout specified using --timeout 5m command line argument is ignored #4117

@DaRosenberg

Description

@DaRosenberg

Description

We are running tests using dotnet test --timeout 5m in GHA. In maybe 10% of runs, a test seems to hang, but the specified timeout is ignored.

Here's a screenshot from GHA showing the issue:

Image

Expected Behavior

I expect the hanging test to be cancelled after 5 minutes.

Actual Behavior

Test run hangs for 6 hours with no progress, until GHA cancels the run.

Steps to Reproduce

  1. Create a test that waits forever
  2. Run it with dotnet test --timeout 5m in GitHub Actions

TUnit Version

1.5.41

.NET Version

.NET 10.0

Operating System

Linux

IDE / Test Runner

dotnet CLI (dotnet test / dotnet run)

Error Output / Stack Trace

Additional Context

No response

IDE-Specific Issue?

  • I've confirmed this issue occurs when running via dotnet test or dotnet run, not just in my IDE

Metadata

Metadata

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions