Core Library0.xAPI Reference

Choose documentation 3

latest

Current version

latest
English

Early release libtmux is released, and its APIs may still change between releases. This site's structure and URLs may change too.

function libtmux-swift latest

waitUntil(within:_:)

Polls condition until it holds, and reports whether it did.

Source and package
Qualified name
waitUntil(within:_:)
Package
libtmux-swift
Source
Tests/TmuxFixture/TmuxFixture.swift
waitUntil( within: Duration, condition: () async throws -> Bool ) -> Bool

Description#

Bounded in wall-clock rather than in attempts. What makes one of these polls slow is the tmux call inside it, so a count of attempts says nothing about how long the loop can run: on a contended machine a generous-looking budget outlives the case's time limit, and the failure reads as a timeout instead of naming the thing that never became true.

Parameters
Raises

Guides#

Pages that discuss waitUntil(within:_:).

Esc

Type to search.

Reference previewOpen reference