Skip to content

Commit

Permalink
Skip t/36-email.t
Browse files Browse the repository at this point in the history
Need to figure out a new testing strategy here. [[User:Perlwikibot testing]]
was created with a confirmed email so you could send emails to it. The
account was then locked (in CentralAuth), but this still permitted emails
to be sent. MediaWiki no longer allows this. We need to figure out another
plan.
  • Loading branch information
doherty committed Jul 3, 2016
1 parent 049c202 commit f57da25
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions t/36-email.t
Expand Up @@ -6,9 +6,12 @@ use Test::More;
use MediaWiki::Bot;
my $t = __FILE__;

plan $ENV{PWPUsername} && $ENV{PWPPassword}
? ( tests => 1 )
: ( skip_all => q{I can't log in without credentials} );
# Need to figure out a new testing strategy here. [[User:Perlwikibot testing]]
# was created with a confirmed email so you could send emails to it. The
# account was then locked (in CentralAuth), but this still permitted emails
# to be sent. MediaWiki no longer allows this. We need to figure out another
# plan.
plan skip_all => "Can't email locked accounts";

my $bot = MediaWiki::Bot->new({
agent => "MediaWiki::Bot tests (https://metacpan.org/MediaWiki::Bot; $t)",
Expand All @@ -22,4 +25,4 @@ my $res = $bot->email('User:Perlwikibot testing', "MediaWiki::Bot test $rand", $
ok($res, 'Sending an email succeeded') or diag explain $bot->{error};
note 'This test sent an email to [[User:Perlwikibot testing]].';
note 'The email registered for this account is perlwikibot@mailinator.com';
note 'You can find the inbox at https://perlwikibot.mailinator.com';
note 'You can find the inbox at https://mailinator.com/inbox2.jsp?public_to=perlwikibot';

0 comments on commit f57da25

Please sign in to comment.