Skip to content

Test timeouts #721

@RevanProdigalKnight

Description

@RevanProdigalKnight

Sometimes when writing unit tests I forget to provide an implementation to a mock, which causes the unit test to hang forever. It would be nice if bashunit could automatically cause unit tests to terminate as having errored out if they exceed a time threshold, e.g. 5 seconds

Example:

function test_hangs() {
  bashunit::mock some_function

  some_function

  assert_exit_code 0
}

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request
No fields configured for Feature.

Projects

Status
Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions