[svn:PHP-Sandwich] rev 983 - PHP-Sandwich/trunk/t

[email protected] 14 Apr 2005 18:35:51 -0000
Newsgroups perl.php.sandwich.dev
Message-ID <[email protected]>
Author: gschlossnagle
Date: Thu Apr 14 11:35:50 2005
New Revision: 983

Added:
   PHP-Sandwich/trunk/t/3.pl   (contents, props changed)
   PHP-Sandwich/trunk/t/4.pl   (contents, props changed)
   PHP-Sandwich/trunk/t/5.pl   (contents, props changed)
Removed:
   PHP-Sandwich/trunk/t/2.pl
Modified:
   PHP-Sandwich/trunk/t/1.pl
Log:
new tests

Modified: PHP-Sandwich/trunk/t/1.pl
==============================================================================
--- PHP-Sandwich/trunk/t/1.pl	(original)
+++ PHP-Sandwich/trunk/t/1.pl	Thu Apr 14 11:35:50 2005
@@ -1,4 +1,8 @@
 #!/opt/ecelerity/3rdParty/bin/perl 
+
+# Test 2 simultaneous interpreters.  Requires TSRM patch and
+# --enable-maintainer-zts build
+
 use PHP;
 $p = new PHP::Interpreter();
 $p2 = new PHP::Interpreter();

Added: PHP-Sandwich/trunk/t/3.pl
==============================================================================
--- (empty file)
+++ PHP-Sandwich/trunk/t/3.pl	Thu Apr 14 11:35:50 2005
@@ -0,0 +1,14 @@
+use strict;
+use Test;
+
+BEGIN { plan tests => 1 }
+
+use PHP;
+use PHP::Interpreter;
+
+print "# Testing passing Perl AVs to PHP functions.\n";
+
+$p = new PHP::Interpreter();
+$p->eval('function dump($a) { ; }');
+@list = ('I', 'AM', 'AN', 'ARRAY');
+$arg = $p->dump(\@list);

Added: PHP-Sandwich/trunk/t/4.pl
==============================================================================
--- (empty file)
+++ PHP-Sandwich/trunk/t/4.pl	Thu Apr 14 11:35:50 2005
@@ -0,0 +1,9 @@
+#!/opt/ecelerity/3rdParty/bin/perl 
+use PHP;
+use PHP::Interpreter;
+
+$p = new PHP::Interpreter();
+$p->eval('function dump($a) { var_dump($a); }');
+$hash = { 'a' => 'alpha', 'b' => 'beta', 'c' => 'charlie' };
+$arg = $p->dump($hash);
+

Added: PHP-Sandwich/trunk/t/5.pl
==============================================================================
--- (empty file)
+++ PHP-Sandwich/trunk/t/5.pl	Thu Apr 14 11:35:50 2005
@@ -0,0 +1,9 @@
+#!/opt/ecelerity/3rdParty/bin/perl 
+use PHP;
+use PHP::Interpreter;
+
+$p = new PHP::Interpreter();
+$p->eval('function dump($a) { var_dump($a); }');
+@sublist = ( 'NESTED', 'ARRAY');
+@list = ('I', 'AM', 'AN', \@sublist);
+$arg = $p->dump(\@list);