

def test_init_wsa(self):
    with mock.patch.object(self.ws2_32, 'WSADATA') as mock_WSADATA:
        self.ws2_32.init_wsa()
        mock_WSADATA.assert_called_once_with()
        mock_WSADATA._ctypes_mock.windll.Ws2_32.WSAStartup.assert_called_once_with(self.ws2_32.VERSION_2_2, self._ctypes_mock.byref.return_value)
        self._ctypes_mock.byref.assert_called_once_with(mock_WSADATA.return_value)

dataset/ETHPy150Open openstack/cloudbase-init/cloudbaseinit/tests/utils/windows/test_ws2_32.py WS2_32UtilsTests.test_init_wsa/VarMisuse@42/70 `self`->`mock_WSADATA`