diff options
author | Tom Feist <shabble@metavore.org> | 2011-02-28 20:53:15 +0000 |
---|---|---|
committer | Tom Feist <shabble@metavore.org> | 2011-02-28 20:53:15 +0000 |
commit | fa7b4c4482f718ffbcbfe580c37f9c2f2067ec43 (patch) | |
tree | 3bc26cd3b873cd91d77067835206db27d4651e6a /testing/test2.pl | |
parent | refactor everything to make tests more test-like. (diff) | |
download | irssi-scripts-fa7b4c4482f718ffbcbfe580c37f9c2f2067ec43.tar.gz irssi-scripts-fa7b4c4482f718ffbcbfe580c37f9c2f2067ec43.zip |
added other tests
Diffstat (limited to '')
-rwxr-xr-x | testing/test2.pl | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/testing/test2.pl b/testing/test2.pl new file mode 100755 index 0000000..661e66b --- /dev/null +++ b/testing/test2.pl @@ -0,0 +1,38 @@ +#!/usr/bin/env perl + +use strict; +use warnings; + +use feature qw/say/; + +use lib 'blib/lib'; + +use Test::Irssi; + +my $tester = Test::Irssi->new + (irssi_binary => "/opt/stow/repo/irssi-debug/bin/irssi", + irssi_homedir => $ENV{HOME} . "/projects/tmp/test/irssi-debug"); + +my $test = $tester->new_test('test2'); +$test->add_input_sequence("/echo 'Window one'\n"); +$test->add_delay(5); +$test->add_input_sequence("/window new hide\n"); +$test->add_input_sequence("/win 2\n"); +for (1..10) { + $test->add_input_sequence($_); + $test->add_delay(0.2); +} +$test->add_input_sequence("\x01/echo \x05\n"); +$test->add_delay(10); +$test->add_input_sequence("\x1b\x31"); +$test->add_delay(10); +#$test->add_input_sequence("This is\x0acursor movement\x0a"); +# $test->add_delay(5); + + + +# $test->add_expected_output("Hello"); + + + +$tester->run; |