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(self, contents, *expected_names):
names = find_from_imports(contents)
self.assertEqual(set(expected_names), names)