Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def setUp(self) -> None:
self.connection = secretstorage.dbus_init()
self.collection = secretstorage.get_any_collection(self.connection)
def test_closing_context_manager(self) -> None:
with closing(dbus_init()) as connection:
collection = get_any_collection(connection)
self.assertIsNotNone(collection)
label = collection.get_label()
self.assertIsNotNone(label)
def setUp(self) -> None:
self.connection = dbus_init()
self.collection = get_any_collection(self.connection)
def setUp(self) -> None:
self.connection = dbus_init()
self.collection = get_any_collection(self.connection)
self.created_timestamp = time.time()
self.item = self.collection.create_item('My item', ATTRIBUTES,
b'pa$$word')
self.other_item = self.collection.create_item('My item',
ATTRIBUTES, b'', content_type='data/null')