[Rt-commit] rt branch, 5.0/mobile-config-option, updated. rt-5.0.0alpha1-384-g64001734cd

Jim Brandt jbrandt at bestpractical.com
Thu May 7 14:43:47 EDT 2020


The branch, 5.0/mobile-config-option has been updated
       via  64001734cdae76e893ab627be841d91ca4a10c68 (commit)
      from  918955a057ee375c45ab388558d460250f9753b0 (commit)

Summary of changes:
 t/web/login.t  | 16 ++++++++++++++++
 t/web/mobile.t |  1 +
 2 files changed, 17 insertions(+)

- Log -----------------------------------------------------------------
commit 64001734cdae76e893ab627be841d91ca4a10c68
Author: Jim Brandt <jbrandt at bestpractical.com>
Date:   Thu May 7 14:36:37 2020 -0400

    Update tests for mobile defaulting off

diff --git a/t/web/login.t b/t/web/login.t
index 862782a0cc..222f40e1ba 100644
--- a/t/web/login.t
+++ b/t/web/login.t
@@ -93,6 +93,22 @@ diag "mobile login with not mobile client";
     $m->content_lacks( 'Logout', 'really logout' );
 }
 
+diag "mobile normal login, mobile off";
+{
+
+    # default browser in android 2.3.6
+    $m->agent(
+"Mozilla/5.0 (Linux; U; Android 2.3.6; en-us; Nexus One Build/GRK39F) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1"
+    );
+
+    $m->get($baseurl);
+    is( $m->uri, $baseurl, "right url" );
+    $m->content_lacks( "/m/index.html?NotMobile=1", 'normal UI login' );
+}
+
+RT::Test->stop_server;
+RT->Config->Set(ShowMobileSite => 1);
+( $baseurl, $m ) = RT::Test->started_ok;
 
 diag "mobile normal login";
 {
diff --git a/t/web/mobile.t b/t/web/mobile.t
index 831bf6652a..908096399c 100644
--- a/t/web/mobile.t
+++ b/t/web/mobile.t
@@ -2,6 +2,7 @@ use strict;
 use warnings;
 use RT::Test tests => 170;
 
+RT->Config->Set(ShowMobileSite => 1);
 my ( $url, $m ) = RT::Test->started_ok;
 my $root = RT::Test->load_or_create_user( Name => 'root' );
 

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


More information about the rt-commit mailing list