Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_loads(self):
versions = Versions.loads(
'[' +
'{"version": "2.0", "title": "2.0.2", "aliases": ["latest"]}, ' +
'{"version": "1.0", "title": "1.0.1", "aliases": ["stable"]}' +
']'
)
self.assertEqual(list(versions), [
VersionInfo('2.0', '2.0.2', aliases={'latest'}),
VersionInfo('1.0', '1.0.1', aliases={'stable'}),
])