initial commit of file from CVS for smeserver-manager on Fri Mar 22 14:54:28 AEDT 2024
This commit is contained in:
33
root/usr/share/smanager/t/003_I18N.t
Normal file
33
root/usr/share/smanager/t/003_I18N.t
Normal file
@@ -0,0 +1,33 @@
|
||||
use Mojo::Base -strict;
|
||||
|
||||
use utf8;
|
||||
use Test::More;
|
||||
|
||||
plan skip_all => 'unset QUICK_TEST to enable this test' if $ENV{QUICK_TEST};
|
||||
|
||||
plan tests => 3;
|
||||
|
||||
use FindBin;
|
||||
use lib "$FindBin::Bin/../lib";
|
||||
|
||||
package main;
|
||||
use Mojolicious::Lite;
|
||||
|
||||
use Test::Mojo;
|
||||
|
||||
plugin 'SrvMngr::Plugin::I18N' => {
|
||||
namespace => 'SrvMngr::I18N::Modules::General', default => 'en'
|
||||
};
|
||||
|
||||
get '/' => 'index';
|
||||
|
||||
my $t = Test::Mojo->new;
|
||||
|
||||
$t->get_ok('/')->status_is(200)
|
||||
->content_is("Disabled en\n");
|
||||
|
||||
done_testing();
|
||||
|
||||
__DATA__
|
||||
@@ index.html.ep
|
||||
<%=l 'DISABLED' %> <%= languages %>
|
Reference in New Issue
Block a user