Added test files for SDL::Events.pm
Kartik Thakore [Wed, 28 Oct 2009 14:18:32 +0000 (10:18 -0400)]
t/core_events.t [new file with mode: 0644]

diff --git a/t/core_events.t b/t/core_events.t
new file mode 100644 (file)
index 0000000..d189e22
--- /dev/null
@@ -0,0 +1,51 @@
+#!/usr/bin/perl -w
+use strict;
+use SDL;
+use Test::More;
+
+plan ( tests => 4 );
+
+my @done =qw/ none /;
+
+
+SKIP:
+{
+skip 'Not implemented', 2; 
+use_ok( 'SDL::Events' ); 
+can_ok ('SDL::Events', @done); 
+}
+
+my @left = qw/
+pumpevents 
+peepevents 
+pollevent 
+waitevent 
+pushevent 
+seteventfilter 
+eventstate 
+getkeystate 
+getmodstate 
+setmodstate 
+getkeyname 
+enableunicode 
+enablekeyrepeat 
+getmousestate 
+getrelativemousestate 
+getappstate 
+joystickeventstate 
+StartTextInput 
+StopTextInput 
+SetTextInputRect 
+/;
+
+my $why = '[Percentage Completion] '.int( 100 * $#done / ($#done + $#left) ) ."\% implementation. $#done / ".($#done+$#left); 
+
+TODO:
+{
+       local $TODO = $why;
+       pass "\nThe following functions:\n".join ",", @left; 
+}
+       if( $done[0] eq 'none'){ diag '0% done 0/'.$#left } else { diag  $why} 
+
+
+pass 'Are we still alive? Checking for segfaults';