summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-05-19 09:52:05 +0800
committerin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-05-19 09:52:05 +0800
commit95fce7fddf6e3d16bc1c07b464976fdfed981366 (patch)
treedbca63e1272d24d9655ab6b38310590768bf45fd
parent0b54f94516ef2b1fcb18233daa9ce488b100ee43 (diff)
downloadpttbbs-95fce7fddf6e3d16bc1c07b464976fdfed981366.tar
pttbbs-95fce7fddf6e3d16bc1c07b464976fdfed981366.tar.gz
pttbbs-95fce7fddf6e3d16bc1c07b464976fdfed981366.tar.bz2
pttbbs-95fce7fddf6e3d16bc1c07b464976fdfed981366.tar.lz
pttbbs-95fce7fddf6e3d16bc1c07b464976fdfed981366.tar.xz
pttbbs-95fce7fddf6e3d16bc1c07b464976fdfed981366.tar.zst
pttbbs-95fce7fddf6e3d16bc1c07b464976fdfed981366.zip
*** empty log message ***
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@869 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--pttpi/cgi/t/.cvsignore1
-rw-r--r--pttpi/cgi/t/1.board.getBid.pl11
-rw-r--r--pttpi/cgi/t/2.getBrdInfo.pl15
-rw-r--r--pttpi/cgi/t/host.pl.sample2
4 files changed, 29 insertions, 0 deletions
diff --git a/pttpi/cgi/t/.cvsignore b/pttpi/cgi/t/.cvsignore
new file mode 100644
index 00000000..9f20a79c
--- /dev/null
+++ b/pttpi/cgi/t/.cvsignore
@@ -0,0 +1 @@
+host.pl
diff --git a/pttpi/cgi/t/1.board.getBid.pl b/pttpi/cgi/t/1.board.getBid.pl
new file mode 100644
index 00000000..04be5b89
--- /dev/null
+++ b/pttpi/cgi/t/1.board.getBid.pl
@@ -0,0 +1,11 @@
+#!/usr/bin/perl
+use Frontier::Client;
+use Data::Dumper;
+do 'host.pl';
+
+$brdname = $ARGV[0] || 'SYSOP';
+$server = Frontier::Client->new(url => $server_url);
+$result = $server->call('board.getBid', $brdname);
+
+print "board.getBid($brdname) from $server_url:\n";
+print Dumper($result);
diff --git a/pttpi/cgi/t/2.getBrdInfo.pl b/pttpi/cgi/t/2.getBrdInfo.pl
new file mode 100644
index 00000000..a0ae95eb
--- /dev/null
+++ b/pttpi/cgi/t/2.getBrdInfo.pl
@@ -0,0 +1,15 @@
+#!/usr/bin/perl
+# $Id: 2.getBrdInfo.pl,v 1.1 2003/05/19 01:52:05 in2 Exp $
+use Frontier::Client;
+use Frontier::RPC2;
+use MIME::Base64;
+use Data::Dumper;
+do 'host.pl';
+
+$bid = $ARGV[0] || 0;
+
+$server = Frontier::Client->new(url => $server_url);
+$result = $server->call('board.getBrdInfo', $bid);
+
+print Dumper($result);
+print decode_base64($result->{title}->value());
diff --git a/pttpi/cgi/t/host.pl.sample b/pttpi/cgi/t/host.pl.sample
new file mode 100644
index 00000000..72669230
--- /dev/null
+++ b/pttpi/cgi/t/host.pl.sample
@@ -0,0 +1,2 @@
+#!/usr/bin/perl
+$server_url = 'http://host_to_pttpi/path_to_pttpi/pttpi.cgi'