Exemplo n.º 1
0
 def test_nested_qualified_key(self):
     tested = device.PropertyAccessor(None, None, None)
     self.assertEqual(
         [
             ('org.freedesktop.UDisks2.Block', 'Drive'),
             ('org.freedesktop.UDisks2.Drive', 'Media'),
         ],
         tested.parse_key(
             'org.freedesktop.UDisks2.Block.Drive/org.freedesktop.UDisks2.Drive.Media'
         ))
Exemplo n.º 2
0
 def test_empty_key(self):
     tested = device.PropertyAccessor(None, None, None)
     self.assertEqual([], tested.parse_key(''))
Exemplo n.º 3
0
 def test_simple_qualified_key(self):
     tested = device.PropertyAccessor(None, None, None)
     self.assertEqual(
         [('org.freedesktop.UDisks2.Block', 'IdLabel')],
         tested.parse_key('org.freedesktop.UDisks2.Block.IdLabel'))
Exemplo n.º 4
0
 def test_nested_unqualified_key(self):
     tested = device.PropertyAccessor(None, None, None)
     self.assertEqual([
         (None, 'Drive'),
         (None, 'Media'),
     ], tested.parse_key('Drive/Media'))
Exemplo n.º 5
0
 def test_simple_unqualified_key(self):
     tested = device.PropertyAccessor(None, None, None)
     self.assertEqual([(None, 'IdLabel')], tested.parse_key('IdLabel'))