blob: 3b45795d3ea43474db71b042cf3250d4c375c4a4 [file] [log] [blame]
Akrona65bd5d2024-10-24 13:28:11 +02001use Mojo::Base -strict;
2use Test::More;
3use Test::Mojo;
4use Mojo::File qw/path/;
5use utf8;
6
7$ENV{KALAMAR_VERSION} = '0.47.999';
8
9my $t = Test::Mojo->new('Kalamar');
10
11$t->app->mode('production');
12
13$t->get_ok('/')
14 ->status_is(200)
15 ->text_is('title', 'KorAP - Corpus Analysis Platform')
16 ->text_is('h1 span', 'KorAP - Corpus Analysis Platform')
17 ;
18
19$t->get_ok('/' => { 'Accept-Language' => 'de-DE, en-US, en' })
20 ->status_is(200)
21 ->text_is('title', 'KorAP - Korpusanalyseplattform der nächsten Generation')
22 ->text_is('h1 span', 'KorAP - Korpusanalyseplattform der nächsten Generation')
23 ;
24
25$t->get_ok('/' => { 'Accept-Language' => 'ro, en' })
26 ->status_is(200)
27 ->text_is('title', 'KorAP - Platformă pentru analiza corpusului')
28 ->text_is('h1 span', 'KorAP - Platformă pentru analiza corpusului')
29 ;
30
31$t->get_ok('/' => { 'Accept-Language' => 'hu, en' })
32 ->status_is(200)
33 ->text_is('title', 'KorAP - Korpuszelemző platform')
34 ->text_is('h1 span', 'KorAP - Korpuszelemző platform')
35 ;
36
37
38done_testing();