[Rt-commit] rt branch, 4.0/redirect-after-quick-create, updated. rt-4.0.0-410-g8962dc6

Thomas Sibley trs at bestpractical.com
Fri Jul 29 10:53:53 EDT 2011


The branch, 4.0/redirect-after-quick-create has been updated
       via  8962dc6d9d14e05ee97e90667fbf584f08ff71de (commit)
       via  66f3299ee7c1853b219c4e07b734a4f0519f6b18 (commit)
      from  ec6c47884edb24b9a0e26f0368cf34bc47cd1dc8 (commit)

Summary of changes:
 share/html/index.html |    2 +-
 t/web/quickcreate.t   |    5 +++--
 2 files changed, 4 insertions(+), 3 deletions(-)

- Log -----------------------------------------------------------------
commit 66f3299ee7c1853b219c4e07b734a4f0519f6b18
Author: Thomas Sibley <trs at bestpractical.com>
Date:   Fri Jul 29 10:52:45 2011 -0400

    Prefer an implicit index.html over explicitly specifying it
    
    This leads to cleaner looking urls, and matches what we do when we
    redirect after login.

diff --git a/share/html/index.html b/share/html/index.html
index 7f52c8b..7d370fa 100755
--- a/share/html/index.html
+++ b/share/html/index.html
@@ -129,7 +129,7 @@ if ( $ARGS{'QuickCreate'} ) {
     }
     MaybeRedirectForResults(
         Actions   => \@results,
-        Path      => '/index.html',
+        Path      => '/',
     );
 }
 

commit 8962dc6d9d14e05ee97e90667fbf584f08ff71de
Author: Thomas Sibley <trs at bestpractical.com>
Date:   Fri Jul 29 10:53:35 2011 -0400

    Adjust tests to take into account the new redirect after quickcreate

diff --git a/t/web/quickcreate.t b/t/web/quickcreate.t
index 0cb856c..b257f9d 100644
--- a/t/web/quickcreate.t
+++ b/t/web/quickcreate.t
@@ -2,7 +2,7 @@
 use strict;
 use warnings;
 
-use RT::Test tests => 10;
+use RT::Test tests => 11;
 
 RT->Config->Set('DisplayTicketAfterQuickCreate' => 0);
 
@@ -15,7 +15,8 @@ $m->field(Subject => 'from quick create');
 $m->submit;
 
 $m->content_like(qr/Ticket \d+ created in queue/, 'created ticket');
-is( $m->uri, $baseurl . '/index.html', 'still in homepage' );
+like( $m->uri, qr{^\Q$baseurl\E/(?:index\.html)?\?results=}, 'still in homepage' );
+unlike( $m->uri, qr{Ticket/Display.html}, 'not on ticket display page' );
 
 $m->get_ok($baseurl . '/Prefs/Other.html');
 $m->submit_form(

-----------------------------------------------------------------------


More information about the Rt-commit mailing list