Преглед изворни кода

Fix #74, remove t/ dep from module meta

George S. Baugh пре 10 година
родитељ
комит
6c3270d1f1
5 измењених фајлова са 7 додато и 5 уклоњено
  1. 1 1
      bin/testrail-report
  2. 2 0
      dist.ini
  3. 1 1
      lib/Test/Rail/Harness.pm
  4. 1 1
      lib/Test/Rail/Parser.pm
  5. 2 2
      lib/TestRail/Utils.pm

+ 1 - 1
bin/testrail-report

@@ -156,7 +156,7 @@ TestRail::Utils::interrogateUser(\%opts,qw{apiurl user password project run});
 $opts{result_options} = {'version' => $opts{version}} if $opts{version};
 
 if ($opts{'mock'}) {
-    require Test::LWP::UserAgent::TestRailMock;
+    require 't/lib/Test/LWP/UserAgent/TestRailMock.pm'; ## no critic
     $opts{'browser'} = $Test::LWP::UserAgent::TestRailMock::mockObject;
     $opts{'debug'} = 1;
 }

+ 2 - 0
dist.ini

@@ -122,6 +122,8 @@ stopwords = findRuns
 stopwords = findTests
 stopwords = assignee
 stopwords = parseConfig
+stopwords = getPlanSummary
+stopwords = getRunSummary
 
 [PkgVersion]
 [AutoPrereqs]

+ 1 - 1
lib/Test/Rail/Harness.pm

@@ -63,7 +63,7 @@ sub make_parser {
 
     #for Testability of plugin
     if ($ENV{'TESTRAIL_MOCKED'}) {
-        require Test::LWP::UserAgent::TestRailMock;
+        require 't/lib/Test/LWP/UserAgent/TestRailMock.pm'; ## no critic
         $args->{'debug'} = 1;
         $args->{'browser'} = $Test::LWP::UserAgent::TestRailMock::mockObject;
     }

+ 1 - 1
lib/Test/Rail/Parser.pm

@@ -51,7 +51,7 @@ Get the TAP Parser ready to talk to TestRail, and register a bunch of callbacks
 
 =item B<debug> - BOOLEAN: Print a bunch of extra messages
 
-=item B<browser> - OBJECT: Something like an LWP::UserAgent.  Useful for mocking with L<Test::LWP::UserAgent::TestRailMock>.
+=item B<browser> - OBJECT: Something like an LWP::UserAgent.  Useful for mocking.
 
 =item B<run> - STRING (semi-optional): name of desired run. Required if run_id not passed.
 

+ 2 - 2
lib/TestRail/Utils.pm

@@ -216,7 +216,7 @@ Convenience method for binaries and testing.
 Returns a new TestRail::API when passed an options hash such as is built by most of the binaries,
 or returned by parseConfig.
 
-Has a special 'mock' hash key that can only be used by those testing this distribution.
+Has a special 'mock' hash key that can only be used by those testing this distribution during 'make test'.
 
 =cut
 
@@ -227,7 +227,7 @@ sub getHandle {
     my $tr = TestRail::API->new($opts->{apiurl},$opts->{user},$opts->{password},$opts->{'encoding'},$opts->{'debug'});
     if ($opts->{'mock'}) {
         use lib 't/lib'; #Unit tests will always run from the main dir during make test
-        require Test::LWP::UserAgent::TestRailMock;
+        require 't/lib/Test/LWP/UserAgent/TestRailMock.pm'; ## no critic
         $tr->{'browser'} = $Test::LWP::UserAgent::TestRailMock::mockObject;
         $tr->{'debug'} = 0;
     }