Permalink
Browse files

Item14152: Merge commit '5fcac85155551731f8a04fdd8c667cb93d558497' in…

…to Item14152

* commit '5fcac85155551731f8a04fdd8c667cb93d558497':
  Item13897: OopsException backward compatibility and bug fixes.
  Item13897: Fixed Foswiki::Class incompatibility with perl 5.20 and lower.
  Item13897: Fixed feature :5.14 not been applied sometimes.
  Item13897: Merge of Foswiki::Exception.pm from Item14152
  Item13897: Fixed a problem with @ARGV being emptied.
  Item14150:  Recompute validation keys on cached pages
  • Loading branch information...
2 parents 48c7762 + 5fcac85 commit 2905c84836501ebc77d4d4dd93e1ed3457bf17bb @vrurg vrurg committed Sep 6, 2016
@@ -113,7 +113,7 @@ sub registerCallbacks {
$this->_cbRegistered(1);
}
-before _prepareConfig => sub {
+before BUILD => sub {
my $this = shift;
$this->registerCallbacks;
@@ -31,8 +31,7 @@ use Foswiki::UI::Register();
use Try::Tiny;
use Carp qw(cluck);
-use Moo;
-use namespace::clean;
+use Foswiki::Class;
extends qw(FoswikiTestCase);
has test_user_forename => ( is => 'rw', );
@@ -225,7 +225,7 @@ sub _registerUserException {
},
},
);
- $this->app->net->setMailHandler( \&FoswikiFnTestCase::sentMail );
+ $this->app->net->setMailHandler( $this->can('sentMail') );
my $exception;
try {
$this->captureWithKey(
@@ -252,7 +252,7 @@ sub _registerUserException {
# Reload caches
$this->createNewFoswikiApp;
- $this->app->net->setMailHandler( \&FoswikiFnTestCase::sentMail );
+ $this->app->net->setMailHandler( $this->can('sentMail') );
return $exception;
}
@@ -814,7 +814,7 @@ sub verify_resetEmailOkay {
callbacks => { handleRequestException => \&_cbHRE, },
);
- $this->app->net->setMailHandler( \&FoswikiFnTestCase::sentMail );
+ $this->app->net->setMailHandler( $this->can('sentMail') );
try {
$this->captureWithKey(
manage => sub {
@@ -923,7 +923,7 @@ EOM
callbacks => { handleRequestException => \&_cbHRE, },
);
- $this->app->net->setMailHandler( \&FoswikiFnTestCase::sentMail );
+ $this->app->net->setMailHandler( $this->can('sentMail') );
# SMELL We've set path_info, web and topic must be set from it.
#$req->topic($regTopic);
@@ -1071,7 +1071,7 @@ EOM
callbacks => { handleRequestException => \&_cbHRE, },
);
- $this->app->net->setMailHandler( \&FoswikiFnTestCase::sentMail );
+ $this->app->net->setMailHandler( $this->can('sentMail') );
try {
my ($text) = $this->captureWithKey(
@@ -1133,7 +1133,7 @@ sub verify_deleteUser {
callbacks => { handleRequestException => \&_cbHRE, },
);
- $this->app->net->setMailHandler( \&FoswikiFnTestCase::sentMail );
+ $this->app->net->setMailHandler( $this->can('sentMail') );
try {
$this->captureWithKey(
@@ -1454,7 +1454,7 @@ sub test_createDefaultWeb {
callbacks => { handleRequestException => \&_cbHRE, },
);
- $this->app->net->setMailHandler( \&FoswikiFnTestCase::sentMail );
+ $this->app->net->setMailHandler( $this->can('sentMail') );
try {
my ( $stdout, $stderr, $result ) =
@@ -1837,7 +1837,7 @@ sub test_createEmptyWeb {
callbacks => { handleRequestException => \&_cbHRE, },
);
- $this->app->net->setMailHandler( \&FoswikiFnTestCase::sentMail );
+ $this->app->net->setMailHandler( $this->can('sentMail') );
try {
my ( $stdout, $stderr, $result ) =
Oops, something went wrong.

0 comments on commit 2905c84

Please sign in to comment.