expect package
Test-agnostic assertion library for ROBLOX.
Remarks
Exports the expect() method as the primary entry point.
Classes
Class | Description |
---|---|
Builder for creating messages in an expect() method. |
Functions
Function | Description |
---|---|
Recursively resolves the path and parent of a Proxy to create a full path from the root. | |
Creates a Proxy around a | |
Helper function for testing expect error messages. Throws an error if the | |
Perform assertions/checks on the state of a value. | |
Adds additional methods to expect(). | |
Add additional negations to expect(). | |
Add additional NOOPs to expect(). | |
Gets the (current) default ExpectConfig. | |
Finds the nearest proxy in the hierarchy that has a non null value, if any. | |
Safely gets the parent of a proxy, without triggering any metamethods. | |
Safely gets the path of a proxy, without triggering any metamethods. | |
Safely gets the value of a proxy, without triggering any metamethods. | |
Type guard for Proxy values. | |
Resets the default ExpectConfig. | |
Sets the default ExpectConfig. | |
Creates a Proxy around a |
Interfaces
Interface | Description |
---|---|
The "actual" variable in an expect() statement. | |
Parent interface for all expect() calls. | |
Configuration setting for expect(). Configuration is generally used inline as needed, as the concept of | |
The "expected" variable in an expect() statement. | |
Configuration options for instances of ExpectMessageBuilder. | |
Utility interface for specifying dynamic variables in expect error messages. | |
The data attached to a Proxy. | |
Data about the variables in an expect statement. |
Variables
Variable | Description |
---|---|
Utility constant for specifying dynamic variables in expect error messages. |
Type Aliases
Type Alias | Description |
---|---|
The implementation of a expect() method. | |
An object of expect() method names to implementations. | |
The value of an enum in a LuaEnum. | |
The result of an expect() method call. | |
Callback for deciding if a | |
Helper type for inferring the type of an array. | |
A user-defined enum, as it would be defined in the transpiled Lua. | |
A wrapper around a value | |
Callback for deciding if a |