#1011: Add $(property:~replacement) syntax that turns anything false into
replacement, too
------------------------+---------------------------------------------------
Reporter: dustin | Owner: dustin
Type: enhancement | Status: reopened
Priority: major | Milestone: 0.8.2
Version: 0.8.1 | Resolution:
Keywords: |
------------------------+---------------------------------------------------
Comment(by dustin):
OK, here's the new tests; this turns anything that Python sees as false
into the replacement:
{{{
#!text/x-python
def testColonTildeSet(self):
self.assertEqual(self.pm['prop_str:~missing'], 'a-string')
def testColonTildeNone(self):
# None is special-cased *differently* for ~:
self.assertEqual(self.pm['prop_none:~missing'], 'missing')
def testColonTildeZero(self):
self.assertEqual(self.pm['prop_zero:~missing'], 'missing')
def testColonTildeOne(self):
self.assertEqual(self.pm['prop_one:~missing'], 1)
def testColonTildeFalse(self):
self.assertEqual(self.pm['prop_false:~missing'], 'missing')
def testColonTildeTrue(self):
self.assertEqual(self.pm['prop_true:~missing'], True)
def testColonTildeEmpty(self):
self.assertEqual(self.pm['prop_empty:~missing'], 'missing')
def testColonTildeUnset(self):
self.assertEqual(self.pm['prop_nosuch:~missing'], 'missing')
}}}
--
Ticket URL: <http://buildbot.net/trac/ticket/1011#comment:8>
Buildbot <http://buildbot.net/>
Buildbot: build/test automation
------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Buildbot-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/buildbot-commits