LinkEmbedder/Link/Webex.pm untested

filter: Statementstmt 0.0% 0 / 17 Branchbran 0.0% 0 / 2 Conditioncond 0.0% 0 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 0.0% 0 / 2 Podpod 0.0% 0 / 1 totaltotal 0.0% 0 / 27 CC 2 SCAR 15.4
CC
2
Cov
0%
learn_p
6.0
BEGIN
2.0
CRAP 4.7
1 package LinkEmbedder::Link::Webex;
2 use Mojo::Base 'LinkEmbedder::Link';
3  
4 has provider_name => 'Webex';
5 has provider_url => sub { Mojo::URL->new('https://webex.com') };
6  
7 sub learn_p {
8 my $self = shift;
9 my $path = $self->url->path;
10 return $self->SUPER::learn_p unless @$path == 2 and $path->[0] eq 'meet';
11  
12 $self->{iframe_src} = $self->url;
13 $self->type('rich');
14 $self->title("Join the room $path->[1]");
15 $self->template([__PACKAGE__, 'webex.html.ep']);
16  
17 return Mojo::Promise->new->resolve($self);
18 }
19  
20 1;
21  
22 __DATA__