[Rt-commit] r9746 - in rt/branches/3.999-DANGEROUS: . lib/RT t/web
jesse at bestpractical.com
jesse at bestpractical.com
Mon Nov 26 14:11:50 EST 2007
Author: jesse
Date: Mon Nov 26 14:11:49 2007
New Revision: 9746
Modified:
rt/branches/3.999-DANGEROUS/ (props changed)
rt/branches/3.999-DANGEROUS/html/Admin/CustomFields/Objects.html
rt/branches/3.999-DANGEROUS/lib/RT/Shredder.pm
rt/branches/3.999-DANGEROUS/lib/RT/Test.pm
rt/branches/3.999-DANGEROUS/t/web/crypt-gnupg.t
rt/branches/3.999-DANGEROUS/t/web/gnupg-outgoing.t
Log:
r71687 at pinglin: jesse | 2007-11-11 20:13:45 -0500
* more tests passing
Modified: rt/branches/3.999-DANGEROUS/html/Admin/CustomFields/Objects.html
==============================================================================
--- rt/branches/3.999-DANGEROUS/html/Admin/CustomFields/Objects.html (original)
+++ rt/branches/3.999-DANGEROUS/html/Admin/CustomFields/Objects.html Mon Nov 26 14:11:49 2007
@@ -68,7 +68,9 @@
<%INIT>
my $CF = RT::Model::CustomField->new($session{'CurrentUser'});
-$CF->load($id) or Abort(loc("Could not load CustomField [_1]"), $id);
+$CF->load($id) if ($id);
+
+unless ($CF->id) { Abort(loc("Could not load CustomField [_1]"), $id)};
my $LookupType = $CF->LookupType || '';
$LookupType =~ /^(.*?)-/ ||
Abort(loc("Object of type [_1] cannot take custom fields", $LookupType));
Modified: rt/branches/3.999-DANGEROUS/lib/RT/Shredder.pm
==============================================================================
--- rt/branches/3.999-DANGEROUS/lib/RT/Shredder.pm (original)
+++ rt/branches/3.999-DANGEROUS/lib/RT/Shredder.pm Mon Nov 26 14:11:49 2007
@@ -553,7 +553,7 @@
};
if( $@ ) {
Jifty->handle->rollback('force');
- $selfJifty->handle->rollbackDumpTo( Mark => $mark ) if $mark;
+ $self->RollbackDumpTo( Mark => $mark ) if $mark;
die $@ if RT::Shredder::Exception::Info->caught;
die "Couldn't wipeout object: $@";
}
@@ -784,10 +784,10 @@
die "Couldn't pop mark: $msg" unless $state;
}
}
-sub rollbackDumpTo {
+sub RollbackDumpTo {
my $self = shift;
foreach (@{ $self->{'dump_plugins'} }) {
- my ($state, $msg) = $_Jifty->handle->rollbackTo( @_ );
+ my ($state, $msg) = $_->rollbackTo( @_ );
die "Couldn't rollback to mark: $msg" unless $state;
}
}
Modified: rt/branches/3.999-DANGEROUS/lib/RT/Test.pm
==============================================================================
--- rt/branches/3.999-DANGEROUS/lib/RT/Test.pm (original)
+++ rt/branches/3.999-DANGEROUS/lib/RT/Test.pm Mon Nov 26 14:11:49 2007
@@ -271,7 +271,8 @@
my $cmd = $RT::BinPath .'/rt-mailgate';
die "Couldn't find mailgate ($cmd) command" unless -f $cmd;
- $cmd .= ' --debug';
+
+ $cmd = $^X . " " .$cmd. ' --debug';
while( my ($k,$v) = each %args ) {
next unless $v;
$cmd .= " --$k '$v'";
Modified: rt/branches/3.999-DANGEROUS/t/web/crypt-gnupg.t
==============================================================================
--- rt/branches/3.999-DANGEROUS/t/web/crypt-gnupg.t (original)
+++ rt/branches/3.999-DANGEROUS/t/web/crypt-gnupg.t Mon Nov 26 14:11:49 2007
@@ -392,7 +392,7 @@
my $key2 = "75E156271DCCF02DDD4A7A8CDF651FA0632C4F50";
ok($user = RT::Model::User->new($RT::system_user));
-ok($user->Load('root'), "Loaded user 'root'");
+ok($user->load('root'), "Loaded user 'root'");
is($user->PreferredKey, $key1, "preferred key is set correctly");
$m->get("$baseurl/Prefs/Other.html");
like($m->content, qr/Preferred key/, "preferred key option shows up in preference");
@@ -407,7 +407,7 @@
$m->submit;
ok($user = RT::Model::User->new($RT::system_user));
-ok($user->Load('root'), "Loaded user 'root'");
+ok($user->load('root'), "Loaded user 'root'");
is($user->PreferredKey, $key2, "preferred key is set correctly to the new value");
$m->get("$baseurl/Prefs/Other.html");
Modified: rt/branches/3.999-DANGEROUS/t/web/gnupg-outgoing.t
==============================================================================
--- rt/branches/3.999-DANGEROUS/t/web/gnupg-outgoing.t (original)
+++ rt/branches/3.999-DANGEROUS/t/web/gnupg-outgoing.t Mon Nov 26 14:11:49 2007
@@ -158,7 +158,7 @@
ok ($id, "got id of a newly created ticket - $id");
my $tick = RT::Model::Ticket->new( $RT::system_user );
- $tick->Load( $id );
+ $tick->load( $id );
ok ($tick->id, "loaded ticket #$id");
my $txn = $tick->Transactions->first;
@@ -179,7 +179,7 @@
ok ($id, "got id of a newly created ticket - $id");
my $tick = RT::Model::Ticket->new( $RT::system_user );
- $tick->Load( $id );
+ $tick->load( $id );
ok ($tick->id, "loaded ticket #$id");
my $txn = $tick->Transactions->first;
@@ -203,7 +203,7 @@
ok ($id, "got id of a newly created ticket - $id");
my $tick = RT::Model::Ticket->new( $RT::system_user );
- $tick->Load( $id );
+ $tick->load( $id );
ok ($tick->id, "loaded ticket #$id");
my $txn = $tick->Transactions->first;
@@ -226,7 +226,7 @@
ok ($id, "got id of a newly created ticket - $id");
my $tick = RT::Model::Ticket->new( $RT::system_user );
- $tick->Load( $id );
+ $tick->load( $id );
ok ($tick->id, "loaded ticket #$id");
my $txn = $tick->Transactions->first;
More information about the Rt-commit
mailing list