[Rt-commit] rt branch, psgi, updated. rt-3.9.4-141-g315ba3d
Shawn Moore
sartak at bestpractical.com
Tue Oct 19 00:28:33 EDT 2010
The branch, psgi has been updated
via 315ba3d0281bd7c4163cd568e59b6422e03deb27 (commit)
from 07c2fa98033599f9223af266a4e7de319e14d7b5 (commit)
Summary of changes:
lib/RT/Test/Web.pm | 16 ++++------------
1 files changed, 4 insertions(+), 12 deletions(-)
- Log -----------------------------------------------------------------
commit 315ba3d0281bd7c4163cd568e59b6422e03deb27
Author: Shawn M Moore <sartak at bestpractical.com>
Date: Tue Oct 19 13:27:45 2010 +0900
Fix warnings fetching under plack
diff --git a/lib/RT/Test/Web.pm b/lib/RT/Test/Web.pm
index 3af6494..ae1abda 100644
--- a/lib/RT/Test/Web.pm
+++ b/lib/RT/Test/Web.pm
@@ -174,21 +174,13 @@ sub goto_create_ticket {
sub get_warnings {
my $self = shift;
+ local $Test::Builder::Level = $Test::Builder::Level + 1;
- # FIXME: need psgi mw for stashed warnings
- if ($self->isa('Test::WWW::Mechanize::PSGI') || ($ENV{'RT_TEST_WEB_HANDLER'}||'') eq 'plack') {
- Test::More::ok(1);
- return;
- }
-
- my $server_class = 'RT::Interface::Web::Standalone';
-
- my $url = $server_class->test_warning_path;
+ return unless $self->get_ok('/__test_warnings');
- local $Test::Builder::Level = $Test::Builder::Level + 1;
- return unless $self->get_ok($url);
+ use Storable 'thaw';
- my @warnings = $server_class->decode_warnings($self->content);
+ my @warnings = @{ thaw $self->content };
return @warnings;
}
-----------------------------------------------------------------------
More information about the Rt-commit
mailing list