Author: tewk
Date: Fri Dec  5 08:18:43 2008
New Revision: 33513

Added:
   trunk/ext/SQLite3/t/
Modified:
   trunk/ext/SQLite3/Makefile.PL
   trunk/ext/SQLite3/Makefile.in
   trunk/ext/SQLite3/test.p6

Log:
[sqlite] make all and make test


Modified: trunk/ext/SQLite3/Makefile.PL
==============================================================================
--- trunk/ext/SQLite3/Makefile.PL       (original)
+++ trunk/ext/SQLite3/Makefile.PL       Fri Dec  5 08:18:43 2008
@@ -1,3 +1,4 @@
+use lib '../../lib';
 use Parrot::Configure;
 my $pc = Parrot::Configure->new();
 $pc->data->slurp();

Modified: trunk/ext/SQLite3/Makefile.in
==============================================================================
--- trunk/ext/SQLite3/Makefile.in       (original)
+++ trunk/ext/SQLite3/Makefile.in       Fri Dec  5 08:18:43 2008
@@ -64,6 +64,15 @@
 .c$(O) :
        @$(CC) "" $(CFLAGS) -I$(@D) @[EMAIL PROTECTED]@ -c $<
 
+
+all :
+       cd ../..; make perl6
+       cd ../../compilers/ncigen/; ../../parrot 
../../languages/perl6/perl6.pbc gen_sqlite3.pl /usr/include/sqlite3.h > 
../../ext/SQLite3/genSQLite3.pir
+
+test:
+       ../../parrot ../../languages/perl6/perl6.pbc test.p6
+       
+
 $(SHARED_LIB) : $(C_FILES)
        $(MKPATH) @blib_dir@
        $(CC) $(CC_INC) $(LD_SHARE_FLAGS) $(LDFLAGS) @[EMAIL PROTECTED]@ \
@@ -71,7 +80,6 @@
                $(C_FILES) $(C_LIBS) $(ICU_SHARED)
 #CONDITIONED_LINE(win32):      if exist [EMAIL PROTECTED] mt.exe -nologo 
-manifest [EMAIL PROTECTED] -outputresource:$@;2
 
-all : $(SHARED_LIB)
 
 clean : 
        $(RM_F) $(SHARED_LIB) @blib_dir@ $(O_FILES) Makefile

Modified: trunk/ext/SQLite3/test.p6
==============================================================================
--- trunk/ext/SQLite3/test.p6   (original)
+++ trunk/ext/SQLite3/test.p6   Fri Dec  5 08:18:43 2008
@@ -1,6 +1,10 @@
 # Andy the time-strapped test fairy says:
 # If this were Perl 5, I'd put in tests roughly like the following:
 use DBDI;
+use Test;
+
+plan 1;
+
 my $conn = DBDI::DriverManager.getConnection("dbdi:SQLite3:test.db", "", "");
 ### isa_ok($conn, 'DBDI::DriverManager');
 my $stm = $conn.createStatement();
@@ -19,7 +23,9 @@
 my $stm2 = $conn.createStatement();
 my $rs = $stm2.executeQuery("SELECT baz, bar FROM foo");
 while ($rs.next()) {
-    say $rs.getCol(1);
-    say $rs.getCol("baz");
+    if (($rs.getCol(1) eq "Thingy") && ($rs.getCol("baz") = 123)) {
+        ok(1, 'select equals insert');
+    }
 }
-### Check that we got back exactly one row.
+
+# vim: ft=perl6:

Reply via email to