[Rt-commit] r2687 - in rt/branches/PLATANO-EXPERIMENTAL-CSS: . lib/t/regression

jesse at bestpractical.com jesse at bestpractical.com
Sat Apr 16 04:14:02 EDT 2005


Author: jesse
Date: Sat Apr 16 04:14:01 2005
New Revision: 2687

Added:
   rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/t/regression/18custom_frontpage.t   (contents, props changed)
Modified:
   rt/branches/PLATANO-EXPERIMENTAL-CSS/   (props changed)
Log:
 r13076 at hualien:  jesse | 2005-04-16 03:00:58 -0400
  r12970 at hualien:  jesse | 2005-04-16 02:16:06 -0400
   r6495 at hualien:  jesse | 2005-03-06 17:46:04 -0500
    r6412 at hualien (orig r2294):  clkao | 2005-03-06 10:50:23 -0500
     r2419 at ab:  clkao | 2005-03-06 23:48:51 +0800
     Minimum regression tests for frontpage customization.
    
   
  
 


Added: rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/t/regression/18custom_frontpage.t
==============================================================================
--- (empty file)
+++ rt/branches/PLATANO-EXPERIMENTAL-CSS/lib/t/regression/18custom_frontpage.t	Sat Apr 16 04:14:01 2005
@@ -0,0 +1,40 @@
+#!/usr/bin/perl -w
+use strict;
+
+use Test::More tests => 4;
+BEGIN {
+    use RT;
+    RT::LoadConfig;
+    RT::Init;
+}
+use Test::WWW::Mechanize;
+
+$RT::WebPath ||= ''; # Shut up a warning
+use constant BaseURL => "http://localhost:".$RT::WebPort.$RT::WebPath."/";
+
+# reset preferences for easier test?
+
+my $m = Test::WWW::Mechanize->new ( autocheck => 1 );
+isa_ok($m, 'Test::WWW::Mechanize');
+
+$m->get( BaseURL."?user=root;pass=password" );
+$m->content_like(qr/Logout/, 'we did log in');
+
+$m->get ( BaseURL.'Prefs/MyRT.html' );
+$m->form_name ('SelectionBox-main');
+# can't use submit form for mutli-valued select as it uses set_fields
+$m->field ('main-Selected' => ['component-QuickCreate', 'system-My Requests', 'system-My Tickets']);
+$m->click_button (name => 'remove');
+$m->form_name ('SelectionBox-main');
+$m->click_button (name => 'submit');
+$m->get ( BaseURL );
+$m->content_lacks ('highest priority tickets');
+
+$m->get ( BaseURL.'Prefs/MyRT.html' );
+$m->form_name ('SelectionBox-main');
+$m->field ('main-Available' => ['component-QuickCreate', 'system-My Requests', 'system-My Tickets']);
+$m->click_button (name => 'add');
+$m->form_name ('SelectionBox-main');
+$m->click_button (name => 'submit');
+$m->get ( BaseURL );
+$m->content_like (qr'highest priority tickets');


More information about the Rt-commit mailing list