Nils Diewald | 5d1ffb4 | 2014-05-21 17:45:34 +0000 | [diff] [blame] | 1 | use Mojo::Base -strict; |
Nils Diewald | 034ea70 | 2015-01-16 19:41:52 +0000 | [diff] [blame] | 2 | use lib '../lib', 'lib'; |
Nils Diewald | 5d1ffb4 | 2014-05-21 17:45:34 +0000 | [diff] [blame] | 3 | use Test::More; |
| 4 | use Test::Mojo; |
| 5 | |
Nils Diewald | 2fe12e1 | 2015-03-06 16:47:06 +0000 | [diff] [blame] | 6 | my $t = Test::Mojo->new('Kalamar'); |
Akron | a0cd596 | 2015-06-29 09:38:00 +0200 | [diff] [blame] | 7 | |
| 8 | $t->app->mode('production'); |
| 9 | |
Nils Diewald | 996aa55 | 2014-12-02 03:26:44 +0000 | [diff] [blame] | 10 | $t->get_ok('/') |
| 11 | ->status_is(200) |
Nils Diewald | a748b0e | 2015-05-19 22:54:06 +0000 | [diff] [blame] | 12 | ->text_is('title', 'KorAP - Corpus Analysis Platform') |
| 13 | ->text_is('h1 span', 'KorAP - Corpus Analysis Platform'); |
Nils Diewald | 5d1ffb4 | 2014-05-21 17:45:34 +0000 | [diff] [blame] | 14 | |
Akron | a0cd596 | 2015-06-29 09:38:00 +0200 | [diff] [blame] | 15 | $t->get_ok('/huhuhuhuhu') |
| 16 | ->status_is(404) |
| 17 | ->text_is('title', 'KorAP: 404 - Page not found') |
| 18 | ->text_is('h1 span', 'KorAP: 404 - Page not found'); |
| 19 | |
Nils Diewald | 5d1ffb4 | 2014-05-21 17:45:34 +0000 | [diff] [blame] | 20 | done_testing(); |