X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=rt%2Ft%2Fweb%2Ftransaction_batch.t;h=12d01fba481cd6cbdc8df73b7b1898e88e193336;hb=de9d037528895f7151a9aead6724ce2df95f9586;hp=ae04e1fcabd4eb8542ab53af9153d258a418de1b;hpb=f3c4966ed1f6ec3db7accd6dcdd3a5a3821d72a7;p=freeside.git diff --git a/rt/t/web/transaction_batch.t b/rt/t/web/transaction_batch.t index ae04e1fca..12d01fba4 100644 --- a/rt/t/web/transaction_batch.t +++ b/rt/t/web/transaction_batch.t @@ -12,7 +12,14 @@ my ($val, $msg) =$s1->Create( Queue => $q->Id, ScripAction => 'User Defined', CustomIsApplicableCode => 'return ($self->TransactionObj->Field||"") eq "TimeEstimated"', CustomPrepareCode => 'return 1', - CustomCommitCode => '$self->TicketObj->SetPriority($self->TicketObj->Priority + 2); return 1;', + CustomCommitCode => ' +if ( $self->TicketObj->CurrentUser->Name ne "RT_System" ) { + warn "Ticket obj has incorrect CurrentUser (should be RT_System) ".$self->TicketObj->CurrentUser->Name +} +if ( $self->TicketObj->QueueObj->CurrentUser->Name ne "RT_System" ) { + warn "Queue obj has incorrect CurrentUser (should be RT_System) ".$self->TicketObj->QueueObj->CurrentUser->Name +} +$self->TicketObj->SetPriority($self->TicketObj->Priority + 2); return 1;', Template => 'Blank', Stage => 'TransactionBatch', );