Browse Source

Stop setting NOHUP, and stop stubbing prerequisites in the libravatar test

Both programs set $ENV{NOHUP} so that a bulk edit would not restart the
server.  The only reader of it was restart_parent(), which went when
restarting moved to tPSGI, and nothing in either tree reads it now.

The libravatar test put nine prerequisites into %INC before loading
Trog::Auth, as stand-ins for modules missing from the machine it was
written on.  Makefile.PL requires every one of them, so the test now
loads the real ones, as the other tests do.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
troglodyne-bot 6 days ago
parent
commit
2156ba81a1
3 changed files with 0 additions and 23 deletions
  1. 0 3
      bin/tcms-useradd
  2. 0 3
      bin/tcmslogin
  3. 0 17
      t/Trog-Auth-libravatar.t

+ 0 - 3
bin/tcms-useradd

@@ -17,9 +17,6 @@ use Trog::Log;
 use Trog::Data;
 use Trog::Config;
 
-# Don't murder our terminal when done
-$ENV{NOHUP} = 1;
-
 =head1 SYNOPSIS
 
 Add or edit a tCMS user.  In the event of a user edit, every option save for user is optional,

+ 0 - 3
bin/tcmslogin

@@ -14,9 +14,6 @@ use IO::Prompter();
 use Trog::Auth;
 use Trog::Log;
 
-# Don't murder our terminal when done
-$ENV{NOHUP} = 1;
-
 =head1 SYNOPSIS
 
 Log a user in and print the resulting session cookie, so that you can hand it

+ 0 - 17
t/Trog-Auth-libravatar.t

@@ -8,23 +8,6 @@ use Test::MockModule qw{strict};
 
 use FindBin::libs;
 
-# Stub modules absent from the test environment before loading Trog::Auth
-BEGIN {
-    # Logging stubs -- Log::Dispatch family not installed in test env
-    $INC{'Log/Dispatch.pm'}            = 1;
-    $INC{'Log/Dispatch/DBI.pm'}        = 1;
-    $INC{'Log/Dispatch/Screen.pm'}     = 1;
-    $INC{'Log/Dispatch/FileRotate.pm'} = 1;
-    $INC{'Trog/Log/DBI.pm'}            = 1;
-
-    # Other missing optional deps
-    $INC{'HTTP/Tiny/UNIX.pm'} = 1;
-    $INC{'File/LibMagic.pm'}  = 1;
-    $INC{'Imager/QRCode.pm'}  = 1;
-    $INC{'Config/Simple.pm'}  = 1;
-
-}
-
 require_ok('Trog::Auth') or BAIL_OUT("Can't load Trog::Auth");
 
 subtest 'users_with_emails -- no rows returned' => sub {