Пример #1
0
 def test_can_serialize_as_metadata_when_some(self):
     manager = SupportedHardwareManager()
     manager.add('PowerZ')
     manager.add('PowerY')
     manager.add('PowerX')
     expected = {'supported-hardware': ['PowerX', 'PowerY', 'PowerZ']}
     observed = manager.to_metadata()
     self.assertEqual(observed, expected)
Пример #2
0
 def test_can_serialize_as_metadata_when_any(self):
     manager = SupportedHardwareManager()
     expected = {'supported-hardware': 'any'}
     observed = manager.to_metadata()
     self.assertEqual(observed, expected)