public function test_if_maybe_monad_obeys_the_laws($return, $f, $g, $x)
{
MonadLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
f\curryN(1, $return),
$f,
$g,
$x
) {
ApplicativeLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
f\curryN(1, $pure),
$u,
$v,
Functor $x
) {
FunctorLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$f,
$g,
$x
public function test_if_identity_monad_obeys_the_laws($f, $g, $x)
{
MonadLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
f\curryN(1, Identity::of),
$f,
$g,
$x
) {
ApplicativeLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
f\curryN(1, Identity::of),
$u,
$v,
Functor $x
) {
FunctorLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$f,
$g,
$x
public function test_if_maybe_monad_obeys_the_laws($return, $f, $g, $x)
{
MonadLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
f\curryN(1, $return),
$f,
$g,
$x
) {
ApplicativeLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
f\curryN(1, $pure),
$u,
$v,
public function test_it_should_obey_monoid_laws($x, $y, $z)
{
MonoidLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$x,
$y,
$z
Functor $x
) {
FunctorLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$f,
$g,
$x
public function test_if_list_obeys_the_laws($f, $g, $x)
{
MonadLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
f\curryN(1, fromValue),
$f,
$g,
$x
) {
ApplicativeLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
f\curryN(1, $pure),
$u,
$v,
Functor $x
) {
FunctorLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$f,
$g,
$x
public function test_it_should_obey_monoid_laws(Monoid $x, Monoid $y, Monoid $z)
{
MonoidLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$x,
$y,
$z
namespace test\Primitive;
-use Widmogrod\Functional as f;
use Widmogrod\Helpful\SetoidLaws;
use Widmogrod\Primitive\Num;
$c
) {
SetoidLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$a,
$b,
$c
namespace test\Primitive;
use Eris\TestTrait;
-use Widmogrod\Functional as f;
use Widmogrod\Helpful\MonoidLaws;
use Widmogrod\Helpful\SetoidLaws;
use Widmogrod\Primitive\Product;
$c
) {
SetoidLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$a,
$b,
$c
$c
) {
MonoidLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$a,
$b,
$c
namespace test\Primitive;
-use Widmogrod\Functional as f;
use Widmogrod\Helpful\MonoidLaws;
use Widmogrod\Helpful\SetoidLaws;
use Widmogrod\Primitive\Product;
$c
) {
SetoidLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$a,
$b,
$c
$c
) {
MonoidLaws::test(
- f\curryN(3, [$this, 'assertEquals']),
+ [$this, 'assertEquals'],
$a,
$b,
$c