Global Assertions Plugin
Overview
The Global Assertions Plugin for Pest provides global functions for assertions that were removed in v0.3
Source code: github.com/pestphp/pest-plugin-global-assertions
Installation
Install the Global Assertions Plugin via the Composer package manager:
1composer require pestphp/pest-plugin-global-assertions --dev
Available functions
This allows you to do the following, without calling the $this
object. For a full list of available methods, please refer to the compiled list.
1it('asserts true is true using global function', function () {2 assertTrue(true);3});
This plugin is a good temporary helper when upgrading to the Expectations API in Pest v0.3
Next section: Snapshots →