From 9bfb5ef9a2cd17c6d21ea7a755d22cf439cd87dc Mon Sep 17 00:00:00 2001 From: Bernard Davison Date: Tue, 20 Mar 2012 14:48:53 +1100 Subject: [PATCH] Making the /Error/ regex match on word boundries so it won't match i2c_error for example. --- tests/LisaL/01_upload.t | 4 ++-- tests/examples/01_compile_all_example_targets.t | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/LisaL/01_upload.t b/tests/LisaL/01_upload.t index c32d5b62b5..56c139579e 100644 --- a/tests/LisaL/01_upload.t +++ b/tests/LisaL/01_upload.t @@ -17,7 +17,7 @@ my $compile_output = run_program( "make $make_compile_options", 0,1); unlike($compile_output, '/Aircraft \'LisaLv11_Booz2v12_RC\' not found in/', "The compile output does not contain the message \"Aircraft \'LisaLv11_Booz2v12_RC\' not found in\""); -unlike($compile_output, '/Error/i', "The compile output does not contain the word \"Error\""); +unlike($compile_output, '/\bError\b/i', "The compile output does not contain the word \"Error\""); #################### # Upload the airframe @@ -27,7 +27,7 @@ my $upload_output = run_program( $ENV{'PAPARAZZI_SRC'}, "make $make_upload_options", 0,1); -unlike($upload_output, '/Error/i', "The upload output does not contain the word \"Error\""); +unlike($upload_output, '/\bError\b/i', "The upload output does not contain the word \"Error\""); # Start the server process my $server_command = "$ENV{'PAPARAZZI_HOME'}/sw/ground_segment/tmtc/server"; diff --git a/tests/examples/01_compile_all_example_targets.t b/tests/examples/01_compile_all_example_targets.t index d8cb760458..275a370384 100644 --- a/tests/examples/01_compile_all_example_targets.t +++ b/tests/examples/01_compile_all_example_targets.t @@ -37,7 +37,7 @@ foreach my $example (sort keys%{$examples->{'aircraft'}}) $ENV{'PAPARAZZI_SRC'}, "make $make_upload_options", $ENV->{'TEST_VERBOSE'},1); - unlike($upload_output, '/Error/i', "The upload output does not contain the word \"Error\""); + unlike($upload_output, '/\bError\b/i', "The upload output does not contain the word \"Error\""); } } elsif ($process =~ m#target#) @@ -57,7 +57,7 @@ foreach my $example (sort keys%{$examples->{'aircraft'}}) $ENV{'PAPARAZZI_SRC'}, "make $make_upload_options", $ENV->{'TEST_VERBOSE'},1); - unlike($upload_output, '/Error/i', "The upload output does not contain the word \"Error\""); + unlike($upload_output, '/\bError\b/i', "The upload output does not contain the word \"Error\""); } } }