blib/lib/Comics/Plugin/WhatTheDuck.pm untested

filter: Statementstmt 0.0% 0 / 15 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 3 Podpod n/a totaltotal 0.0% 0 / 18 CC 1 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1 #! perl
2  
3 use strict;
4 use warnings;
5  
6 package Comics::Plugin::WhatTheDuck;
7  
8 use parent qw(Comics::Fetcher::Single);
9  
10 our $VERSION = "1.00";
11  
12 our $name = "What the Duck";
13 our $url = "https://www.whattheduck.net/";
14 our $disabled = 1; # stopped
15  
16 our $pattern =
17 qr{ <img \s+
18 src="(?<url>https?://\d+\.media\.tumblr\.com/
19 [0-9a-f]{32}/
20 (?<image>tumblr_.*?_(?:1280|640)\.\w+))" \s+
21 alt="(?<alt>WTD.*?)" \s+
22 width="\d+" \s+
23 height="\d+" \s*
24 >
25 }x;
26  
27 # Important: Return the package name!
28 __PACKAGE__;