Edgewall Software
Modify

Opened 16 years ago

Closed 14 years ago

#334 closed defect (fixed)

[patch] Match pattern is case-sensitive

Reported by: manu.blot@… Owned by: osimons
Priority: trivial Milestone: 0.6.1
Component: Build master Version: dev
Keywords: patch test easy Cc:
Operating System: BSD

Description

from branches/experimental/trac-0.11

When adding a match pattern for an OS, for example, Bitten is case-sensitive, which is a bit of a hassle to match an OS, for example:

  • Linux is a match
  • linux is not a match

Attachments (1)

334.insensitive-pattern-match.diff (1.7 KB) - added by anatoly techtonik <techtonik@…> 14 years ago.

Download all attachments as: .zip

Change History (9)

comment:1 Changed 15 years ago by osimons

  • Milestone changed from 0.6 to 0.6.1

comment:2 Changed 14 years ago by anatoly techtonik <techtonik@…>

  • Keywords patch added
  • Summary changed from Match pattern is case-sensitive to [patch] Match pattern is case-sensitive

No test cases yet. Can't run them out of the box. Need pointer to instructions how to run tests from checkout.

  • bitten/queue.py

     
    184184                for propname, pattern in ifilter(None, platform.rules):
    185185                    try:
    186186                        propvalue = properties.get(propname)
    187                         if not propvalue or not re.match(pattern, propvalue):
     187                        if (not propvalue or not re.match(pattern,
     188                                                          propvalue, re.I)):
    188189                            match = False
    189190                            break
    190191                    except re.error:

comment:3 Changed 14 years ago by osimons

$> python setup.py test

Changed 14 years ago by anatoly techtonik <techtonik@…>

comment:4 Changed 14 years ago by anatoly techtonik <techtonik@…>

  • Keywords test easy added

Added test case.

comment:5 Changed 14 years ago by osimons

Thanks! Committed in [993] (trunk) and merged to 0.6.1dev in [994].

comment:6 Changed 14 years ago by anatoly techtonik <techtonik@…>

Nice, but I can't close the ticket. There is only "new" option.

comment:7 Changed 14 years ago by osimons

  • Owner changed from cmlenz to osimons

comment:8 Changed 14 years ago by osimons

  • Resolution set to fixed
  • Status changed from new to closed

Heh, I forgot to close :-)

Add Comment

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain osimons.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.