From 53fcd15fe7667628f4d5c4f2c1b2dc49f174d67c Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Mon, 28 Sep 2015 18:06:25 +0200 Subject: EFA: Handle ambiguous input properly (explicit accessors for candidate lists) --- t/21-vrr-ambig.t | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 't/21-vrr-ambig.t') diff --git a/t/21-vrr-ambig.t b/t/21-vrr-ambig.t index 7dd96a4..fb03a43 100644 --- a/t/21-vrr-ambig.t +++ b/t/21-vrr-ambig.t @@ -5,7 +5,7 @@ use 5.010; use utf8; use File::Slurp qw(slurp); -use Test::More tests => 7; +use Test::More tests => 9; BEGIN { use_ok('Travel::Status::DE::VRR'); @@ -21,8 +21,10 @@ can_ok($status, qw(errstr results)); $status->check_for_ambiguous(); -is($status->errstr, 'Ambiguous name input: Alfredusbad | Am Alfredusbad', - 'errstr ok'); +is($status->errstr, 'ambiguous name parameter', 'errstr ok'); + +is_deeply([$status->place_candidates], [], 'place candidates ok'); +is_deeply([$status->name_candidates], ['Alfredusbad', 'Am Alfredusbad'], 'name candidates ok'); is_deeply([$status->lines], [], 'no lines'); is_deeply([$status->results], [], 'no results'); -- cgit v1.2.3