Skip to main content

@rbxts/expect > Assertion > function

Assertion.function() method​

Asserts that the value is a function.

Signature:

function(): Assertion<object>;

Returns:

Assertion<object>

Remarks​

Just a wrapper around , but with the function type provided automatically.

Example​

expect(() => {}).to.be.a.function();