Skip to content
Browse files

Parametrise the summary url for easier testing

  • Loading branch information...
1 parent 421f631 commit dca617810bff9882e7c87edf4d25a28d497db92f @rafl rafl committed with oalders Jan 15, 2012
Showing with 6 additions and 2 deletions.
  1. +6 −2 lib/MetaCPAN/Script/Tickets.pm
View
8 lib/MetaCPAN/Script/Tickets.pm
@@ -10,7 +10,11 @@ use namespace::autoclean;
with 'MooseX::Getopt', 'MetaCPAN::Role::Common';
-my $rt_summary_url = 'https://rt.cpan.org/Public/bugs-per-dist.tsv';
+has rt_summary_url => (
+ is => 'ro',
+ required => 1,
+ default => 'https://rt.cpan.org/Public/bugs-per-dist.tsv',
+);
sub run {
my ($self) = @_;
@@ -23,7 +27,7 @@ sub retrieve_bug_summary {
my ($self) = @_;
my $ua = LWP::UserAgent->new;
- my $resp = $ua->request(GET $rt_summary_url);
+ my $resp = $ua->request(GET $self->rt_summary_url);
confess $resp->reason unless $resp->is_success;

0 comments on commit dca6178

Please sign in to comment.
Something went wrong with that request. Please try again.