Beispiel #1
0
        def test_ginput(self):
            """Test ginput function

            This does NOT perform interactive tests
            """

            plt = sx.plot()
            self.qWaitForWindowExposed(plt)
            self.qapp.processEvents()

            result = sx.ginput(1, timeout=0.1)
            self.assertEqual(len(result), 0)

            plt.setAttribute(qt.Qt.WA_DeleteOnClose)
            plt.close()
Beispiel #2
0
def test_ginput(sx, qapp, qapp_utils, plot_kind):
    """Test ginput function

    This does NOT perform interactive tests
    """
    create_plot = getattr(sx, plot_kind)
    plt = create_plot()
    qapp_utils.qWaitForWindowExposed(plt)
    qapp.processEvents()

    result = sx.ginput(1, timeout=0.1)
    assert len(result) == 0

    plt.setAttribute(qt.Qt.WA_DeleteOnClose)
    plt.close()
Beispiel #3
0
    def test_ginput(self):
        """Test ginput function

        This does NOT perform interactive tests
        """

        for create_plot in (sx.plot, sx.imshow, sx.scatter):
            with self.subTest(create_plot.__name__):
                plt = create_plot()
                self.qWaitForWindowExposed(plt)
                self.qapp.processEvents()

                result = sx.ginput(1, timeout=0.1)
                self.assertEqual(len(result), 0)

                plt.setAttribute(qt.Qt.WA_DeleteOnClose)
                plt.close()
    def test_ginput(self):
        """Test ginput function

        This does NOT perform interactive tests
        """

        for create_plot in (sx.plot, sx.imshow, sx.scatter):
            with self.subTest(create_plot.__name__):
                plt = create_plot()
                self.qWaitForWindowExposed(plt)
                self.qapp.processEvents()

                result = sx.ginput(1, timeout=0.1)
                self.assertEqual(len(result), 0)

                plt.setAttribute(qt.Qt.WA_DeleteOnClose)
                plt.close()