WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH] add multiline flag to regular expression search expr

To: xen-devel@xxxxxxxxxxxxxxxxxxx, ewan@xxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] add multiline flag to regular expression search expressions in block integrity tests
From: Harry Butterworth <harry@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
Date: Mon, 12 Jun 2006 18:41:44 +0100
Delivery-date: Mon, 12 Jun 2006 10:42:14 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
The 02_block_device_write_verify.py test that I wrote is failing because
the regular expression to extract the md5sum is only looking at the
first line of output and the sum is in a subsequent line (after the
output from dd).

This patch fixes the test by adding the multiline flag to the search
parameters so that the search looks in all lines of the output for the
md5sum.  I added the multiline flag in all searches to make the tests
more robust against changes in the output format of the commands used.

I'm not exactly sure how this slipped through my testing.  I suspect
that I forgot to install the new python file after updating the test to
use dd and then tested the old version a second time by accident.
Either that or it really did work when I tested it and the output format
has changed for some reason.

I tested this patch against xen-unstable 10326 and the 02 test fails
without the patch and succeeds with it.

Thanks to James Dykman for some help with this.

Signed-off-by Harry Butterworth <butterwo@xxxxxxxxxx>

Attachment: multiline.patch
Description: Text Data

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH] add multiline flag to regular expression search expressions in block integrity tests, Harry Butterworth <=