Acme-Echo

 view release on metacpan or  search on metacpan

t/after.t  view on Meta::CPAN

use strict;
use warnings;
use Test::More tests => 2;
my $s = 0;
foreach (1 .. 10){
  $s += $_;
}

no Acme::Echo;

my $expected = do { local $/ = undef; <DATA> };
is( $out, $expected, "output matches" );
is( $s, 55, "s=55" );

__DATA__
CODE RAN WAS:<br>
<pre>

use strict;
use warnings;
use Test::More tests => 2;
my $s = 0;
foreach (1 .. 10){
  $s += $_;
}

t/all.t  view on Meta::CPAN

use strict;
use warnings;
use Test::More tests => 2;
my $s = 0;
foreach (1 .. 10){
  $s += $_;
}

no Acme::Echo;

my $expected = do { local $/ = undef; <DATA> };
is( $out, $expected, "output matches" );
is( $s, 55, "s=55" );

__DATA__
CODE RAN WAS:<br>
<pre>

use strict;
use warnings;
use Test::More tests => 2;
my $s = 0;
foreach (1 .. 10){
  $s += $_;
}

t/before.t  view on Meta::CPAN

use strict;
use warnings;
use Test::More tests => 2;
my $s = 0;
foreach (1 .. 10){
  $s += $_;
}

no Acme::Echo;

my $expected = do { local $/ = undef; <DATA> };
is( $out, $expected, "output matches" );
is( $s, 55, "s=55" );

__DATA__
CODE RAN WAS:<br>
<pre>

use strict;
use warnings;
use Test::More tests => 2;
my $s = 0;
foreach (1 .. 10){
  $s += $_;
}

t/lines.t  view on Meta::CPAN

$s=0;
while($s < 3){
  $s++;
}
sub cube {
  my $n = shift;
  return $n ** 3
}

no Acme::Echo;
my $expected = do { local $/ = undef; <DATA> };
is( $out, $expected, "output matches" );
is( $s, 3, "s=3" );

__DATA__
--> use strict; <--
--> use warnings; <--
--> use Test::More tests => 2; <--
--> my $x = 1; <--
--> my $y; <--
--> $y = $x ** 2; <--
--> my $s = 0; <--
--> $s += $_ for 1 .. 10; <--
--> $s = 0; <--
COMPOUND STATEMENTS NOT SUPPORTED IN lines MODE



( run in 0.572 second using v1.01-cache-2.11-cpan-cdf2f3d4e48 )