[Rt-commit] r12842 - in rt/branches/3.8-TESTING: . lib/t t/data/emails t/data/emails/8859-15-message-series t/data/gnupg/emails t/data/gnupg/keyrings t/data/mail t/data/mails t/mail t/web
alexmv at bestpractical.com
alexmv at bestpractical.com
Tue Jun 3 13:34:27 EDT 2008
Author: alexmv
Date: Tue Jun 3 13:34:26 2008
New Revision: 12842
Added:
rt/branches/3.8-TESTING/t/data/emails/
rt/branches/3.8-TESTING/t/data/emails/8859-15-message-series/
- copied from r10964, /rt/branches/3.8-TESTING/lib/t/data/8859-15-message-series/
rt/branches/3.8-TESTING/t/data/emails/crashes-file-based-parser
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/crashes-file-based-parser
rt/branches/3.8-TESTING/t/data/emails/lorem-ipsum
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/lorem-ipsum
rt/branches/3.8-TESTING/t/data/emails/multipart-alternative-with-umlaut
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/multipart-alternative-with-umlaut
rt/branches/3.8-TESTING/t/data/emails/multipart-report
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/multipart-report
rt/branches/3.8-TESTING/t/data/emails/nested-mime-sample
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/nested-mime-sample
rt/branches/3.8-TESTING/t/data/emails/nested-rfc-822
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/nested-rfc-822
rt/branches/3.8-TESTING/t/data/emails/new-ticket-from-iso-8859-1
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/new-ticket-from-iso-8859-1
rt/branches/3.8-TESTING/t/data/emails/new-ticket-from-iso-8859-1-full
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/new-ticket-from-iso-8859-1-full
rt/branches/3.8-TESTING/t/data/emails/notes-uuencoded
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/notes-uuencoded
rt/branches/3.8-TESTING/t/data/emails/rt-send-cc
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/rt-send-cc
rt/branches/3.8-TESTING/t/data/emails/russian-subject-no-content-type
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/russian-subject-no-content-type
rt/branches/3.8-TESTING/t/data/emails/subject-with-folding-ws
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/subject-with-folding-ws
rt/branches/3.8-TESTING/t/data/emails/text-html-in-russian
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/text-html-in-russian
rt/branches/3.8-TESTING/t/data/emails/text-html-with-umlaut
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/text-html-with-umlaut
rt/branches/3.8-TESTING/t/data/emails/very-long-subject
- copied unchanged from r10964, /rt/branches/3.8-TESTING/lib/t/data/very-long-subject
rt/branches/3.8-TESTING/t/data/gnupg/emails/
- copied from r10964, /rt/branches/3.8-TESTING/t/data/mails/gnupg-basic-set/
rt/branches/3.8-TESTING/t/data/gnupg/keyrings/
- copied from r10964, /rt/branches/3.8-TESTING/lib/t/data/crypt-gnupg/
Removed:
rt/branches/3.8-TESTING/lib/t/
rt/branches/3.8-TESTING/t/data/mail/
rt/branches/3.8-TESTING/t/data/mails/
Modified:
rt/branches/3.8-TESTING/ (props changed)
rt/branches/3.8-TESTING/t/mail/crypt-gnupg.t
rt/branches/3.8-TESTING/t/mail/gnupg-bad.t
rt/branches/3.8-TESTING/t/mail/gnupg-incoming.t
rt/branches/3.8-TESTING/t/mail/gnupg-realmail.t
rt/branches/3.8-TESTING/t/mail/gnupg-reverification.t
rt/branches/3.8-TESTING/t/mail/sendmail.t
rt/branches/3.8-TESTING/t/shredder/utils.pl
rt/branches/3.8-TESTING/t/web/command_line.t
Log:
r32444 at kohr-ah: chmrr | 2008-06-03 13:34:06 -0400
* Gut lib/t/ and re-jigger t/data/ to make more sense.
Modified: rt/branches/3.8-TESTING/t/mail/crypt-gnupg.t
==============================================================================
--- rt/branches/3.8-TESTING/t/mail/crypt-gnupg.t (original)
+++ rt/branches/3.8-TESTING/t/mail/crypt-gnupg.t Tue Jun 3 13:34:26 2008
@@ -17,7 +17,7 @@
use File::Spec ();
use Cwd;
-my $homedir = File::Spec->catdir( cwd(), qw(lib t data crypt-gnupg) );
+my $homedir = File::Spec->catdir( cwd(), qw(t data gnupg keyrings) );
mkdir $homedir;
use_ok('RT::Crypt::GnuPG');
Modified: rt/branches/3.8-TESTING/t/mail/gnupg-bad.t
==============================================================================
--- rt/branches/3.8-TESTING/t/mail/gnupg-bad.t (original)
+++ rt/branches/3.8-TESTING/t/mail/gnupg-bad.t Tue Jun 3 13:34:26 2008
@@ -14,7 +14,7 @@
use Cwd 'getcwd';
-my $homedir = File::Spec->catdir( getcwd(), qw(lib t data crypt-gnupg) );
+my $homedir = File::Spec->catdir( getcwd(), qw(t data gnupg keyrings) );
RT->Config->Set( LogToScreen => 'debug' );
RT->Config->Set( 'GnuPG',
Modified: rt/branches/3.8-TESTING/t/mail/gnupg-incoming.t
==============================================================================
--- rt/branches/3.8-TESTING/t/mail/gnupg-incoming.t (original)
+++ rt/branches/3.8-TESTING/t/mail/gnupg-incoming.t Tue Jun 3 13:34:26 2008
@@ -17,7 +17,7 @@
use String::ShellQuote 'shell_quote';
use IPC::Run3 'run3';
-my $homedir = File::Spec->catdir( getcwd(), qw(lib t data crypt-gnupg) );
+my $homedir = File::Spec->catdir( getcwd(), qw(t data gnupg keyrings) );
# catch any outgoing emails
unlink "t/mailbox";
Modified: rt/branches/3.8-TESTING/t/mail/gnupg-realmail.t
==============================================================================
--- rt/branches/3.8-TESTING/t/mail/gnupg-realmail.t (original)
+++ rt/branches/3.8-TESTING/t/mail/gnupg-realmail.t Tue Jun 3 13:34:26 2008
@@ -69,7 +69,7 @@
my ($eid, $usage, $format, $attachment) = @_;
diag "email_ok $eid: $usage, $format, $attachment" if $ENV{'TEST_VERBOSE'};
- my ($file) = glob("t/data/mails/gnupg-basic-set/$eid-*");
+ my ($file) = glob("t/data/gnupg/emails/$eid-*");
my $mail = RT::Test->file_content($file);
my ($status, $id) = RT::Test->send_via_mailgate($mail);
Modified: rt/branches/3.8-TESTING/t/mail/gnupg-reverification.t
==============================================================================
--- rt/branches/3.8-TESTING/t/mail/gnupg-reverification.t (original)
+++ rt/branches/3.8-TESTING/t/mail/gnupg-reverification.t Tue Jun 3 13:34:26 2008
@@ -49,7 +49,7 @@
my @ticket_ids;
-my @files = glob("t/data/mails/gnupg-basic-set/*-signed-*");
+my @files = glob("t/data/gnupg/emails/*-signed-*");
foreach my $file ( @files ) {
diag "testing $file" if $ENV{'TEST_VERBOSE'};
Modified: rt/branches/3.8-TESTING/t/mail/sendmail.t
==============================================================================
--- rt/branches/3.8-TESTING/t/mail/sendmail.t (original)
+++ rt/branches/3.8-TESTING/t/mail/sendmail.t Tue Jun 3 13:34:26 2008
@@ -45,7 +45,7 @@
# Let's test to make sure a multipart/report is processed correctly
-my $content = RT::Test->file_content("$RT::BasePath/lib/t/data/multipart-report");
+my $content = RT::Test->file_content("t/data/emails/multipart-report");
# be as much like the mail gateway as possible.
use RT::Interface::Email;
my %args = (message => $content, queue => 1, action => 'correspond');
@@ -100,7 +100,7 @@
# create an iso 8859-1 ticket
@scrips_fired = ();
-$content = RT::Test->file_content("$RT::BasePath/lib/t/data/new-ticket-from-iso-8859-1");
+$content = RT::Test->file_content("t/data/emails/new-ticket-from-iso-8859-1");
@@ -148,7 +148,7 @@
# create an iso 8859-1 ticket
@scrips_fired = ();
- $content = RT::Test->file_content("$RT::BasePath/lib/t/data/new-ticket-from-iso-8859-1");
+ $content = RT::Test->file_content("t/data/emails/new-ticket-from-iso-8859-1");
# be as much like the mail gateway as possible.
use RT::Interface::Email;
@@ -242,7 +242,7 @@
# {{{ test a multipart alternative containing a text-html part with an umlaut
- $content = RT::Test->file_content("$RT::BasePath/lib/t/data/multipart-alternative-with-umlaut");
+ $content = RT::Test->file_content("t/data/emails/multipart-alternative-with-umlaut");
$parser->ParseMIMEEntityFromScalar($content);
@@ -271,7 +271,7 @@
# {{{ test a text-html message with an umlaut
- $content = RT::Test->file_content("$RT::BasePath/lib/t/data/text-html-with-umlaut");
+ $content = RT::Test->file_content("t/data/emails/text-html-with-umlaut");
$parser->ParseMIMEEntityFromScalar($content);
@@ -307,7 +307,7 @@
# {{{ test a text-html message with russian characters
- $content = RT::Test->file_content("$RT::BasePath/lib/t/data/text-html-in-russian");
+ $content = RT::Test->file_content("t/data/emails/text-html-in-russian");
$parser->ParseMIMEEntityFromScalar($content);
@@ -333,7 +333,7 @@
RT->Config->Set( EmailInputEncodings => 'koi8-r', RT->Config->Get('EmailInputEncodings') );
RT->Config->Set( EmailOutputEncoding => 'koi8-r' );
-$content = RT::Test->file_content("$RT::BasePath/lib/t/data/russian-subject-no-content-type");
+$content = RT::Test->file_content("t/data/emails/russian-subject-no-content-type");
$parser->ParseMIMEEntityFromScalar($content);
@@ -374,7 +374,7 @@
# {{{ test a message containing a nested RFC 822 message
- $content = RT::Test->file_content("$RT::BasePath/lib/t/data/nested-rfc-822");
+ $content = RT::Test->file_content("t/data/emails/nested-rfc-822");
ok ($content, "Loaded nested-rfc-822 to test");
$parser->ParseMIMEEntityFromScalar($content);
@@ -413,7 +413,7 @@
# {{{ test a multipart alternative containing a uuencoded mesage generated by lotus notes
- $content = RT::Test->file_content("$RT::BasePath/lib/t/data/notes-uuencoded");
+ $content = RT::Test->file_content("t/data/emails/notes-uuencoded");
$parser->ParseMIMEEntityFromScalar($content);
@@ -438,7 +438,7 @@
# {{{ test a multipart that crashes the file-based mime-parser works
- $content = RT::Test->file_content("$RT::BasePath/lib/t/data/crashes-file-based-parser");
+ $content = RT::Test->file_content("t/data/emails/crashes-file-based-parser");
$parser->ParseMIMEEntityFromScalar($content);
@@ -465,7 +465,7 @@
# {{{ test a multi-line RT-Send-CC header
- $content = RT::Test->file_content("$RT::BasePath/lib/t/data/rt-send-cc");
+ $content = RT::Test->file_content("t/data/emails/rt-send-cc");
$parser->ParseMIMEEntityFromScalar($content);
@@ -490,7 +490,7 @@
diag q{regression test for #5248 from rt3.fsck.com} if $ENV{TEST_VERBOSE};
{
- my $content = RT::Test->file_content("$RT::BasePath/lib/t/data/subject-with-folding-ws");
+ my $content = RT::Test->file_content("t/data/emails/subject-with-folding-ws");
my ($status, $msg, $ticket) = RT::Interface::Email::Gateway(
{ message => $content, queue => 1, action => 'correspond' }
);
@@ -501,7 +501,7 @@
diag q{regression test for #5248 from rt3.fsck.com} if $ENV{TEST_VERBOSE};
{
- my $content = RT::Test->file_content("$RT::BasePath/lib/t/data/very-long-subject");
+ my $content = RT::Test->file_content("t/data/emails/very-long-subject");
my ($status, $msg, $ticket) = RT::Interface::Email::Gateway(
{ message => $content, queue => 1, action => 'correspond' }
);
Modified: rt/branches/3.8-TESTING/t/shredder/utils.pl
==============================================================================
--- rt/branches/3.8-TESTING/t/shredder/utils.pl (original)
+++ rt/branches/3.8-TESTING/t/shredder/utils.pl Tue Jun 3 13:34:26 2008
@@ -123,7 +123,7 @@
cleanup_tmp();
RT::InitLogging();
- diag( _init_db() );
+ _init_db();
RT::Init();
$SIG{__WARN__} = sub { $RT::Logger->warning( @_ ); warn @_ };
@@ -150,7 +150,7 @@
=head3 db_name
Returns absolute file path to the current DB.
-It is C<cwd() .'/t/data/tmp/'. test_name() .'.db'>.
+It is C<cwd() .'/t/data/shredder/'. test_name() .'.db'>.
See also C<test_name> function.
=cut
@@ -212,11 +212,11 @@
=head3 tmpdir
Return absolute path to tmp dir used in tests.
-It is C<cwd(). "t/data/tmp">.
+It is C<cwd(). "t/data/shredder">.
=cut
-sub tmpdir { return File::Spec->catdir(Cwd::cwd(), qw(lib t data shredder)) }
+sub tmpdir { return File::Spec->catdir(Cwd::cwd(), qw(t data shredder)) }
=head2 create_tmpdir
@@ -228,7 +228,7 @@
=head3 cleanup_tmp
-Delete all tmp files that match C<t/data/tmp/test_name.*> mask.
+Delete all tmp files that match C<t/data/shredder/test_name.*> mask.
See also C<test_name> function.
=cut
@@ -401,4 +401,9 @@
return grep( !$_, $Test->summary )? 0: 1;
}
+END {
+ return unless is_all_successful;
+ File::Path::rmtree(tmpdir());
+}
+
1;
Modified: rt/branches/3.8-TESTING/t/web/command_line.t
==============================================================================
--- rt/branches/3.8-TESTING/t/web/command_line.t (original)
+++ rt/branches/3.8-TESTING/t/web/command_line.t Tue Jun 3 13:34:26 2008
@@ -111,7 +111,7 @@
# add attachments to a ticket
# text attachment
- check_attachment("$RT::BasePath/lib/t/data/lorem-ipsum");
+ check_attachment("t/data/emails/lorem-ipsum");
# binary attachment
check_attachment($RT::MasonComponentRoot.'/NoAuth/images/bplogo.gif');
More information about the Rt-commit
mailing list