[Rt-commit] rt branch, 4.4/shredder-user-uid, repushed
Craig Kaiser
craig at bestpractical.com
Wed Jun 6 17:38:35 EDT 2018
The branch 4.4/shredder-user-uid was deleted and repushed:
was f733d258269e28b40772e3f878c1a4dda3a19f3f
now 63a2cd6ef5c26e2c24359c647883cae1816bba05
1: c8d34c2db ! 1: ad7b7c816 Add test to hit shredder web UI
@@ -12,17 +12,15 @@
+use strict;
+use warnings;
+
-+use RT::Test tests => 9;
++use RT::Test;
+
-+my $test = 'RT::Test';
-+
-+my $config = RT::Config;
-+$config->Set('ShredderStoragePath', $test->temp_directory);
++RT::Config->Set('ShredderStoragePath', RT::Test->temp_directory);
+
+my ( $baseurl, $agent ) = RT::Test->started_ok;
+
+diag("Test server running at $baseurl");
+
++my $ticket_id;
+{
+ $agent->login('root' => 'password');
+ is( $agent->status, 200, "Fetched the page ok");
@@ -30,9 +28,10 @@
+ my $ticket = RT::Test->create_ticket( Subject => 'test shredder', Queue => 1, );
+ ok( $ticket->Id, "created new ticket" );
+
-+ # Shredder will throw a warning if we do not call this
-+ $ticket->ApplyTransactionBatch;
++ $ticket_id = $ticket->id;
++}
+
++{
+ $agent->get($baseurl . '/Admin/Tools/Shredder/?Plugin=Tickets&Tickets%3Aquery=id%3D1&Search=Search');
+
+ # Select the ticket object and wipe it out
@@ -40,8 +39,9 @@
+ $agent->current_form->find_input('WipeoutObject')->check;
+ $agent->click_button(name => 'Wipeout');
+
-+ my ($ret, $msg) = $ticket->Load(1);
-+ is $ret, undef, 'Ticket successfully deleted';
++ my $ticket = RT::Ticket->new(RT->SystemUser);
++ my ($ret, $msg) = $ticket->Load($ticket_id);
++ is ( $ret, undef, 'Ticket successfully deleted' );
+}
+
+done_testing();
2: f733d2582 = 2: 63a2cd6ef Restrict Name checks to RT::User objects when shredding
More information about the rt-commit
mailing list