#!/usr/bin/perl

use v5.14;
use warnings;

use Test2::V0;

BEGIN { $ENV{PERL_ASSERT_ENABLED} = 0; }

use Syntax::Keyword::Assert;

# assertions do not fail
{
   ok( lives { assert(0) }, 'assert(0) does not fail when disabled' );
}

# side-effects do not happen
{
   my $counter;
   assert($counter++);
   ok( !$counter, 'assert() with side-effects does not happen' );
}

done_testing;
