Supported Versions: PHP 4, PHP 5, PHP 7, PHP 8
Natural logarithm
<?php log(float $num, float $base = M_E): float
<?php })->throws(ExpectationFailedException::class, 'oh no!');



test('not failures', function () {

    expect(log(3))->not->toBeFloat();

})->throws(ExpectationFailedException::class);
<?php use PHPUnit\Framework\ExpectationFailedException;



test('pass', function () {

    expect(log(0))->toBeInfinite();

    expect(log(1))->not->toBeInfinite();

});
<?php test('pass', function () {

    expect(log(0))->toBeInfinite();

    expect(log(1))->not->toBeInfinite();

});



test('failures', function () {
<?php test('pass', function () {

    expect(asin(2))->toBeNan();

    expect(log(0))->not->toBeNan();

});



test('failures', function () {