コード例 #1
0
ファイル: conftest.py プロジェクト: guili618/gns3-gui
def reset_qt_signal():
    """
    Reset the QT signals between tests. Otherwise
    you can get callback on code from previous test.
    """

    from gns3.qt import FakeQtSignal
    FakeQtSignal.reset()
コード例 #2
0
def reset_qt_signal():
    """
    Reset the QT signals between tests. Otherwise
    you can get callback on code from previous test.
    """

    from gns3.qt import FakeQtSignal
    FakeQtSignal.reset()
コード例 #3
0
def response():
    response = unittest.mock.MagicMock()
    type(response).finished = unittest.mock.PropertyMock(
        return_value=FakeQtSignal())
    response.error.return_value = QtNetwork.QNetworkReply.NoError
    response.attribute.return_value = 200
    return response