From 5e436d356b026e06ed29163791a04b3820cf6c05 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sat, 3 Dec 2011 02:12:00 +0100 Subject: Result: Add ->date accessor --- t/20-db.t | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 't') diff --git a/t/20-db.t b/t/20-db.t index 03c25ef..e90f853 100644 --- a/t/20-db.t +++ b/t/20-db.t @@ -4,7 +4,7 @@ use warnings; use 5.010; use File::Slurp qw(slurp); -use Test::More tests => 97; +use Test::More tests => 98; BEGIN { use_ok('Travel::Status::DE::DeutscheBahn'); @@ -22,10 +22,11 @@ my @departures = $status->results; for my $departure (@departures) { isa_ok($departure, 'Travel::Status::DE::DeutscheBahn::Result'); - can_ok($departure, qw(route_end destination origin info platform route + can_ok($departure, qw(date route_end destination origin info platform route route_raw time train)); } +is($departures[0]->date, '06.07.2011', 'first result: date ok'); is($departures[0]->time, '19:21', 'first result: time ok'); is($departures[0]->train, 'RE 10228', 'first result: train ok'); is($departures[0]->destination, 'Duisburg Hbf', 'first result: destination ok'); -- cgit v1.2.3