Added an assert to verify that a toggle without a specified channel only

toggles the value of the current channel and not the default toggle.
This commit is contained in:
James Vega 2003-11-04 16:14:11 +00:00
parent 4d8e8807b9
commit 1558635250
1 changed files with 2 additions and 0 deletions

View File

@ -43,6 +43,8 @@ class ToggleDictionaryTestCase(unittest.TestCase):
## self.assertEqual(t['#baz']['foo'], True)
self.assertEqual(t.get('foo'), True)
self.assertEqual(t.get('foo', '#baz'), True)
t.toggle('foo', value=False)
self.assertEqual(t.get('foo', '#baz'), True)
t.toggle('foo', value=False, channel='#baz')
self.assertEqual(t.get('foo', '#baz'), False)
t.toggle('foo', channel='#baz')