[Bps-public-commit] test-expect branch, master, created. 0.32
Alex Vandiver
alexmv at bestpractical.com
Thu Apr 2 01:52:56 EDT 2015
The branch, master has been created
at 03b28d1b1a03d09b046613830e04f8cddf0773ac (commit)
- Log -----------------------------------------------------------------
commit 23499a378c82e3b474a974c5b4141baab63141cc
Author: Léon Brocard <acme at astray.com>
Date: Wed Mar 30 16:12:15 2005 -0500
initial import of Test-Expect 0.29
diff --git a/Build.PL b/Build.PL
new file mode 100644
index 0000000..55c2e7f
--- /dev/null
+++ b/Build.PL
@@ -0,0 +1,16 @@
+use Module::Build;
+use strict;
+
+my $build = Module::Build->new(
+ create_makefile_pl => 'traditional',
+ license => 'perl',
+ module_name => 'Test::Expect',
+ requires => {
+ 'Class::Accessor::Chained::Fast' => '0',
+ 'Expect::Simple' => '0',
+ 'Term::ReadLine' => '0',
+ 'Test::Builder' => '0',
+ 'Test::More' => '0',
+ },
+);
+$build->create_build_script;
diff --git a/CHANGES b/CHANGES
new file mode 100644
index 0000000..da61b30
--- /dev/null
+++ b/CHANGES
@@ -0,0 +1,4 @@
+Revision history for Perl module Devel::ebug
+
+0.29 Wed Mar 30 23:18:02 CST 2005
+ - initial release
diff --git a/MANIFEST b/MANIFEST
new file mode 100644
index 0000000..b35b194
--- /dev/null
+++ b/MANIFEST
@@ -0,0 +1,10 @@
+Build.PL
+CHANGES
+lib/Test/Expect.pm
+Makefile.PL
+MANIFEST This list of files
+META.yml
+read
+readline
+README
+t/simple.t
diff --git a/META.yml b/META.yml
new file mode 100644
index 0000000..be19bf6
--- /dev/null
+++ b/META.yml
@@ -0,0 +1,19 @@
+--- #YAML:1.0
+name: Test-Expect
+version: 0.29
+author:
+ - Leon Brocard, C<< <acme at astray.com> >>
+abstract: |-
+ Automated driving and testing of terminal-based programs
+license: perl
+requires:
+ Class::Accessor::Chained::Fast: 0
+ Expect::Simple: 0
+ Term::ReadLine: 0
+ Test::Builder: 0
+ Test::More: 0
+provides:
+ Test::Expect:
+ file: lib/Test/Expect.pm
+ version: 0.29
+generated_by: Module::Build version 0.2605
diff --git a/Makefile.PL b/Makefile.PL
new file mode 100644
index 0000000..c514df3
--- /dev/null
+++ b/Makefile.PL
@@ -0,0 +1,17 @@
+# Note: this file was auto-generated by Module::Build::Compat version 0.03
+use ExtUtils::MakeMaker;
+WriteMakefile
+(
+ 'NAME' => 'Test::Expect',
+ 'VERSION_FROM' => 'lib/Test/Expect.pm',
+ 'PREREQ_PM' => {
+ 'Class::Accessor::Chained::Fast' => '0',
+ 'Expect::Simple' => '0',
+ 'Term::ReadLine' => '0',
+ 'Test::Builder' => '0',
+ 'Test::More' => '0'
+ },
+ 'INSTALLDIRS' => 'site',
+ 'PL_FILES' => {}
+ )
+;
diff --git a/README b/README
new file mode 100644
index 0000000..6575322
--- /dev/null
+++ b/README
@@ -0,0 +1,73 @@
+NAME
+ Test::Expect - Automated driving and testing of terminal-based programs
+
+SYNOPSIS
+ # in a t/*.t file:
+ use Test::Expect;
+ use Test::More tests => 13;
+ expect_run(
+ command => "perl testme.pl",
+ prompt => 'testme: ',
+ quit => 'quit',
+ );
+ expect("ping", "pong", "expect");
+ expect_send("ping", "expect_send");
+ expect_is("* Hi there, to testme", "expect_is");
+ expect_like(qr/Hi there, to testme/, "expect_like");
+
+DESCRIPTION
+ Test::Expect is a module for automated driving and testing of
+ terminal-based programs. It is handy for testing interactive programs
+ which have a prompt, and is based on the same concepts as the Tcl Expect
+ tool.
+
+ Test::Expect is intended for use in a test script.
+
+SUBROUTINES
+ expect_run
+ The expect_run subroutine sets up Test::Expect. You must pass in the
+ interactive program to run, what the prompt of the program is, and which
+ command quits the program:
+
+ expect_run(
+ command => "perl testme.pl",
+ prompt => 'testme: ',
+ quit => 'quit',
+ );
+
+ expect
+ The expect subroutine is the catch all subroutine. You pass in the
+ command, the expected output of the subroutine and an optional comment.
+
+ expect("ping", "pong", "expect");
+
+ expect_send
+ The expect_send subroutine sends a command to the program. You pass in
+ the command and an optional comment.
+
+ expect_send("ping", "expect_send");
+
+ expect_is
+ The expect_is subroutine tests the output of the program like
+ Test::More's is. It has an optional comment:
+
+ expect_is("* Hi there, to testme", "expect_is");
+
+ expect_like
+ The expect_like subroutine tests the output of the program like
+ Test::More's like. It has an optional comment:
+
+ expect_like(qr/Hi there, to testme/, "expect_like");
+
+SEE ALSO
+ Expect, Expect::Simple.
+
+AUTHOR
+ Leon Brocard, "<acme at astray.com>"
+
+COPYRIGHT
+ Copyright (C) 2005, Leon Brocard
+
+ This module is free software; you can redistribute it or modify it under
+ the same terms as Perl itself.
+
diff --git a/lib/Test/Expect.pm b/lib/Test/Expect.pm
new file mode 100644
index 0000000..ef7a007
--- /dev/null
+++ b/lib/Test/Expect.pm
@@ -0,0 +1,175 @@
+package Test::Expect;
+use strict;
+use warnings;
+use Class::Accessor::Chained::Fast;
+use Expect::Simple;
+use Exporter;
+use Test::Builder;
+use base qw(Class::Accessor::Chained::Fast Exporter);
+__PACKAGE__->mk_accessors(qw(program));
+our $VERSION = "0.29";
+our @EXPORT = qw(
+expect_run
+expect_is
+expect_like
+expect_send
+expect
+END
+);
+
+my $Test = Test::Builder->new;
+
+my $expect;
+my $sent;
+
+sub import {
+ my $self = shift;
+ if (@_) {
+ die @_;
+ my $package = caller;
+ $Test->exported_to($package);
+ $Test->plan(@_);
+ };
+ $Test->no_ending(0);
+ $self->export_to_level(1, $self, $_) foreach @EXPORT;
+}
+
+sub expect_run {
+ my(%conf) = @_;
+ $expect = Expect::Simple->new({
+ Cmd => "PERL_RL=\"o=0\" " . $conf{command},
+ Prompt => $conf{prompt},
+ DisconnectCmd => $conf{quit},
+ Verbose => 0,
+ Debug => 0,
+ Timeout => 100
+});
+ die $expect->error if $expect->error;
+ $Test->ok(1, "expect_run");
+}
+
+sub before {
+ my $before = $expect->before;
+ $before =~ s/\r//g;
+ $before =~ s/^$sent// if $sent;
+ $before =~ s/^\n+//;
+ $before =~ s/\n+$//;
+ return $before;
+}
+
+sub expect_like {
+ my($like, $comment) = @_;
+ $Test->like(before(), $like, $comment);
+}
+
+sub expect_is {
+ my($is, $comment) = @_;
+ $Test->is_eq(before(), $is, $comment);
+}
+
+sub expect_send {
+ my($send, $comment) = @_;
+ $expect->send($send);
+ $sent = $send;
+ $Test->ok(1, $comment);
+}
+
+sub expect {
+ my($send, $is, $label) = @_;
+ expect_send($send, $label);
+ expect_is($is, $label);
+}
+
+sub END {
+ undef $expect;
+}
+
+1;
+
+__END__
+
+=head1 NAME
+
+Test::Expect - Automated driving and testing of terminal-based programs
+
+=head1 SYNOPSIS
+
+ # in a t/*.t file:
+ use Test::Expect;
+ use Test::More tests => 13;
+ expect_run(
+ command => "perl testme.pl",
+ prompt => 'testme: ',
+ quit => 'quit',
+ );
+ expect("ping", "pong", "expect");
+ expect_send("ping", "expect_send");
+ expect_is("* Hi there, to testme", "expect_is");
+ expect_like(qr/Hi there, to testme/, "expect_like");
+
+=head1 DESCRIPTION
+
+L<Test::Expect> is a module for automated driving and testing of
+terminal-based programs. It is handy for testing interactive programs
+which have a prompt, and is based on the same concepts as the Tcl
+Expect tool.
+
+L<Test::Expect> is intended for use in a test script.
+
+=head1 SUBROUTINES
+
+=head2 expect_run
+
+The expect_run subroutine sets up L<Test::Expect>. You must pass in
+the interactive program to run, what the prompt of the program is, and
+which command quits the program:
+
+ expect_run(
+ command => "perl testme.pl",
+ prompt => 'testme: ',
+ quit => 'quit',
+ );
+
+=head2 expect
+
+The expect subroutine is the catch all subroutine. You pass in the
+command, the expected output of the subroutine and an optional
+comment.
+
+ expect("ping", "pong", "expect");
+
+=head2 expect_send
+
+The expect_send subroutine sends a command to the program. You pass in
+the command and an optional comment.
+
+ expect_send("ping", "expect_send");
+
+=head2 expect_is
+
+The expect_is subroutine tests the output of the program like
+Test::More's is. It has an optional comment:
+
+ expect_is("* Hi there, to testme", "expect_is");
+
+=head2 expect_like
+
+The expect_like subroutine tests the output of the program like
+Test::More's like. It has an optional comment:
+
+ expect_like(qr/Hi there, to testme/, "expect_like");
+
+=head1 SEE ALSO
+
+L<Expect>, L<Expect::Simple>.
+
+=head1 AUTHOR
+
+Leon Brocard, C<< <acme at astray.com> >>
+
+=head1 COPYRIGHT
+
+Copyright (C) 2005, Leon Brocard
+
+This module is free software; you can redistribute it or modify it
+under the same terms as Perl itself.
diff --git a/read b/read
new file mode 100644
index 0000000..6855fb2
--- /dev/null
+++ b/read
@@ -0,0 +1,18 @@
+#!perl
+use strict;
+use warnings;
+$| = 1;
+
+print "* Hi there, to read\n";
+
+while (1) {
+ print "read: ";
+ my $command = <>;
+ chomp $command;
+
+ if ($command eq 'ping') {
+ print "pong\n";
+ } elsif ($command eq 'quit') {
+ exit;
+ }
+}
diff --git a/readline b/readline
new file mode 100644
index 0000000..68e33e5
--- /dev/null
+++ b/readline
@@ -0,0 +1,18 @@
+#!perl
+use strict;
+use warnings;
+use Term::ReadLine;
+
+print "* Hi there, to readline\n";
+
+my $term = Term::ReadLine->new('readline');
+
+while (1) {
+ my $command = $term->readline("readline: ");
+
+ if ($command eq 'ping') {
+ print "pong\n";
+ } elsif ($command eq 'quit') {
+ exit;
+ }
+}
diff --git a/t/simple.t b/t/simple.t
new file mode 100644
index 0000000..99229f3
--- /dev/null
+++ b/t/simple.t
@@ -0,0 +1,21 @@
+#!perl
+use strict;
+use warnings;
+use lib 'lib';
+use Test::Expect;
+use Test::More tests => 15;
+
+ok(1, "True");
+
+foreach my $filename ('read', 'readline') {
+ ok($filename, "Testing $filename");
+ expect_run(
+ command => "$^X $filename",
+ prompt => $filename . ': ',
+ quit => 'quit',
+ );
+ expect_like(qr/Hi there, to $filename/, "expect_like");
+ expect_is("* Hi there, to $filename", "expect_is");
+ expect_send("ping", "expect_send");
+ expect("ping", "pong", "expect");
+};
commit 2608166aeb5cfb002e5d3947af49c875e621926d
Author: Léon Brocard <acme at astray.com>
Date: Tue Feb 28 22:02:53 2006 -0500
import Test-Expect 0.30
diff --git a/CHANGES b/CHANGES
index da61b30..6e73c14 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,4 +1,8 @@
Revision history for Perl module Devel::ebug
+0.30 Tue Feb 28 21:54:16 GMT 2006
+ - added expect_handle to fetch the underlying Expect object
+ (patch by Kevin Riggle)
+
0.29 Wed Mar 30 23:18:02 CST 2005
- initial release
diff --git a/META.yml b/META.yml
index be19bf6..53f3468 100644
--- a/META.yml
+++ b/META.yml
@@ -1,19 +1,8 @@
--- #YAML:1.0
name: Test-Expect
-version: 0.29
+version: 0.30
author:
- Leon Brocard, C<< <acme at astray.com> >>
-abstract: |-
- Automated driving and testing of terminal-based programs
+abstract: Automated driving and testing of terminal-based programs
license: perl
-requires:
- Class::Accessor::Chained::Fast: 0
- Expect::Simple: 0
- Term::ReadLine: 0
- Test::Builder: 0
- Test::More: 0
-provides:
- Test::Expect:
- file: lib/Test/Expect.pm
- version: 0.29
-generated_by: Module::Build version 0.2605
+generated_by: Module::Build version 0.2611, without YAML.pm
diff --git a/README b/README
index 6575322..c6bc42b 100644
--- a/README
+++ b/README
@@ -19,7 +19,8 @@ DESCRIPTION
Test::Expect is a module for automated driving and testing of
terminal-based programs. It is handy for testing interactive programs
which have a prompt, and is based on the same concepts as the Tcl Expect
- tool.
+ tool. As in Expect::Simple, the Expect object is made available for
+ tweaking.
Test::Expect is intended for use in a test script.
@@ -59,6 +60,9 @@ SUBROUTINES
expect_like(qr/Hi there, to testme/, "expect_like");
+ expect_handle
+ This returns the Expect object.
+
SEE ALSO
Expect, Expect::Simple.
diff --git a/lib/Test/Expect.pm b/lib/Test/Expect.pm
index ef7a007..037851a 100644
--- a/lib/Test/Expect.pm
+++ b/lib/Test/Expect.pm
@@ -7,9 +7,10 @@ use Exporter;
use Test::Builder;
use base qw(Class::Accessor::Chained::Fast Exporter);
__PACKAGE__->mk_accessors(qw(program));
-our $VERSION = "0.29";
+our $VERSION = "0.30";
our @EXPORT = qw(
expect_run
+expect_handle
expect_is
expect_like
expect_send
@@ -48,6 +49,8 @@ sub expect_run {
$Test->ok(1, "expect_run");
}
+sub expect_handle { return $expect->expect_handle(); }
+
sub before {
my $before = $expect->before;
$before =~ s/\r//g;
@@ -112,7 +115,8 @@ Test::Expect - Automated driving and testing of terminal-based programs
L<Test::Expect> is a module for automated driving and testing of
terminal-based programs. It is handy for testing interactive programs
which have a prompt, and is based on the same concepts as the Tcl
-Expect tool.
+Expect tool. As in L<Expect::Simple>, the L<Expect> object is made
+available for tweaking.
L<Test::Expect> is intended for use in a test script.
@@ -159,6 +163,10 @@ Test::More's like. It has an optional comment:
expect_like(qr/Hi there, to testme/, "expect_like");
+=head2 expect_handle
+
+This returns the L<Expect> object.
+
=head1 SEE ALSO
L<Expect>, L<Expect::Simple>.
diff --git a/t/simple.t b/t/simple.t
index 99229f3..f5e8b5a 100644
--- a/t/simple.t
+++ b/t/simple.t
@@ -3,7 +3,9 @@ use strict;
use warnings;
use lib 'lib';
use Test::Expect;
-use Test::More tests => 15;
+use Test::More tests => 18;
+
+require_ok('Expect');
ok(1, "True");
@@ -14,6 +16,7 @@ foreach my $filename ('read', 'readline') {
prompt => $filename . ': ',
quit => 'quit',
);
+ isa_ok(expect_handle(), 'Expect');
expect_like(qr/Hi there, to $filename/, "expect_like");
expect_is("* Hi there, to $filename", "expect_is");
expect_send("ping", "expect_send");
commit 01ba84709d7c2827bcaf7800c80479aa755c7599
Author: Léon Brocard <acme at astray.com>
Date: Wed May 7 09:21:00 2008 -0400
import Test-Expect 0.31
diff --git a/CHANGES b/CHANGES
index 6e73c14..3d01bed 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,9 @@
Revision history for Perl module Devel::ebug
+0.31 Wed May 7 10:15:19 BST 2008
+ - add expect_quit method to close the Expect object
+ (patch by Alex Vandiver)
+
0.30 Tue Feb 28 21:54:16 GMT 2006
- added expect_handle to fetch the underlying Expect object
(patch by Kevin Riggle)
diff --git a/META.yml b/META.yml
index 53f3468..4afe8c9 100644
--- a/META.yml
+++ b/META.yml
@@ -1,8 +1,23 @@
---- #YAML:1.0
+---
name: Test-Expect
-version: 0.30
+version: 0.31
author:
- - Leon Brocard, C<< <acme at astray.com> >>
+ - 'Leon Brocard, C<< <acme at astray.com> >>'
abstract: Automated driving and testing of terminal-based programs
license: perl
-generated_by: Module::Build version 0.2611, without YAML.pm
+resources:
+ license: http://dev.perl.org/licenses/
+requires:
+ Class::Accessor::Chained::Fast: 0
+ Expect::Simple: 0
+ Term::ReadLine: 0
+ Test::Builder: 0
+ Test::More: 0
+provides:
+ Test::Expect:
+ file: lib/Test/Expect.pm
+ version: 0.31
+generated_by: Module::Build version 0.280801
+meta-spec:
+ url: http://module-build.sourceforge.net/META-spec-v1.2.html
+ version: 1.2
diff --git a/Makefile.PL b/Makefile.PL
index c514df3..d27dc7a 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -1,17 +1,18 @@
-# Note: this file was auto-generated by Module::Build::Compat version 0.03
+# Note: this file was auto-generated by Module::Build::Compat version 0.2808_01
use ExtUtils::MakeMaker;
WriteMakefile
(
+ 'PL_FILES' => {},
+ 'INSTALLDIRS' => 'site',
'NAME' => 'Test::Expect',
+ 'EXE_FILES' => [],
'VERSION_FROM' => 'lib/Test/Expect.pm',
'PREREQ_PM' => {
+ 'Test::More' => '0',
'Class::Accessor::Chained::Fast' => '0',
- 'Expect::Simple' => '0',
'Term::ReadLine' => '0',
'Test::Builder' => '0',
- 'Test::More' => '0'
- },
- 'INSTALLDIRS' => 'site',
- 'PL_FILES' => {}
+ 'Expect::Simple' => '0'
+ }
)
;
diff --git a/lib/Test/Expect.pm b/lib/Test/Expect.pm
index 037851a..7405f83 100644
--- a/lib/Test/Expect.pm
+++ b/lib/Test/Expect.pm
@@ -7,15 +7,16 @@ use Exporter;
use Test::Builder;
use base qw(Class::Accessor::Chained::Fast Exporter);
__PACKAGE__->mk_accessors(qw(program));
-our $VERSION = "0.30";
-our @EXPORT = qw(
-expect_run
-expect_handle
-expect_is
-expect_like
-expect_send
-expect
-END
+our $VERSION = "0.31";
+our @EXPORT = qw(
+ expect_run
+ expect_handle
+ expect_is
+ expect_like
+ expect_send
+ expect_quit
+ expect
+ END
);
my $Test = Test::Builder->new;
@@ -24,67 +25,72 @@ my $expect;
my $sent;
sub import {
- my $self = shift;
- if (@_) {
- die @_;
- my $package = caller;
- $Test->exported_to($package);
- $Test->plan(@_);
- };
- $Test->no_ending(0);
- $self->export_to_level(1, $self, $_) foreach @EXPORT;
+ my $self = shift;
+ if (@_) {
+ die @_;
+ my $package = caller;
+ $Test->exported_to($package);
+ $Test->plan(@_);
+ }
+ $Test->no_ending(0);
+ $self->export_to_level( 1, $self, $_ ) foreach @EXPORT;
}
sub expect_run {
- my(%conf) = @_;
- $expect = Expect::Simple->new({
- Cmd => "PERL_RL=\"o=0\" " . $conf{command},
- Prompt => $conf{prompt},
- DisconnectCmd => $conf{quit},
- Verbose => 0,
- Debug => 0,
- Timeout => 100
-});
- die $expect->error if $expect->error;
- $Test->ok(1, "expect_run");
+ my (%conf) = @_;
+ $expect = Expect::Simple->new(
+ { Cmd => "PERL_RL=\"o=0\" " . $conf{command},
+ Prompt => $conf{prompt},
+ DisconnectCmd => $conf{quit},
+ Verbose => 0,
+ Debug => 0,
+ Timeout => 100
+ }
+ );
+ die $expect->error if $expect->error;
+ $Test->ok( 1, "expect_run" );
}
sub expect_handle { return $expect->expect_handle(); }
sub before {
- my $before = $expect->before;
- $before =~ s/\r//g;
- $before =~ s/^$sent// if $sent;
- $before =~ s/^\n+//;
- $before =~ s/\n+$//;
- return $before;
+ my $before = $expect->before;
+ $before =~ s/\r//g;
+ $before =~ s/^$sent// if $sent;
+ $before =~ s/^\n+//;
+ $before =~ s/\n+$//;
+ return $before;
}
sub expect_like {
- my($like, $comment) = @_;
- $Test->like(before(), $like, $comment);
+ my ( $like, $comment ) = @_;
+ $Test->like( before(), $like, $comment );
}
sub expect_is {
- my($is, $comment) = @_;
- $Test->is_eq(before(), $is, $comment);
+ my ( $is, $comment ) = @_;
+ $Test->is_eq( before(), $is, $comment );
}
sub expect_send {
- my($send, $comment) = @_;
- $expect->send($send);
- $sent = $send;
- $Test->ok(1, $comment);
+ my ( $send, $comment ) = @_;
+ $expect->send($send);
+ $sent = $send;
+ $Test->ok( 1, $comment );
}
sub expect {
- my($send, $is, $label) = @_;
- expect_send($send, $label);
- expect_is($is, $label);
+ my ( $send, $is, $label ) = @_;
+ expect_send( $send, $label );
+ expect_is( $is, $label );
+}
+
+sub expect_quit {
+ undef $expect;
}
sub END {
- undef $expect;
+ expect_quit;
}
1;
@@ -167,6 +173,10 @@ Test::More's like. It has an optional comment:
This returns the L<Expect> object.
+=head1 expect_quit
+
+Closes the L<Expect> handle.
+
=head1 SEE ALSO
L<Expect>, L<Expect::Simple>.
commit dac18c3ab26d1ead9931fe16a7be788104e23f37
Author: Thomas Sibley <trs at bestpractical.com>
Date: Fri Dec 14 13:57:05 2012 -0500
Escape sent string when used in regex
Otherwise metacharacters in the sent string interfere with the match and
may lead to an invalid regex pattern.
diff --git a/lib/Test/Expect.pm b/lib/Test/Expect.pm
index 7405f83..8b25537 100644
--- a/lib/Test/Expect.pm
+++ b/lib/Test/Expect.pm
@@ -56,7 +56,7 @@ sub expect_handle { return $expect->expect_handle(); }
sub before {
my $before = $expect->before;
$before =~ s/\r//g;
- $before =~ s/^$sent// if $sent;
+ $before =~ s/^\Q$sent\E// if $sent;
$before =~ s/^\n+//;
$before =~ s/\n+$//;
return $before;
commit 5c46e28d9080d96fcf537c6b30f4047cc2737025
Author: Alex Vandiver <alexmv at bestpractical.com>
Date: Thu Apr 2 01:25:45 2015 -0400
Add leading space to PERL_RL environment variable
The PERL_RL environment variable, used by Term::Readline, expects a
leading space; see https://metacpan.org/pod/Term::ReadLine#ENVIRONMENT
Failure to include one makes it impossible to test interactive programs
relying on Term::Readline.
diff --git a/lib/Test/Expect.pm b/lib/Test/Expect.pm
index 8b25537..3f72250 100644
--- a/lib/Test/Expect.pm
+++ b/lib/Test/Expect.pm
@@ -39,7 +39,7 @@ sub import {
sub expect_run {
my (%conf) = @_;
$expect = Expect::Simple->new(
- { Cmd => "PERL_RL=\"o=0\" " . $conf{command},
+ { Cmd => "PERL_RL=\" o=0\" " . $conf{command},
Prompt => $conf{prompt},
DisconnectCmd => $conf{quit},
Verbose => 0,
commit f00e026daed21dd6017b41c01fd95ec1e8554d27
Author: Alex Vandiver <alexmv at bestpractical.com>
Date: Thu Apr 2 01:29:51 2015 -0400
Add a .gitignore
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..a83315b
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,10 @@
+/_build/
+/Build
+/Makefile
+/Makefile.old
+/blib/
+/pm_to_blib
+/Test-Expect-*.tar.gz
+*.bak
+*.swp
+/MYMETA.*
commit 03b28d1b1a03d09b046613830e04f8cddf0773ac
Author: Alex Vandiver <alexmv at bestpractical.com>
Date: Thu Apr 2 01:42:47 2015 -0400
Version 0.32 releng
diff --git a/CHANGES b/CHANGES
index 3d01bed..a8ad85d 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,12 +1,19 @@
-Revision history for Perl module Devel::ebug
+Revision history for Perl module Test::Expect
-0.31 Wed May 7 10:15:19 BST 2008
- - add expect_quit method to close the Expect object
- (patch by Alex Vandiver)
+0.32 2015-04-02
+ - Quote regex meta-characters before using them in a regex (fixes
+ #81987)
+ - Include leading space in PERL_RL variable (fixes #38914)
+ - New maintainer (BPS)
-0.30 Tue Feb 28 21:54:16 GMT 2006
- - added expect_handle to fetch the underlying Expect object
- (patch by Kevin Riggle)
+0.31 2008-05-07
+ - add expect_quit method to close the Expect object (patch by Alex
+ Vandiver)
+
+0.30 2006-02-28
+ - added expect_handle to fetch the underlying Expect object (patch by
+ Kevin Riggle)
+
+0.29 2005-03-30
+ - initial release
-0.29 Wed Mar 30 23:18:02 CST 2005
- - initial release
diff --git a/MANIFEST b/MANIFEST
index b35b194..2ce37ba 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -3,6 +3,7 @@ CHANGES
lib/Test/Expect.pm
Makefile.PL
MANIFEST This list of files
+META.json
META.yml
read
readline
diff --git a/META.json b/META.json
new file mode 100644
index 0000000..678334c
--- /dev/null
+++ b/META.json
@@ -0,0 +1,46 @@
+{
+ "abstract" : "Automated driving and testing of terminal-based programs",
+ "author" : [
+ "Best Practical Solutions, LLC E<lt>modules at bestpractical.comE<gt>",
+ "Original module by Leon Brocard, E<lt>acme at astray.comE<gt>"
+ ],
+ "dynamic_config" : 1,
+ "generated_by" : "Module::Build version 0.4211",
+ "license" : [
+ "perl_5"
+ ],
+ "meta-spec" : {
+ "url" : "http://search.cpan.org/perldoc?CPAN::Meta::Spec",
+ "version" : "2"
+ },
+ "name" : "Test-Expect",
+ "prereqs" : {
+ "configure" : {
+ "requires" : {
+ "Module::Build" : "0.42"
+ }
+ },
+ "runtime" : {
+ "requires" : {
+ "Class::Accessor::Chained::Fast" : "0",
+ "Expect::Simple" : "0",
+ "Term::ReadLine" : "0",
+ "Test::Builder" : "0",
+ "Test::More" : "0"
+ }
+ }
+ },
+ "provides" : {
+ "Test::Expect" : {
+ "file" : "lib/Test/Expect.pm",
+ "version" : "0.32"
+ }
+ },
+ "release_status" : "stable",
+ "resources" : {
+ "license" : [
+ "http://dev.perl.org/licenses/"
+ ]
+ },
+ "version" : "0.32"
+}
diff --git a/META.yml b/META.yml
index 4afe8c9..ba098e2 100644
--- a/META.yml
+++ b/META.yml
@@ -1,23 +1,28 @@
---
-name: Test-Expect
-version: 0.31
+abstract: 'Automated driving and testing of terminal-based programs'
author:
- - 'Leon Brocard, C<< <acme at astray.com> >>'
-abstract: Automated driving and testing of terminal-based programs
+ - 'Best Practical Solutions, LLC E<lt>modules at bestpractical.comE<gt>'
+ - 'Original module by Leon Brocard, E<lt>acme at astray.comE<gt>'
+build_requires: {}
+configure_requires:
+ Module::Build: '0.42'
+dynamic_config: 1
+generated_by: 'Module::Build version 0.4211, CPAN::Meta::Converter version 2.150001'
license: perl
-resources:
- license: http://dev.perl.org/licenses/
-requires:
- Class::Accessor::Chained::Fast: 0
- Expect::Simple: 0
- Term::ReadLine: 0
- Test::Builder: 0
- Test::More: 0
+meta-spec:
+ url: http://module-build.sourceforge.net/META-spec-v1.4.html
+ version: '1.4'
+name: Test-Expect
provides:
Test::Expect:
file: lib/Test/Expect.pm
- version: 0.31
-generated_by: Module::Build version 0.280801
-meta-spec:
- url: http://module-build.sourceforge.net/META-spec-v1.2.html
- version: 1.2
+ version: '0.32'
+requires:
+ Class::Accessor::Chained::Fast: '0'
+ Expect::Simple: '0'
+ Term::ReadLine: '0'
+ Test::Builder: '0'
+ Test::More: '0'
+resources:
+ license: http://dev.perl.org/licenses/
+version: '0.32'
diff --git a/Makefile.PL b/Makefile.PL
index d27dc7a..8b8e45b 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -1,18 +1,18 @@
-# Note: this file was auto-generated by Module::Build::Compat version 0.2808_01
+# Note: this file was auto-generated by Module::Build::Compat version 0.4211
use ExtUtils::MakeMaker;
WriteMakefile
(
- 'PL_FILES' => {},
- 'INSTALLDIRS' => 'site',
- 'NAME' => 'Test::Expect',
- 'EXE_FILES' => [],
- 'VERSION_FROM' => 'lib/Test/Expect.pm',
- 'PREREQ_PM' => {
- 'Test::More' => '0',
- 'Class::Accessor::Chained::Fast' => '0',
- 'Term::ReadLine' => '0',
- 'Test::Builder' => '0',
- 'Expect::Simple' => '0'
- }
- )
+ 'NAME' => 'Test::Expect',
+ 'VERSION_FROM' => 'lib/Test/Expect.pm',
+ 'PREREQ_PM' => {
+ 'Class::Accessor::Chained::Fast' => '0',
+ 'Expect::Simple' => '0',
+ 'Term::ReadLine' => '0',
+ 'Test::Builder' => '0',
+ 'Test::More' => '0'
+ },
+ 'INSTALLDIRS' => 'site',
+ 'EXE_FILES' => [],
+ 'PL_FILES' => {}
+)
;
diff --git a/lib/Test/Expect.pm b/lib/Test/Expect.pm
index 3f72250..a3ac46b 100644
--- a/lib/Test/Expect.pm
+++ b/lib/Test/Expect.pm
@@ -7,7 +7,7 @@ use Exporter;
use Test::Builder;
use base qw(Class::Accessor::Chained::Fast Exporter);
__PACKAGE__->mk_accessors(qw(program));
-our $VERSION = "0.31";
+our $VERSION = "0.32";
our @EXPORT = qw(
expect_run
expect_handle
@@ -173,7 +173,7 @@ Test::More's like. It has an optional comment:
This returns the L<Expect> object.
-=head1 expect_quit
+=head2 expect_quit
Closes the L<Expect> handle.
@@ -183,11 +183,32 @@ L<Expect>, L<Expect::Simple>.
=head1 AUTHOR
-Leon Brocard, C<< <acme at astray.com> >>
+Best Practical Solutions, LLC E<lt>modules at bestpractical.comE<gt>
+
+Original module by Leon Brocard, E<lt>acme at astray.comE<gt>
+
+=head1 BUGS
+
+=for html
+<p>All bugs should be reported via email to
+L<bug-RT-Extension-SLA at rt.cpan.org|mailto:bug-RT-Extension-SLA at rt.cpan.org>
+or via the web at
+L<rt.cpan.org|http://rt.cpan.org/Public/Dist/Display.html?Name=RT-Extension-SLA>.</p>
+
+=for text
+ All bugs should be reported via email to
+ bug-RT-Extension-SLA at rt.cpan.org
+ or via the web at
+ http://rt.cpan.org/Public/Dist/Display.html?Name=RT-Extension-SLA
+
=head1 COPYRIGHT
+This extension is Copyright (C) 2015 Best Practical Solutions, LLC.
+
Copyright (C) 2005, Leon Brocard
This module is free software; you can redistribute it or modify it
under the same terms as Perl itself.
+
+=cut
-----------------------------------------------------------------------
More information about the Bps-public-commit
mailing list