[Python-modules-commits] [pytest-qt] 01/03: New upstream version 2.1.0

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Thu Feb 9 16:45:44 UTC 2017


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to branch master
in repository pytest-qt.

commit 65169a9946547981e35acfcc4548c278cd455515
Author: Ghislain Antony Vaillant <ghisvail at gmail.com>
Date:   Wed Feb 8 15:03:02 2017 +0000

    New upstream version 2.1.0
---
 .gitattributes                          |    1 +
 .gitignore                              |   18 +
 .project                                |   17 +
 .pydevproject                           |    8 +
 .travis.yml                             |   59 ++
 CHANGELOG.rst                           |  412 ++++++++++++
 LICENSE                                 |   21 +
 Manifest.in                             |    3 +
 PKG-INFO                                |  195 ++++++
 README.rst                              |  171 +++++
 appveyor.yml                            |   27 +
 docs/.gitignore                         |    1 +
 docs/Makefile                           |  153 +++++
 docs/_static/find_files_dialog.png      |  Bin 0 -> 31437 bytes
 docs/app_exit.rst                       |   35 +
 docs/changelog.rst                      |    7 +
 docs/conf.py                            |  242 +++++++
 docs/index.rst                          |   32 +
 docs/intro.rst                          |   97 +++
 docs/logging.rst                        |  244 +++++++
 docs/make.bat                           |  190 ++++++
 docs/modeltester.rst                    |   55 ++
 docs/note_pyqt4v2.rst                   |   25 +
 docs/reference.rst                      |   34 +
 docs/signals.rst                        |  232 +++++++
 docs/tutorial.rst                       |   69 ++
 docs/virtual_methods.rst                |   75 +++
 docs/wait_until.rst                     |   72 +++
 pytest_qt.egg-info/PKG-INFO             |  195 ++++++
 pytest_qt.egg-info/SOURCES.txt          |   56 ++
 pytest_qt.egg-info/dependency_links.txt |    1 +
 pytest_qt.egg-info/entry_points.txt     |    3 +
 pytest_qt.egg-info/requires.txt         |    5 +
 pytest_qt.egg-info/top_level.txt        |    1 +
 pytestqt/__init__.py                    |    3 +
 pytestqt/_version.py                    |    4 +
 pytestqt/exceptions.py                  |  101 +++
 pytestqt/logging.py                     |  292 +++++++++
 pytestqt/modeltest.py                   |  683 ++++++++++++++++++++
 pytestqt/plugin.py                      |  186 ++++++
 pytestqt/qt_compat.py                   |  194 ++++++
 pytestqt/qtbot.py                       |  633 ++++++++++++++++++
 pytestqt/wait_signal.py                 |  574 +++++++++++++++++
 requirements.txt                        |    1 +
 scripts/install-qt.py                   |   88 +++
 scripts/link_pyqt.py                    |  221 +++++++
 setup.cfg                               |    8 +
 setup.py                                |   62 ++
 tests/conftest.py                       |   87 +++
 tests/test_basics.py                    |  360 +++++++++++
 tests/test_exceptions.py                |  316 +++++++++
 tests/test_logging.py                   |  520 +++++++++++++++
 tests/test_modeltest.py                 |  272 ++++++++
 tests/test_qtest_proxies.py             |   32 +
 tests/test_wait_signal.py               | 1066 +++++++++++++++++++++++++++++++
 tests/test_wait_until.py                |   65 ++
 tox.ini                                 |   35 +
 57 files changed, 8559 insertions(+)

diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000..c9a14c1
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1 @@
+CHANGELOG.md    merge=union
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..6d76704
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,18 @@
+*.pyc
+__pycache__
+*.log
+/distribute-0.6.35.tar.gz
+/distribute-0.6.35-py2.7.egg
+/pytest_qt.egg-info
+/build
+/dist
+/.tox
+.env*
+.coverage
+/.cache
+/.venv
+/.eggs
+
+
+# auto-generated by setuptools_scm
+/pytestqt/_version.py
diff --git a/.project b/.project
new file mode 100644
index 0000000..9a9fb50
--- /dev/null
+++ b/.project
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>pytest-qt</name>
+	<comment></comment>
+	<projects>
+	</projects>
+	<buildSpec>
+		<buildCommand>
+			<name>org.python.pydev.PyDevBuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.python.pydev.pythonNature</nature>
+	</natures>
+</projectDescription>
diff --git a/.pydevproject b/.pydevproject
new file mode 100644
index 0000000..a946dfc
--- /dev/null
+++ b/.pydevproject
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<?eclipse-pydev version="1.0"?><pydev_project>
+<pydev_pathproperty name="org.python.pydev.PROJECT_SOURCE_PATH">
+<path>/${PROJECT_DIR_NAME}</path>
+</pydev_pathproperty>
+<pydev_property name="org.python.pydev.PYTHON_PROJECT_VERSION">python 2.7</pydev_property>
+<pydev_property name="org.python.pydev.PYTHON_PROJECT_INTERPRETER">Default</pydev_property>
+</pydev_project>
diff --git a/.travis.yml b/.travis.yml
new file mode 100644
index 0000000..febef69
--- /dev/null
+++ b/.travis.yml
@@ -0,0 +1,59 @@
+language: python
+sudo: required
+dist: trusty
+
+python:
+  - "2.7"
+  - "3.4"
+
+virtualenv:
+  system_site_packages: true
+
+matrix:
+  exclude:
+    - env: PYTEST_QT_API=pyqt5
+      python: "2.7"
+
+env:
+ - PYTEST_QT_API=pyqt4
+ - PYTEST_QT_API=pyqt4v2
+ - PYTEST_QT_API=pyside
+ - PYTEST_QT_API=pyqt5
+
+install:
+ - sudo apt-get update
+
+ # Xvfb
+ - sudo apt-get install -y xvfb
+
+ # Qt
+ - python scripts/install-qt.py
+
+ # PyTest
+ - pip install -U pytest
+
+ # Tox
+ - pip install -U tox
+
+ # others
+ - pip install coveralls --use-wheel
+
+script:
+ - python setup.py develop
+ # change screen size and depth in attempt to fix waitActive test (#160)
+ - catchsegv xvfb-run --server-args="-screen 0 640x480x24" coverage run --source=pytestqt setup.py test
+ - tox -e lint
+
+after_success:
+ - coveralls
+
+deploy:
+  provider: pypi
+  user: nicoddemus
+  password:
+    secure: Uj4XhkIUGE8CkE9mbP4y2wrp1s+jODkEi+wXCL1ZDhcCxxs3gjEOtAlqIXS/4PMLZcxeV2rXNGzGJ6n+i6Ruj2T1wfar7hmy2faaur6tcUDhEpXLkAl6DAKlMiZbEyT4C7OpunBoYmw8Gh/3kaDeGgz4FxEiJakAqzEmmeyFvFY=
+  on:
+    tags: true
+    distributions: sdist bdist_wheel
+    repo: pytest-dev/pytest-qt
+
diff --git a/CHANGELOG.rst b/CHANGELOG.rst
new file mode 100644
index 0000000..ecc9cfe
--- /dev/null
+++ b/CHANGELOG.rst
@@ -0,0 +1,412 @@
+2.1
+---
+
+- ``waitSignal`` and ``waitSignals`` now provide much more detailed messages
+  when expected signals are not emitted. Many thanks to `@MShekow`_ for the PR
+  (`#153`_).
+
+- ``qtbot`` fixture now can capture Qt virtual method exceptions in a block using
+  ``captureExceptions`` (`#154`_). Thanks to `@fogo`_ for the PR.
+
+- New `qtbot.waitActive`_ and `qtbot.waitExposed`_ methods for PyQt5.
+  Thanks `@The-Compiler`_ for the request (`#158`_).
+
+- ``SignalTimeoutError`` has been renamed to ``TimeoutError``. ``SignalTimeoutError`` is kept as
+  a backward compatibility alias.
+
+.. _qtbot.waitActive: http://pytest-qt.readthedocs.io/en/latest/reference.html#pytestqt.qtbot.QtBot.waitActive
+.. _qtbot.waitExposed: http://pytest-qt.readthedocs.io/en/latest/reference.html#pytestqt.qtbot.QtBot.waitExposed
+
+.. _#153: https://github.com/pytest-dev/pytest-qt/issues/153
+.. _#154: https://github.com/pytest-dev/pytest-qt/issues/154
+.. _#158: https://github.com/pytest-dev/pytest-qt/issues/158
+
+2.0
+---
+
+Breaking Changes
+~~~~~~~~~~~~~~~~
+
+With ``pytest-qt`` 2.0, we changed some defaults to values we think are much
+better, however this required some backwards-incompatible changes:
+
+- ``pytest-qt`` now defaults to using ``PyQt5`` if ``PYTEST_QT_API`` is not set.
+  Before, it preferred ``PySide`` which is using the discontinued Qt4.
+
+- Python 3 versions prior to 3.4 are no longer supported.
+
+- The ``@pytest.mark.qt_log_ignore`` mark now defaults to ``extend=True``, i.e.
+  extends the patterns defined in the config file rather than overriding them.
+  You can pass ``extend=False`` to get the old behaviour of overriding the
+  patterns.
+
+- ``qtbot.waitSignal`` now defaults to ``raising=True`` and raises an exception
+  on timeouts. You can set ``qt_wait_signal_raising = false`` in your config to
+  get back the old behaviour.
+
+- ``PYTEST_QT_FORCE_PYQT`` environment variable is no longer supported. Set ``PYTEST_QT_API``
+  to the appropriate value instead or the new ``qt_api`` configuration option in your
+  ``pytest.ini`` file.
+
+
+New Features
+~~~~~~~~~~~~
+
+* From this version onward, ``pytest-qt`` is licensed under the MIT license (`#134`_).
+
+* New ``qtmodeltester`` fixture to test ``QAbstractItemModel`` subclasses.
+  Thanks `@The-Compiler`_ for the initiative and port of the original C++ code
+  for ModelTester (`#63`_).
+
+* New ``qtbot.waitUntil`` method, which continuously calls a callback until a condition
+  is met or a timeout is reached. Useful for testing asynchronous features 
+  (like in X window environments for example).
+
+* ``waitSignal`` and ``waitSignals`` can receive an optional callback (or list of callbacks)
+  that can evaluate if the arguments of emitted signals should resume execution or not.
+  Additionally ``waitSignals`` has a new ``order`` parameter that allows to expect signals
+  and their arguments in a strict, semi-strict or no specific order.
+  Thanks `@MShekow`_ for the PR (`#141`_).
+
+* Now which Qt binding ``pytest-qt`` will use can be configured by the ``qt_api`` config option.
+  Thanks `@The-Compiler`_ for the request (`#129`_).
+
+* While ``pytestqt.qt_compat`` is an internal module and shouldn't be imported directly,
+  it is known that some test suites did import it. This module now uses a lazy-load mechanism
+  to load Qt classes and objects, so the old symbols (``QtCore``, ``QApplication``, etc.) are
+  no longer available from it.
+
+.. _#134: https://github.com/pytest-dev/pytest-qt/issues/134
+.. _#141: https://github.com/pytest-dev/pytest-qt/pull/141
+.. _#63: https://github.com/pytest-dev/pytest-qt/pull/63
+.. _#129: https://github.com/pytest-dev/pytest-qt/issues/129
+
+
+Other Changes
+~~~~~~~~~~~~~
+
+- Exceptions caught by ``pytest-qt`` in ``sys.excepthook`` are now also printed
+  to ``stderr``, making debugging them easier from within an IDE.
+  Thanks `@fabioz`_ for the PR (`126`_)!
+
+.. _126: https://github.com/pytest-dev/pytest-qt/pull/126
+
+1.11.0
+------
+
+.. note::
+
+    The default value for ``raising`` is planned to change to ``True`` starting in
+    pytest-qt version ``1.12``. Users wishing to preserve
+    the current behavior (``raising`` is ``False`` by default) should make
+    use of the new ``qt_wait_signal_raising`` ini option below.
+
+- New ``qt_wait_signal_raising`` ini option can be used to override the default
+  value of the ``raising`` parameter of the ``qtbot.waitSignal`` and
+  ``qtbot.waitSignals`` functions when omitted:
+
+  .. code-block:: ini
+
+      [pytest]
+      qt_wait_signal_raising = true
+
+  Calls which explicitly pass the ``raising`` parameter are not affected.
+  Thanks `@The-Compiler`_ for idea and initial work on a PR (`120`_).
+
+
+- ``qtbot`` now has a new ``assertNotEmitted`` context manager which can be
+  used to ensure the given signal is not emitted (`92`_).
+  Thanks `@The-Compiler`_ for the PR!
+
+
+.. _92: https://github.com/pytest-dev/pytest-qt/issues/92
+.. _120: https://github.com/pytest-dev/pytest-qt/issues/120
+
+
+1.10.0
+------
+
+- ``SignalBlocker`` now has a ``args`` attribute with the arguments of the
+  signal that triggered it, or ``None`` on a time out (`115`_).
+  Thanks `@billyshambrook`_ for the request and `@The-Compiler`_ for the PR.
+
+- ``MultiSignalBlocker`` is now properly disconnects from signals upon exit.
+
+.. _115: https://github.com/pytest-dev/pytest-qt/issues/115
+
+1.9.0
+-----
+
+- Exception capturing now happens as early/late as possible in order to catch
+  all possible exceptions (including fixtures)(`105`_). Thanks
+  `@The-Compiler`_ for the request.
+
+- Widgets registered by ``qtbot.addWidget`` are now closed  before all other
+  fixtures are tear down (`106`_). Thanks `@The-Compiler`_ for request.
+
+- ``qtbot`` now has a new ``wait`` method which does a blocking wait while the
+  event loop continues to run, similar to ``QTest::qWait``. Thanks
+  `@The-Compiler`_ for the PR (closes `107`_)!
+  
+- raise ``RuntimeError`` instead of ``ImportError`` when failing to import
+  any Qt binding: raising the latter causes `pluggy` in `pytest-2.8` to 
+  generate a subtle warning instead of a full blown error. 
+  Thanks `@Sheeo`_ for bringing this problem to attention (closes `109`_).
+
+.. _105: https://github.com/pytest-dev/pytest-qt/issues/105
+.. _106: https://github.com/pytest-dev/pytest-qt/issues/106
+.. _107: https://github.com/pytest-dev/pytest-qt/issues/107
+.. _109: https://github.com/pytest-dev/pytest-qt/issues/109
+
+
+1.8.0
+-----
+
+- ``pytest.mark.qt_log_ignore`` now supports an ``extend`` parameter that will extend 
+  the list of regexes used to ignore Qt messages (defaults to False). 
+  Thanks `@The-Compiler`_ for the PR (`99`_).
+
+- Fixed internal error when interacting with other plugins that raise an error,
+  hiding the original exception (`98`_). Thanks `@The-Compiler`_ for the PR!
+  
+- Now ``pytest-qt`` is properly tested with PyQt5 on Travis-CI. Many thanks
+  to `@The-Compiler`_ for the PR!
+  
+.. _99: https://github.com/pytest-dev/pytest-qt/issues/99
+.. _98: https://github.com/pytest-dev/pytest-qt/issues/98
+
+1.7.0
+-----
+
+- ``PYTEST_QT_API`` can now be set to ``pyqt4v2`` in order to use version 2 of the 
+  PyQt4 API. Thanks `@montefra`_ for the PR (`93`_)!
+  
+.. _93: https://github.com/pytest-dev/pytest-qt/issues/93  
+
+
+1.6.0
+-----
+
+- Reduced verbosity when exceptions are captured in virtual methods
+  (`77`_, thanks `@The-Compiler`_).
+  
+- ``pytestqt.plugin`` has been split in several files (`74`_) and tests have been
+  moved out of the ``pytestqt`` package. This should not affect users, but it
+  is worth mentioning nonetheless.
+
+- ``QApplication.processEvents()`` is now called before and after other fixtures
+  and teardown hooks, to better try to avoid non-processed events from leaking 
+  from one test to the next. (67_, thanks `@The-Compiler`_). 
+
+- Show Qt/PyQt/PySide versions in pytest header (68_, thanks `@The-Compiler`_!).
+
+- Disconnect SignalBlocker functions after its loop exits to ensure second
+  emissions that call the internal functions on the now-garbage-collected 
+  SignalBlocker instance (#69, thanks `@The-Compiler`_ for the PR).
+  
+.. _77: https://github.com/pytest-dev/pytest-qt/issues/77  
+.. _74: https://github.com/pytest-dev/pytest-qt/issues/74
+.. _67: https://github.com/pytest-dev/pytest-qt/issues/67
+.. _68: https://github.com/pytest-dev/pytest-qt/issues/68
+
+1.5.1
+-----
+
+- Exceptions are now captured also during test tear down, as delayed events will 
+  get processed then and might raise exceptions in virtual methods; 
+  this is specially problematic in ``PyQt5.5``, which 
+  `changed the behavior <http://pyqt.sourceforge.net/Docs/PyQt5/incompatibilities.html#pyqt-v5-5>`_ 
+  to call ``abort`` by default, which will crash the interpreter. 
+  (65_, thanks `@The-Compiler`_).
+  
+.. _65: https://github.com/pytest-dev/pytest-qt/issues/65 
+
+1.5.0
+-----
+
+- Fixed log line number in messages, and provide better contextual information 
+  in Qt5 (55_, thanks `@The-Compiler`_);
+  
+- Fixed issue where exceptions inside a ``waitSignals`` or ``waitSignal`` 
+  with-statement block would be swallowed and a ``SignalTimeoutError`` would be 
+  raised instead. (59_, thanks `@The-Compiler`_ for bringing up the issue and 
+  providing a test case);
+  
+- Fixed issue where the first usage of ``qapp`` fixture would return ``None``. 
+  Thanks to `@gqmelo`_ for noticing and providing a PR;
+- New ``qtlog`` now sports a context manager method, ``disabled`` (58_). 
+  Thanks `@The-Compiler`_ for the idea and testing;
+  
+.. _55: https://github.com/pytest-dev/pytest-qt/issues/55
+.. _58: https://github.com/pytest-dev/pytest-qt/issues/58
+.. _59: https://github.com/pytest-dev/pytest-qt/issues/59
+
+1.4.0
+-----
+
+- Messages sent by ``qDebug``, ``qWarning``, ``qCritical`` are captured and displayed 
+  when tests fail, similar to `pytest-catchlog`_. Also, tests 
+  can be configured to automatically fail if an unexpected message is generated. 
+  
+- New method ``waitSignals``: will block untill **all** signals given are 
+  triggered (thanks `@The-Compiler`_ for idea and complete PR).
+  
+- New parameter ``raising`` to ``waitSignals`` and ``waitSignals``: when ``True`` 
+  will raise a ``qtbot.SignalTimeoutError`` exception when 
+  timeout is reached (defaults to ``False``). 
+  (thanks again to `@The-Compiler`_ for idea and complete PR).
+  
+- ``pytest-qt`` now requires ``pytest`` version >= 2.7.
+
+.. _pytest-catchlog: https://pypi.python.org/pypi/pytest-catchlog
+
+Internal changes to improve memory management
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+- ``QApplication.exit()`` is no longer called at the end of the test session 
+  and the ``QApplication`` instance is not garbage collected anymore;
+  
+- ``QtBot`` no longer receives a QApplication as a parameter in the 
+  constructor, always referencing ``QApplication.instance()`` now; this avoids 
+  keeping an extra reference in the ``qtbot`` instances.
+  
+- ``deleteLater`` is called on widgets added in ``QtBot.addWidget`` at the end 
+  of each test;
+  
+- ``QApplication.processEvents()`` is called at the end of each test to 
+  make sure widgets are cleaned up;
+
+1.3.0
+-----
+
+- pytest-qt now supports `PyQt5`_!
+
+  Which Qt api will be used is still detected automatically, but you can choose 
+  one using the ``PYTEST_QT_API`` environment variable 
+  (the old ``PYTEST_QT_FORCE_PYQT`` is still supported for backward compatibility).
+
+  Many thanks to `@jdreaver`_ for helping to test this release!
+  
+.. _PyQt5: http://pyqt.sourceforge.net/Docs/PyQt5/introduction.html  
+
+1.2.3
+-----
+
+- Now the module ````qt_compat```` no longer sets ``QString`` and ``QVariant`` APIs to 
+  ``2`` for PyQt, making it compatible for those still using version ``1`` of the 
+  API.
+ 
+1.2.2
+-----
+
+- Now it is possible to disable automatic exception capture by using markers or 
+  a ``pytest.ini`` option. Consult the documentation for more information. 
+  (`26`_, thanks `@datalyze-solutions`_ for bringing this up).
+  
+- ``QApplication`` instance is created only if it wasn't created yet 
+  (`21`_, thanks `@fabioz`_!)
+
+- ``addWidget`` now keeps a weak reference its widgets (`20`_, thanks `@fabioz`_)
+
+.. _26: https://github.com/pytest-dev/pytest-qt/issues/26
+.. _21: https://github.com/pytest-dev/pytest-qt/issues/21
+.. _20: https://github.com/pytest-dev/pytest-qt/issues/20
+
+1.2.1
+-----
+
+- Fixed 16_: a signal emitted immediately inside a ``waitSignal`` block now 
+  works as expected (thanks `@baudren`_).
+
+.. _16: https://github.com/pytest-dev/pytest-qt/issues/16
+
+1.2.0
+-----
+
+This version include the new ``waitSignal`` function, which makes it easy 
+to write tests for long running computations that happen in other threads 
+or processes:
+
+.. code-block:: python
+
+    def test_long_computation(qtbot):
+        app = Application()
+    
+        # Watch for the app.worker.finished signal, then start the worker.
+        with qtbot.waitSignal(app.worker.finished, timeout=10000) as blocker:
+            blocker.connect(app.worker.failed)  # Can add other signals to blocker
+            app.worker.start()
+            # Test will wait here until either signal is emitted, or 10 seconds has elapsed
+    
+        assert blocker.signal_triggered  # Assuming the work took less than 10 seconds
+        assert_application_results(app)
+
+Many thanks to `@jdreaver`_ for discussion and complete PR! (`12`_, `13`_)
+
+.. _12: https://github.com/pytest-dev/pytest-qt/issues/12
+.. _13: https://github.com/pytest-dev/pytest-qt/issues/13
+
+1.1.1
+-----
+
+- Added ``stop`` as an alias for ``stopForInteraction`` (`10`_, thanks `@itghisi`_)
+
+- Now exceptions raised in virtual methods make tests fail, instead of silently 
+  passing (`11`_). If an exception is raised, the test will fail and it exceptions 
+  that happened inside virtual calls will be printed as such::
+
+
+    E           Failed: Qt exceptions in virtual methods:
+    E           ________________________________________________________________________________
+    E             File "x:\pytest-qt\pytestqt\_tests\test_exceptions.py", line 14, in event
+    E               raise ValueError('mistakes were made')
+    E
+    E           ValueError: mistakes were made
+    E           ________________________________________________________________________________
+    E             File "x:\pytest-qt\pytestqt\_tests\test_exceptions.py", line 14, in event
+    E               raise ValueError('mistakes were made')
+    E
+    E           ValueError: mistakes were made
+    E           ________________________________________________________________________________
+
+  Thanks to `@jdreaver`_ for request and sample code!
+
+- Fixed documentation for ``QtBot``: it was not being rendered in the 
+  docs due to an import error.
+
+.. _10: https://github.com/pytest-dev/pytest-qt/issues/10
+.. _11: https://github.com/pytest-dev/pytest-qt/issues/11
+
+1.1.0
+-----
+
+Python 3 support.
+
+1.0.2
+-----
+
+Minor documentation fixes.
+
+1.0.1
+-----
+
+Small bug fix release.
+
+1.0.0
+-----
+
+First working version.
+
+
+.. _ at baudren: https://github.com/baudren
+.. _ at billyshambrook: https://github.com/billyshambrook
+.. _ at datalyze-solutions: https://github.com/datalyze-solutions
+.. _ at fabioz: https://github.com/fabioz
+.. _ at fogo: https://github.com/fogo
+.. _ at gqmelo: https://github.com/gqmelo
+.. _ at itghisi: https://github.com/itghisi
+.. _ at jdreaver: https://github.com/jdreaver
+.. _ at montefra: https://github.com/montefra
+.. _ at MShekow: https://github.com/MShekow
+.. _ at Sheeo: https://github.com/Sheeo
+.. _ at The-Compiler: https://github.com/The-Compiler
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 0000000..368cf99
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2013-2016 Bruno Oliveira and others
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
+of the Software, and to permit persons to whom the Software is furnished to do
+so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/Manifest.in b/Manifest.in
new file mode 100644
index 0000000..078d55d
--- /dev/null
+++ b/Manifest.in
@@ -0,0 +1,3 @@
+include LICENSE
+include README.rst
+include tox.ini
diff --git a/PKG-INFO b/PKG-INFO
new file mode 100644
index 0000000..349d0b2
--- /dev/null
+++ b/PKG-INFO
@@ -0,0 +1,195 @@
+Metadata-Version: 1.1
+Name: pytest-qt
+Version: 2.1.0
+Summary: pytest support for PyQt and PySide applications
+Home-page: http://github.com/pytest-dev/pytest-qt
+Author: Bruno Oliveira
+Author-email: nicoddemus at gmail.com
+License: MIT
+Description: =========
+        pytest-qt
+        =========
+        
+        pytest-qt is a `pytest`_ plugin that allows programmers to write tests
+        for `PySide`_ and `PyQt`_ applications.
+        
+        The main usage is to use the `qtbot` fixture, responsible for handling `qApp` 
+        creation as needed and provides methods to simulate user interaction, 
+        like key presses and mouse clicks:
+        
+        
+        .. code-block:: python
+        
+            def test_hello(qtbot):
+                widget = HelloWidget()
+                qtbot.addWidget(widget)
+            
+                # click in the Greet button and make sure it updates the appropriate label
+                qtbot.mouseClick(widget.button_greet, QtCore.Qt.LeftButton)
+            
+                assert widget.greet_label.text() == 'Hello!'
+        
+        
+        .. _PySide: https://pypi.python.org/pypi/PySide
+        .. _PyQt: http://www.riverbankcomputing.com/software/pyqt
+        .. _pytest: http://pytest.org
+        
+        This allows you to test and make sure your view layer is behaving the way you expect after each code change.
+        
+        .. |version| image:: http://img.shields.io/pypi/v/pytest-qt.svg
+          :target: https://pypi.python.org/pypi/pytest-qt
+          
+        .. |downloads| image:: http://img.shields.io/pypi/dm/pytest-qt.svg
+          :target: https://pypi.python.org/pypi/pytest-qt
+          
+        .. |travis| image:: https://img.shields.io/travis/pytest-dev/pytest-qt/master.svg
+          :target: https://travis-ci.org/pytest-dev/pytest-qt
+        
+        .. |coverage| image:: http://img.shields.io/coveralls/pytest-dev/pytest-qt.svg
+          :target: https://coveralls.io/r/pytest-dev/pytest-qt
+        
+        .. |docs| image:: https://readthedocs.org/projects/pytest-qt/badge/?version=latest
+          :target: https://pytest-qt.readthedocs.io
+        
+        .. |appveyor| image:: https://img.shields.io/appveyor/ci/pytest-dev/pytest-qt/master.svg
+          :target: https://ci.appveyor.com/project/nicoddemus/pytest-qt
+        
+        .. |python| image:: https://img.shields.io/pypi/pyversions/pytest-qt.svg
+          :target: https://pypi.python.org/pypi/pytest-qt/
+          :alt: Supported Python versions
+        
+        |python| |version| |downloads| |travis| |appveyor| |coverage| |docs|
+        
+        
+        Features
+        ========
+        
+        - `qtbot`_ fixture to simulate user interaction with ``Qt`` widgets.
+        - `Automatic capture`_ of ``qDebug``, ``qWarning`` and ``qCritical`` messages;
+        - waitSignal_ and waitSignals_ functions to block test execution until specific
+          signals are emitted.
+        - `Exceptions in virtual methods and slots`_ are automatically captured and
+          fail tests accordingly.
+        
+        .. _qtbot: https://pytest-qt.readthedocs.io/en/latest/reference.html#module-pytestqt.qtbot
+        .. _Automatic capture: https://pytest-qt.readthedocs.io/en/latest/logging.html
+        .. _waitSignal: https://pytest-qt.readthedocs.io/en/latest/signals.html
+        .. _waitSignals: https://pytest-qt.readthedocs.io/en/latest/signals.html
+        .. _Exceptions in virtual methods and slots: https://pytest-qt.readthedocs.io/en/latest/virtual_methods.html
+        
+        Requirements
+        ============
+        
+        Works with either PySide_ or PyQt_ (``PyQt5`` and ``PyQt4``) picking whichever
+        is available on the system, giving preference to the first one installed in
+        this order:
+        
+        - ``PyQt5``
+        - ``PySide``
+        - ``PyQt4``
+        
+        To force a particular API, set the configuration variable ``qt_api`` in your ``pytest.ini`` file to
+        ``pyqt5``, ``pyside``, ``pyqt4`` or ``pyqt4v2``. ``pyqt4v2`` sets the ``PyQt4``
+        API to `version 2`_.
+        
+        .. code-block:: ini
+        
+            [pytest]
+            qt_api=pyqt5
+        
+        
+        Alternatively, you can set the ``PYTEST_QT_API`` environment
+        variable to the same values described above (the environment variable wins over the configuration
+        if both are set).
+        
+        .. _version 2: http://pyqt.sourceforge.net/Docs/PyQt4/incompatible_apis.html
+        
+        
+        Documentation
+        =============
+        
+        Full documentation and tutorial available at `Read the Docs`_.
+        
+        .. _Read The Docs: https://pytest-qt.readthedocs.io
+        
+        Change Log
+        ==========
+        
+        Please consult the `changelog page`_.
+        
+        .. _changelog page: https://pytest-qt.readthedocs.io/en/latest/changelog.html
+        
+        Bugs/Requests
+        =============
+        
+        Please report any issues or feature requests in the `issue tracker`_.
+        
+        .. _issue tracker: https://github.com/pytest-dev/pytest-qt/issues
+        
+        Contributing
+        ============
+        
+        Contributions are welcome, so feel free to submit a bug or feature
+        request.
+        
+        Pull requests are highly appreciated! If you
+        can, include some tests that exercise the new code or test that a bug has been
+        fixed, and make sure to include yourself in the contributors list. :)
+        
+        Running tests
+        -------------
+        
+        Tests are run using `tox`_. The simplest way to test is with `PySide`_, as it
+        is available on pip and can be installed by ``tox`` automatically::
+        
+            $ tox -e py34-pyside,py27-pyside,docs
+        
+        If you want to test against `PyQt`_, install it into your global python
+        installation and use the ``py27-pyqt4``, ``py34-pyqt4`` or ``py34-pyqt5``
+        testing environments, and ``tox`` will copy the appropriate files into
+        its virtual environments to ensure isolation.
+        
+        Contributors
+        ------------
+        
+        Many thanks to:
+        
+        - Igor T. Ghisi (`@itghisi <https://github.com/itghisi>`_);
+        - John David Reaver (`@jdreaver <https://github.com/jdreaver>`_);
+        - Benjamin Hedrich (`@bh <https://github.com/bh>`_);
+        - Benjamin Audren (`@baudren <https://github.com/baudren>`_);
+        - Fabio Zadrozny (`@fabioz <https://github.com/fabioz>`_);
+        - Datalyze Solutions (`@datalyze-solutions <https://github.com/datalyze-solutions>`_);
+        - Florian Bruhin (`@The-Compiler <https://github.com/The-Compiler>`_);
+        - Guilherme Quentel Melo (`@gqmelo <https://github.com/gqmelo>`_);
+        - Francesco Montesano (`@montefra <https://github.com/montefra>`_);
+        
+        **Powered by**
+        
+        .. |pycharm| image:: https://www.jetbrains.com/pycharm/docs/logo_pycharm.png
+          :target: https://www.jetbrains.com/pycharm
+          
+        .. |pydev| image:: http://www.pydev.org/images/pydev_banner3.png
+          :target: https://www.pydev.org
+          
+        |pycharm|  
+        
+        |pydev|  
+        
+        .. _tox: https://tox.readthedocs.io
+        
+Keywords: pytest qt test unittest
+Platform: UNKNOWN
+Classifier: Development Status :: 5 - Production/Stable
+Classifier: Framework :: Pytest
+Classifier: Intended Audience :: Developers
+Classifier: License :: OSI Approved :: MIT License
+Classifier: Operating System :: OS Independent
+Classifier: Programming Language :: Python :: 2.7
+Classifier: Programming Language :: Python :: 3
+Classifier: Programming Language :: Python :: 3.4
+Classifier: Programming Language :: Python :: 3.5
+Classifier: Topic :: Desktop Environment :: Window Managers
+Classifier: Topic :: Software Development :: Quality Assurance
+Classifier: Topic :: Software Development :: Testing
+Classifier: Topic :: Software Development :: User Interfaces
diff --git a/README.rst b/README.rst
new file mode 100644
index 0000000..e4fec66
--- /dev/null
+++ b/README.rst
@@ -0,0 +1,171 @@
+=========
+pytest-qt
+=========
+
+pytest-qt is a `pytest`_ plugin that allows programmers to write tests
+for `PySide`_ and `PyQt`_ applications.
+
+The main usage is to use the `qtbot` fixture, responsible for handling `qApp` 
+creation as needed and provides methods to simulate user interaction, 
+like key presses and mouse clicks:
+
+
+.. code-block:: python
+
+    def test_hello(qtbot):
+        widget = HelloWidget()
+        qtbot.addWidget(widget)
+    
+        # click in the Greet button and make sure it updates the appropriate label
+        qtbot.mouseClick(widget.button_greet, QtCore.Qt.LeftButton)
+    
+        assert widget.greet_label.text() == 'Hello!'
+
+
+.. _PySide: https://pypi.python.org/pypi/PySide
+.. _PyQt: http://www.riverbankcomputing.com/software/pyqt
+.. _pytest: http://pytest.org
+
+This allows you to test and make sure your view layer is behaving the way you expect after each code change.
+
+.. |version| image:: http://img.shields.io/pypi/v/pytest-qt.svg
+  :target: https://pypi.python.org/pypi/pytest-qt
+  
+.. |downloads| image:: http://img.shields.io/pypi/dm/pytest-qt.svg
+  :target: https://pypi.python.org/pypi/pytest-qt
+  
+.. |travis| image:: https://img.shields.io/travis/pytest-dev/pytest-qt/master.svg
+  :target: https://travis-ci.org/pytest-dev/pytest-qt
+
+.. |coverage| image:: http://img.shields.io/coveralls/pytest-dev/pytest-qt.svg
+  :target: https://coveralls.io/r/pytest-dev/pytest-qt
+
+.. |docs| image:: https://readthedocs.org/projects/pytest-qt/badge/?version=latest
+  :target: https://pytest-qt.readthedocs.io
+
+.. |appveyor| image:: https://img.shields.io/appveyor/ci/pytest-dev/pytest-qt/master.svg
+  :target: https://ci.appveyor.com/project/nicoddemus/pytest-qt
+
+.. |python| image:: https://img.shields.io/pypi/pyversions/pytest-qt.svg
+  :target: https://pypi.python.org/pypi/pytest-qt/
+  :alt: Supported Python versions
+
+|python| |version| |downloads| |travis| |appveyor| |coverage| |docs|
+
+
+Features
+========
+
+- `qtbot`_ fixture to simulate user interaction with ``Qt`` widgets.
+- `Automatic capture`_ of ``qDebug``, ``qWarning`` and ``qCritical`` messages;
+- waitSignal_ and waitSignals_ functions to block test execution until specific
+  signals are emitted.
+- `Exceptions in virtual methods and slots`_ are automatically captured and
+  fail tests accordingly.
+
+.. _qtbot: https://pytest-qt.readthedocs.io/en/latest/reference.html#module-pytestqt.qtbot
+.. _Automatic capture: https://pytest-qt.readthedocs.io/en/latest/logging.html
+.. _waitSignal: https://pytest-qt.readthedocs.io/en/latest/signals.html
+.. _waitSignals: https://pytest-qt.readthedocs.io/en/latest/signals.html
+.. _Exceptions in virtual methods and slots: https://pytest-qt.readthedocs.io/en/latest/virtual_methods.html
+
+Requirements
+============
+
+Works with either PySide_ or PyQt_ (``PyQt5`` and ``PyQt4``) picking whichever
+is available on the system, giving preference to the first one installed in
+this order:
+
+- ``PyQt5``
+- ``PySide``
+- ``PyQt4``
+
+To force a particular API, set the configuration variable ``qt_api`` in your ``pytest.ini`` file to
+``pyqt5``, ``pyside``, ``pyqt4`` or ``pyqt4v2``. ``pyqt4v2`` sets the ``PyQt4``
+API to `version 2`_.
+
+.. code-block:: ini
+
+    [pytest]
+    qt_api=pyqt5
+
+
+Alternatively, you can set the ``PYTEST_QT_API`` environment
+variable to the same values described above (the environment variable wins over the configuration
+if both are set).
+
+.. _version 2: http://pyqt.sourceforge.net/Docs/PyQt4/incompatible_apis.html
+
+
+Documentation
+=============
+
+Full documentation and tutorial available at `Read the Docs`_.
+
+.. _Read The Docs: https://pytest-qt.readthedocs.io
+
+Change Log
+==========
+
+Please consult the `changelog page`_.
+
+.. _changelog page: https://pytest-qt.readthedocs.io/en/latest/changelog.html
+
+Bugs/Requests
+=============
+
+Please report any issues or feature requests in the `issue tracker`_.
+
+.. _issue tracker: https://github.com/pytest-dev/pytest-qt/issues
+
+Contributing
+============
+
+Contributions are welcome, so feel free to submit a bug or feature
+request.
+
+Pull requests are highly appreciated! If you
+can, include some tests that exercise the new code or test that a bug has been
+fixed, and make sure to include yourself in the contributors list. :)
+
+Running tests
+-------------
+
+Tests are run using `tox`_. The simplest way to test is with `PySide`_, as it
+is available on pip and can be installed by ``tox`` automatically::
+
+    $ tox -e py34-pyside,py27-pyside,docs
+
+If you want to test against `PyQt`_, install it into your global python
+installation and use the ``py27-pyqt4``, ``py34-pyqt4`` or ``py34-pyqt5``
+testing environments, and ``tox`` will copy the appropriate files into
... 7968 lines suppressed ...

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/pytest-qt.git



More information about the Python-modules-commits mailing list