[libclass-virtual-perl] 02/07: Initial revision

dom at earth.li dom at earth.li
Wed Aug 23 14:00:14 UTC 2017


This is an automated email from the git hooks/post-receive script.

dom pushed a commit to tag v0.03
in repository libclass-virtual-perl.

commit 5798d1aa1449e08e5bb99dc43e2b7c1737a69fd6
Author: Michael G. Schwern <schwern at pobox.com>
Date:   Mon Nov 27 07:40:21 2000 +0000

    Initial revision
    
    
    git-svn-id: file:///Users/schwern/tmp/svn/CPAN/Class-Virtual/trunk@2269 8151f2b9-fde8-0310-94fd-f048d12aab9e
---
 MANIFEST             |  0
 Makefile.PL          | 36 +++++++++++++++++++++++++++++++++++
 lib/Class/Virtual.pm |  2 ++
 t/Virtual.t          | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 92 insertions(+)

diff --git a/MANIFEST b/MANIFEST
new file mode 100644
index 0000000..e69de29
diff --git a/Makefile.PL b/Makefile.PL
new file mode 100644
index 0000000..06b0a66
--- /dev/null
+++ b/Makefile.PL
@@ -0,0 +1,36 @@
+# A template for Makefile.PL used by Arena Networks.
+# - Set the $PACKAGE variable to the name of your module.
+# - Set $LAST_API_CHANGE to reflect the last version you changed the API 
+#   of your module.
+# - Fill in your dependencies in PREREQ_PM
+# Alternatively, you can say the hell with this and use h2xs.
+
+use ExtUtils::MakeMaker;
+# See lib/ExtUtils/MakeMaker.pm for details of how to influence
+# the contents of the Makefile that is written.
+
+$PACKAGE = 'Module::Name';
+($PACKAGE_FILE = $PACKAGE) =~ s|::|/|g;
+$LAST_API_CHANGE = 0;
+
+eval "require $PACKAGE";
+
+unless ($@) { # Make sure we did find the module.
+    print <<"CHANGE_WARN" if ${$PACKAGE.'::VERSION'} < $LAST_API_CHANGE;
+
+NOTE: There have been API changes between this version and any older
+than version $LAST_API_CHANGE!  Please read the Changes file if you
+are upgrading from a version older than $LAST_API_CHANGE.
+
+CHANGE_WARN
+}
+
+WriteMakefile(
+    NAME            => $PACKAGE,
+    VERSION_FROM    => "lib/$PACKAGE_FILE.pm", # finds $VERSION
+    PREREQ_PM       => {   },
+    'dist'          => { COMPRESS   => 'gzip -9',
+                         SUFFIX     => '.gz',
+                         DIST_DEFAULT   => 'all tardist',
+                       },
+);
diff --git a/lib/Class/Virtual.pm b/lib/Class/Virtual.pm
new file mode 100644
index 0000000..ea8d5a3
--- /dev/null
+++ b/lib/Class/Virtual.pm
@@ -0,0 +1,2 @@
+package Class::Virtual;
+
diff --git a/t/Virtual.t b/t/Virtual.t
new file mode 100644
index 0000000..7418280
--- /dev/null
+++ b/t/Virtual.t
@@ -0,0 +1,54 @@
+# Before `make install' is performed this script should be runnable with
+# `make test'. After `make install' it should work as `perl test.pl'
+
+######################### We start with some black magic to print on failure.
+
+# Change 1..1 below to 1..last_test_to_print .
+# (It may become useful if the test is moved to ./t subdirectory.)
+use strict;
+
+use vars qw($Total_tests);
+
+my $loaded;
+my $test_num = 1;
+BEGIN { $| = 1; $^W = 1; }
+END {print "not ok $test_num\n" unless $loaded;}
+print "1..$Total_tests\n";
+use Module::Name;
+$loaded = 1;
+ok(1, 'compile');
+######################### End of black magic.
+
+# Utility testing functions.
+sub ok {
+    my($test, $name) = @_;
+    print "not " unless $test;
+    print "ok $test_num";
+    print " - $name" if defined $name;
+    print "\n";
+    $test_num++;
+}
+
+sub eqarray  {
+    my($a1, $a2) = @_;
+    return 0 unless @$a1 == @$a2;
+    my $ok = 1;
+    for (0..$#{$a1}) {
+        my($e1,$e2) = ($a1->[$_], $a2->[$_]);
+        unless($e1 eq $e2) {
+            if( UNIVERSAL::isa($e1, 'ARRAY') and 
+                UNIVERSAL::isa($e2, 'ARRAY') ) 
+            {
+                $ok = eqarray($e1, $e2);
+            }
+            else {
+                $ok = 0;
+            }
+            last unless $ok;
+        }
+    }
+    return $ok;
+}
+
+# Change this to your # of ok() calls + 1
+BEGIN { $Total_tests = 1 }

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libclass-virtual-perl.git



More information about the Pkg-perl-cvs-commits mailing list