[COMMIT LOGREPORT] service/all/lib/tests DlfCategoriserTest.pm,1.4,1.5
Francis J. Lacoste
flacoste at users.sourceforge.net
Mon Jun 13 18:19:49 CEST 2005
Update of /cvsroot/logreport/service/all/lib/tests
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12415/all/lib/tests
Modified Files:
DlfCategoriserTest.pm
Log Message:
Added a finalise() method to the DlfCategoriser API.
Index: DlfCategoriserTest.pm
===================================================================
RCS file: /cvsroot/logreport/service/all/lib/tests/DlfCategoriserTest.pm,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- DlfCategoriserTest.pm 13 Jun 2005 16:10:44 -0000 1.4
+++ DlfCategoriserTest.pm 13 Jun 2005 16:19:47 -0000 1.5
@@ -58,6 +58,7 @@
@_ ] },
'categorise' => sub { push @{$_[0]}, [ 'categorise',
@_ ] },
+ 'finalise' => sub { push @{$_[0]}, [ 'finalise', @_]},
} );
my $process = $self->create_mock_process( $categoriser );
@@ -77,7 +78,7 @@
$process->run_analysis_job( $self->{'20040311_121201'} );
- $self->assert_num_equals( 4, scalar @$categoriser );
+ $self->assert_num_equals( 5, scalar @$categoriser );
$self->assert_str_equals( 'initialise', $categoriser->[0][0] );
$self->assert_str_equals( 'categorise', $categoriser->[1][0] );
$self->assert_num_equals( $self->{'20040311_121201'} -3600,
@@ -86,6 +87,7 @@
$categoriser->[2][2]{'time_start'} );
$self->assert_num_equals( $self->{'20040311_121201'} +3600,
$categoriser->[3][2]{'time_start'} );
+ $self->assert_str_equals( 'finalise', $categoriser->[4][0] );
$self->assert_null( $process->{'errors'} );
$self->assert_num_equals( 3, scalar @{$process->{'dlf'}} );
--
To UNSUBSCRIBE, email to commit-request at logreport.org with a subject of
"unsubscribe". Trouble? Send an email with subject "help" to
commit-request at logreport.org
More information about the Commit
mailing list