Shampoo.Check.ShortReceiveTimeout (shampoo v0.4.0)

View Source

Basics

This check is disabled by default.

Learn how to enable it via .credo.exs.

This check has a base priority of high and works with any version of Elixir.

Explanation

ETC-CORE-012: Give a cross-process assertion enough time on a loaded runner. Allow at least the configured minimum on explicit waits and in the test helper's assert_receive_timeout. Use assert_received when delivery is already synchronized.

Check-Specific Parameters

Use the following parameters to configure this check:

:min_timeout

Minimum literal timeout in milliseconds. Defaults to 500.

This parameter defaults to 500.

:macros

Wait functions and macros to check. Custom names take their timeout as the last argument.

This parameter defaults to [:assert_receive, :assert_push, :assert_reply, :assert_broadcast, :assert_redirect, :assert_patch, :render_async].

:require_configured_default

Require assert_receive_timeout in test/test_helper.exs. Defaults to true.

This parameter defaults to true.

General Parameters

Like with all checks, general params can be applied.

Parameters can be configured via the .credo.exs config file.