summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/version.pm2
-rw-r--r--lib/version/t/01base.t14
-rw-r--r--lib/version/t/02derived.t2
-rw-r--r--lib/version/t/03require.t2
-rw-r--r--lib/version/t/05sigdie.t2
-rw-r--r--lib/version/t/06noop.t2
-rw-r--r--lib/version/t/07locale.t2
7 files changed, 19 insertions, 7 deletions
diff --git a/lib/version.pm b/lib/version.pm
index 286dc790ff..27774bd9c2 100644
--- a/lib/version.pm
+++ b/lib/version.pm
@@ -6,7 +6,7 @@ use strict;
use vars qw(@ISA $VERSION $CLASS $STRICT $LAX *declare *qv);
-$VERSION = 0.9901;
+$VERSION = 0.9902;
$CLASS = 'version';
diff --git a/lib/version/t/01base.t b/lib/version/t/01base.t
index c84531d0c5..9aa8052a30 100644
--- a/lib/version/t/01base.t
+++ b/lib/version/t/01base.t
@@ -9,7 +9,7 @@ use Test::More qw/no_plan/;
BEGIN {
(my $coretests = $0) =~ s'[^/]+\.t'coretests.pm';
require $coretests;
- use_ok('version', 0.9901);
+ use_ok('version', 0.9902);
}
diag "Tests with base class" unless $ENV{PERL_CORE};
@@ -32,3 +32,15 @@ my $v = eval {
return IO::Handle->VERSION;
};
ok defined($v), 'Fix for RT #47980';
+
+{ # https://rt.cpan.org/Ticket/Display.html?id=81085
+ eval { version::new() };
+ like $@, qr'Usage: version::new\(class, version\)',
+ 'No bus err when called as function';
+ eval { $x = 1; print version::new };
+ like $@, qr'Usage: version::new\(class, version\)',
+ 'No implicit object creation when called as function';
+ eval { $x = "version"; print version::new };
+ like $@, qr'Usage: version::new\(class, version\)',
+ 'No implicit object creation when called as function';
+}
diff --git a/lib/version/t/02derived.t b/lib/version/t/02derived.t
index ea683a9bb5..c7afe0f9af 100644
--- a/lib/version/t/02derived.t
+++ b/lib/version/t/02derived.t
@@ -10,7 +10,7 @@ use File::Temp qw/tempfile/;
BEGIN {
(my $coretests = $0) =~ s'[^/]+\.t'coretests.pm';
require $coretests;
- use_ok("version", 0.9901);
+ use_ok("version", 0.9902);
# If we made it this far, we are ok.
}
diff --git a/lib/version/t/03require.t b/lib/version/t/03require.t
index 3d99cb19e4..66c6bd3a85 100644
--- a/lib/version/t/03require.t
+++ b/lib/version/t/03require.t
@@ -14,7 +14,7 @@ BEGIN {
# Don't want to use, because we need to make sure that the import doesn't
# fire just yet (some code does this to avoid importing qv() and delare()).
require_ok("version");
-is $version::VERSION, 0.9901, "Make sure we have the correct class";
+is $version::VERSION, 0.9902, "Make sure we have the correct class";
ok(!"main"->can("qv"), "We don't have the imported qv()");
ok(!"main"->can("declare"), "We don't have the imported declare()");
diff --git a/lib/version/t/05sigdie.t b/lib/version/t/05sigdie.t
index dd785d58b7..188f185587 100644
--- a/lib/version/t/05sigdie.t
+++ b/lib/version/t/05sigdie.t
@@ -15,7 +15,7 @@ BEGIN {
BEGIN {
- use version 0.9901;
+ use version 0.9902;
}
pass "Didn't get caught by the wrong DIE handler, which is a good thing";
diff --git a/lib/version/t/06noop.t b/lib/version/t/06noop.t
index ff556ad214..9d113ed6e4 100644
--- a/lib/version/t/06noop.t
+++ b/lib/version/t/06noop.t
@@ -7,7 +7,7 @@
use Test::More qw/no_plan/;
BEGIN {
- use_ok('version', 0.9901);
+ use_ok('version', 0.9902);
}
my $v1 = version->new('1.2');
diff --git a/lib/version/t/07locale.t b/lib/version/t/07locale.t
index a2005f8a92..3b67f3d77a 100644
--- a/lib/version/t/07locale.t
+++ b/lib/version/t/07locale.t
@@ -11,7 +11,7 @@ use Test::More tests => 7;
use Config;
BEGIN {
- use_ok('version', 0.9901);
+ use_ok('version', 0.9902);
}
SKIP: {