├── README.md ├── app ├── GSM_reciever.py ├── GSM_reciever.pyc ├── GUI.py ├── GUI.pyc ├── __init__.py ├── gui.ui ├── gui.ui.py ├── main.py ├── scanner_grc.py ├── scanner_grc.pyc ├── sniffer.py └── sniffer.pyc ├── dependencies ├── KimiNewt-pyshark-3333414 │ ├── .gitignore │ ├── .travis.yml │ ├── LICENSE.txt │ ├── README.md │ ├── requirements.txt │ ├── src │ │ ├── MANIFEST.in │ │ ├── README.txt │ │ ├── pyshark │ │ │ ├── __init__.py │ │ │ ├── capture │ │ │ │ ├── __init__.py │ │ │ │ ├── capture.py │ │ │ │ ├── file_capture.py │ │ │ │ ├── inmem_capture.py │ │ │ │ ├── live_capture.py │ │ │ │ └── remote_capture.py │ │ │ ├── config.ini │ │ │ ├── config.py │ │ │ ├── packet │ │ │ │ ├── __init__.py │ │ │ │ ├── common.py │ │ │ │ ├── consts.py │ │ │ │ ├── layer.py │ │ │ │ ├── packet.py │ │ │ │ └── packet_summary.py │ │ │ └── tshark │ │ │ │ ├── __init__.py │ │ │ │ ├── tshark.py │ │ │ │ └── tshark_xml.py │ │ └── setup.py │ └── tests │ │ ├── caps │ │ └── capture_test.pcapng │ │ ├── capture │ │ ├── test_capture.py │ │ └── test_inmem_capture.py │ │ ├── conftest.py │ │ ├── test_basic_parsing.py │ │ ├── test_cap_operations.py │ │ ├── test_packet_operations.py │ │ └── test_tshark.py ├── py-1.4.30 │ ├── AUTHORS │ ├── CHANGELOG │ ├── LICENSE │ ├── MANIFEST.in │ ├── PKG-INFO │ ├── README.txt │ ├── build │ │ └── lib.linux-x86_64-2.7 │ │ │ └── py │ │ │ ├── __init__.py │ │ │ ├── __metainfo.py │ │ │ ├── _apipkg.py │ │ │ ├── _builtin.py │ │ │ ├── _code │ │ │ ├── __init__.py │ │ │ ├── _assertionnew.py │ │ │ ├── _assertionold.py │ │ │ ├── _py2traceback.py │ │ │ ├── assertion.py │ │ │ ├── code.py │ │ │ └── source.py │ │ │ ├── _error.py │ │ │ ├── _iniconfig.py │ │ │ ├── _io │ │ │ ├── __init__.py │ │ │ ├── capture.py │ │ │ ├── saferepr.py │ │ │ └── terminalwriter.py │ │ │ ├── _log │ │ │ ├── __init__.py │ │ │ ├── log.py │ │ │ └── warning.py │ │ │ ├── _path │ │ │ ├── __init__.py │ │ │ ├── cacheutil.py │ │ │ ├── common.py │ │ │ ├── local.py │ │ │ ├── svnurl.py │ │ │ └── svnwc.py │ │ │ ├── _process │ │ │ ├── __init__.py │ │ │ ├── cmdexec.py │ │ │ ├── forkedfunc.py │ │ │ └── killproc.py │ │ │ ├── _std.py │ │ │ ├── _xmlgen.py │ │ │ └── test.py │ ├── conftest.py │ ├── dist │ │ └── py-1.4.30-py2.7.egg │ ├── doc │ │ ├── Makefile │ │ ├── _templates │ │ │ └── layout.html │ │ ├── announce │ │ │ ├── release-0.9.0.txt │ │ │ ├── release-0.9.2.txt │ │ │ ├── release-1.0.0.txt │ │ │ ├── release-1.0.1.txt │ │ │ ├── release-1.0.2.txt │ │ │ ├── release-1.1.0.txt │ │ │ ├── release-1.1.1.txt │ │ │ ├── release-1.2.0.txt │ │ │ ├── release-1.2.1.txt │ │ │ ├── release-1.3.0.txt │ │ │ ├── release-1.3.1.txt │ │ │ ├── release-1.3.2.txt │ │ │ ├── release-1.3.3.txt │ │ │ ├── release-1.3.4.txt │ │ │ ├── release-1.4.0.txt │ │ │ ├── release-1.4.1.txt │ │ │ └── releases.txt │ │ ├── changelog.txt │ │ ├── code.txt │ │ ├── conf.py │ │ ├── download.html │ │ ├── example │ │ │ ├── genhtml.py │ │ │ ├── genhtmlcss.py │ │ │ └── genxml.py │ │ ├── faq.txt │ │ ├── img │ │ │ └── pylib.png │ │ ├── index.txt │ │ ├── install.txt │ │ ├── io.txt │ │ ├── links.inc │ │ ├── log.txt │ │ ├── misc.txt │ │ ├── path.txt │ │ ├── style.css │ │ └── xml.txt │ ├── py.egg-info │ │ ├── PKG-INFO │ │ ├── SOURCES.txt │ │ ├── dependency_links.txt │ │ ├── not-zip-safe │ │ └── top_level.txt │ ├── py │ │ ├── __init__.py │ │ ├── __init__.pyc │ │ ├── __metainfo.py │ │ ├── _apipkg.py │ │ ├── _apipkg.pyc │ │ ├── _builtin.py │ │ ├── _code │ │ │ ├── __init__.py │ │ │ ├── _assertionnew.py │ │ │ ├── _assertionold.py │ │ │ ├── _py2traceback.py │ │ │ ├── assertion.py │ │ │ ├── code.py │ │ │ └── source.py │ │ ├── _error.py │ │ ├── _iniconfig.py │ │ ├── _io │ │ │ ├── __init__.py │ │ │ ├── capture.py │ │ │ ├── saferepr.py │ │ │ └── terminalwriter.py │ │ ├── _log │ │ │ ├── __init__.py │ │ │ ├── log.py │ │ │ └── warning.py │ │ ├── _path │ │ │ ├── __init__.py │ │ │ ├── cacheutil.py │ │ │ ├── common.py │ │ │ ├── local.py │ │ │ ├── svnurl.py │ │ │ └── svnwc.py │ │ ├── _process │ │ │ ├── __init__.py │ │ │ ├── cmdexec.py │ │ │ ├── forkedfunc.py │ │ │ └── killproc.py │ │ ├── _std.py │ │ ├── _xmlgen.py │ │ └── test.py │ ├── setup.cfg │ ├── setup.py │ ├── testing │ │ ├── code │ │ │ ├── test_assertion.py │ │ │ ├── test_code.py │ │ │ ├── test_excinfo.py │ │ │ └── test_source.py │ │ ├── conftest.py │ │ ├── io_ │ │ │ ├── __init__.py │ │ │ ├── test_capture.py │ │ │ ├── test_saferepr.py │ │ │ └── test_terminalwriter.py │ │ ├── log │ │ │ ├── __init__.py │ │ │ ├── test_log.py │ │ │ └── test_warning.py │ │ ├── path │ │ │ ├── common.py │ │ │ ├── conftest.py │ │ │ ├── repotest.dump │ │ │ ├── svntestbase.py │ │ │ ├── test_cacheutil.py │ │ │ ├── test_local.py │ │ │ ├── test_svnauth.py │ │ │ ├── test_svnurl.py │ │ │ └── test_svnwc.py │ │ ├── process │ │ │ ├── __init__.py │ │ │ ├── test_cmdexec.py │ │ │ ├── test_forkedfunc.py │ │ │ └── test_killproc.py │ │ ├── root │ │ │ ├── __init__.py │ │ │ ├── test_builtin.py │ │ │ ├── test_error.py │ │ │ ├── test_py_imports.py │ │ │ ├── test_std.py │ │ │ └── test_xmlgen.py │ │ └── test_iniconfig.py │ └── tox.ini ├── pytest-2.8.1 │ ├── .coveragerc │ ├── .gitattributes │ ├── .gitignore │ ├── .travis.yml │ ├── AUTHORS │ ├── CHANGELOG │ ├── CONTRIBUTING.rst │ ├── HOWTORELEASE.rst │ ├── ISSUES.txt │ ├── LICENSE │ ├── MANIFEST.in │ ├── PKG-INFO │ ├── README.rst │ ├── _pytest │ │ ├── __init__.py │ │ ├── _argcomplete.py │ │ ├── _pluggy.py │ │ ├── assertion │ │ │ ├── __init__.py │ │ │ ├── newinterpret.py │ │ │ ├── oldinterpret.py │ │ │ ├── reinterpret.py │ │ │ ├── rewrite.py │ │ │ └── util.py │ │ ├── cacheprovider.py │ │ ├── capture.py │ │ ├── config.py │ │ ├── doctest.py │ │ ├── genscript.py │ │ ├── helpconfig.py │ │ ├── hookspec.py │ │ ├── impl │ │ ├── junitxml.py │ │ ├── main.py │ │ ├── mark.py │ │ ├── monkeypatch.py │ │ ├── nose.py │ │ ├── pastebin.py │ │ ├── pdb.py │ │ ├── pytester.py │ │ ├── python.py │ │ ├── recwarn.py │ │ ├── resultlog.py │ │ ├── runner.py │ │ ├── skipping.py │ │ ├── standalonetemplate.py │ │ ├── terminal.py │ │ ├── tmpdir.py │ │ ├── unittest.py │ │ └── vendored_packages │ │ │ ├── README.md │ │ │ ├── __init__.py │ │ │ ├── pluggy-0.3.1.dist-info │ │ │ ├── DESCRIPTION.rst │ │ │ ├── METADATA │ │ │ ├── RECORD │ │ │ ├── WHEEL │ │ │ ├── metadata.json │ │ │ ├── pbr.json │ │ │ └── top_level.txt │ │ │ └── pluggy.py │ ├── appveyor.yml │ ├── appveyor │ │ └── install.ps1 │ ├── bench │ │ ├── bench.py │ │ ├── bench_argcomplete.py │ │ ├── empty.py │ │ ├── manyparam.py │ │ └── skip.py │ ├── doc │ │ └── en │ │ │ ├── Makefile │ │ │ ├── _getdoctarget.py │ │ │ ├── _templates │ │ │ ├── globaltoc.html │ │ │ ├── layout.html │ │ │ ├── links.html │ │ │ └── sidebarintro.html │ │ │ ├── _themes │ │ │ ├── .gitignore │ │ │ ├── LICENSE │ │ │ ├── README │ │ │ ├── flask │ │ │ │ ├── layout.html │ │ │ │ ├── relations.html │ │ │ │ ├── static │ │ │ │ │ └── flasky.css_t │ │ │ │ └── theme.conf │ │ │ └── flask_theme_support.py │ │ │ ├── adopt.rst │ │ │ ├── announce │ │ │ ├── index.rst │ │ │ ├── release-2.0.0.rst │ │ │ ├── release-2.0.1.rst │ │ │ ├── release-2.0.2.rst │ │ │ ├── release-2.0.3.rst │ │ │ ├── release-2.1.0.rst │ │ │ ├── release-2.1.1.rst │ │ │ ├── release-2.1.2.rst │ │ │ ├── release-2.1.3.rst │ │ │ ├── release-2.2.0.rst │ │ │ ├── release-2.2.1.rst │ │ │ ├── release-2.2.2.rst │ │ │ ├── release-2.2.4.rst │ │ │ ├── release-2.3.0.rst │ │ │ ├── release-2.3.1.rst │ │ │ ├── release-2.3.2.rst │ │ │ ├── release-2.3.3.rst │ │ │ ├── release-2.3.4.rst │ │ │ ├── release-2.3.5.rst │ │ │ ├── release-2.4.0.rst │ │ │ ├── release-2.4.1.rst │ │ │ ├── release-2.4.2.rst │ │ │ ├── release-2.5.0.rst │ │ │ ├── release-2.5.1.rst │ │ │ ├── release-2.5.2.rst │ │ │ ├── release-2.6.0.rst │ │ │ ├── release-2.6.1.rst │ │ │ ├── release-2.6.2.rst │ │ │ ├── release-2.6.3.rst │ │ │ ├── release-2.7.0.rst │ │ │ ├── release-2.7.1.rst │ │ │ └── release-2.7.2.rst │ │ │ ├── assert.rst │ │ │ ├── bash-completion.rst │ │ │ ├── builtin.rst │ │ │ ├── cache.rst │ │ │ ├── capture.rst │ │ │ ├── changelog.rst │ │ │ ├── check_sphinx.py │ │ │ ├── conf.py │ │ │ ├── conftest.py │ │ │ ├── contact.rst │ │ │ ├── contents.rst │ │ │ ├── contributing.rst │ │ │ ├── customize.rst │ │ │ ├── doctest.rst │ │ │ ├── example │ │ │ ├── assertion │ │ │ │ ├── failure_demo.py │ │ │ │ ├── global_testmodule_config │ │ │ │ │ ├── conftest.py │ │ │ │ │ └── test_hello.py │ │ │ │ ├── test_failures.py │ │ │ │ └── test_setup_flow_example.py │ │ │ ├── attic.rst │ │ │ ├── conftest.py │ │ │ ├── costlysetup │ │ │ │ ├── conftest.py │ │ │ │ ├── sub1 │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── test_quick.py │ │ │ │ └── sub2 │ │ │ │ │ ├── __init__.py │ │ │ │ │ └── test_two.py │ │ │ ├── index.rst │ │ │ ├── layout1 │ │ │ │ └── setup.cfg │ │ │ ├── markers.rst │ │ │ ├── multipython.py │ │ │ ├── nonpython.rst │ │ │ ├── nonpython │ │ │ │ ├── __init__.py │ │ │ │ ├── conftest.py │ │ │ │ └── test_simple.yml │ │ │ ├── parametrize.rst │ │ │ ├── py2py3 │ │ │ │ ├── conftest.py │ │ │ │ ├── test_py2.py │ │ │ │ └── test_py3.py │ │ │ ├── pythoncollection.py │ │ │ ├── pythoncollection.rst │ │ │ ├── reportingdemo.rst │ │ │ ├── simple.rst │ │ │ ├── special.rst │ │ │ └── xfail_demo.py │ │ │ ├── faq.rst │ │ │ ├── feedback.rst │ │ │ ├── fixture.rst │ │ │ ├── funcarg_compare.rst │ │ │ ├── funcargs.rst │ │ │ ├── genapi.py │ │ │ ├── getting-started.rst │ │ │ ├── goodpractises.rst │ │ │ ├── img │ │ │ ├── cramer2.png │ │ │ ├── gaynor3.png │ │ │ ├── keleshev.png │ │ │ ├── pullrequest.png │ │ │ ├── pylib.png │ │ │ ├── pytest1.png │ │ │ ├── pytest1favi.ico │ │ │ └── theuni.png │ │ │ ├── index.rst │ │ │ ├── links.inc │ │ │ ├── mark.rst │ │ │ ├── monkeypatch.rst │ │ │ ├── naming20.rst │ │ │ ├── nose.rst │ │ │ ├── overview.rst │ │ │ ├── parametrize.rst │ │ │ ├── plugins.rst │ │ │ ├── plugins_index │ │ │ ├── bitbucket.png │ │ │ ├── github.png │ │ │ ├── index.rst │ │ │ └── plugins_index.py │ │ │ ├── projects.rst │ │ │ ├── pytest.ini │ │ │ ├── recwarn.rst │ │ │ ├── setup.rst │ │ │ ├── skipping.rst │ │ │ ├── status.rst │ │ │ ├── talks.rst │ │ │ ├── test │ │ │ ├── attic.rst │ │ │ ├── config.html │ │ │ ├── dist.html │ │ │ ├── extend.html │ │ │ ├── index.rst │ │ │ ├── mission.rst │ │ │ ├── plugin │ │ │ │ ├── cov.rst │ │ │ │ ├── coverage.rst │ │ │ │ ├── django.rst │ │ │ │ ├── figleaf.rst │ │ │ │ ├── genscript.rst │ │ │ │ ├── helpconfig.rst │ │ │ │ ├── index.rst │ │ │ │ ├── links.rst │ │ │ │ ├── nose.rst │ │ │ │ ├── oejskit.rst │ │ │ │ ├── terminal.rst │ │ │ │ └── xdist.rst │ │ │ └── test.html │ │ │ ├── tmpdir.rst │ │ │ ├── unittest.rst │ │ │ ├── usage.rst │ │ │ ├── writing_plugins.rst │ │ │ ├── xdist.rst │ │ │ ├── xunit_setup.rst │ │ │ └── yieldfixture.rst │ ├── extra │ │ ├── get_issues.py │ │ └── setup-py.test │ │ │ └── setup.py │ ├── plugin-test.sh │ ├── pytest.py │ ├── requirements-docs.txt │ ├── runtox.py │ ├── setup.cfg │ ├── setup.py │ ├── testing │ │ ├── acceptance_test.py │ │ ├── cx_freeze │ │ │ ├── install_cx_freeze.py │ │ │ ├── runtests_script.py │ │ │ ├── runtests_setup.py │ │ │ ├── tests │ │ │ │ ├── test_doctest.txt │ │ │ │ └── test_trivial.py │ │ │ └── tox_run.py │ │ ├── python │ │ │ ├── collect.py │ │ │ ├── fixture.py │ │ │ ├── integration.py │ │ │ ├── metafunc.py │ │ │ └── raises.py │ │ ├── test_argcomplete.py │ │ ├── test_assertinterpret.py │ │ ├── test_assertion.py │ │ ├── test_assertrewrite.py │ │ ├── test_cache.py │ │ ├── test_capture.py │ │ ├── test_collection.py │ │ ├── test_config.py │ │ ├── test_conftest.py │ │ ├── test_doctest.py │ │ ├── test_genscript.py │ │ ├── test_helpconfig.py │ │ ├── test_junitxml.py │ │ ├── test_mark.py │ │ ├── test_monkeypatch.py │ │ ├── test_nose.py │ │ ├── test_parseopt.py │ │ ├── test_pastebin.py │ │ ├── test_pdb.py │ │ ├── test_pluginmanager.py │ │ ├── test_pytester.py │ │ ├── test_recwarn.py │ │ ├── test_resultlog.py │ │ ├── test_runner.py │ │ ├── test_runner_xunit.py │ │ ├── test_session.py │ │ ├── test_skipping.py │ │ ├── test_terminal.py │ │ ├── test_tmpdir.py │ │ └── test_unittest.py │ └── tox.ini ├── readme └── readme~ ├── grc ├── flow graph 1.grc └── flow graph 2.grc └── readme~ /README.md: -------------------------------------------------------------------------------- 1 | 2 | This application scan all GSM carriers in the area and detect the beacon channels of each GSM operator. It provide also a list of neighbor beacons. 3 | This list can be used to initiate a man in the middle attack on a chosen operator by launching (openbts/yatebts) with one of his ARFCN in the list. 4 | 5 | the folder grc contains the gnuradio-companion flow graphs 6 | the folder app contains the python scripts of the application 7 | the folder dependencies contains the applications you need to install to run this program. 8 | 9 | 10 | -------------------------------------------------------------------------------- /app/GSM_reciever.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/app/GSM_reciever.pyc -------------------------------------------------------------------------------- /app/GUI.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/app/GUI.pyc -------------------------------------------------------------------------------- /app/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/app/__init__.py -------------------------------------------------------------------------------- /app/gui.ui: -------------------------------------------------------------------------------- 1 | 2 | 3 | MainWindow 4 | 5 | 6 | 7 | 0 8 | 0 9 | 800 10 | 600 11 | 12 | 13 | 14 | MainWindow 15 | 16 | 17 | 18 | 19 | 20 | 10 21 | 30 22 | 551 23 | 111 24 | 25 | 26 | 27 | true 28 | 29 | 30 | 31 | 32 | 33 | 34 | 0 35 | 0 36 | 800 37 | 21 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /app/gui.ui.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | # Form implementation generated from reading ui file 'untitled.ui' 4 | # 5 | # Created by: PyQt4 UI code generator 4.11.4 6 | # 7 | # WARNING! All changes made in this file will be lost! 8 | 9 | from PyQt4 import QtCore, QtGui 10 | 11 | try: 12 | _fromUtf8 = QtCore.QString.fromUtf8 13 | except AttributeError: 14 | def _fromUtf8(s): 15 | return s 16 | 17 | try: 18 | _encoding = QtGui.QApplication.UnicodeUTF8 19 | def _translate(context, text, disambig): 20 | return QtGui.QApplication.translate(context, text, disambig, _encoding) 21 | except AttributeError: 22 | def _translate(context, text, disambig): 23 | return QtGui.QApplication.translate(context, text, disambig) 24 | 25 | class Ui_MainWindow(object): 26 | def setupUi(self, MainWindow): 27 | MainWindow.setObjectName(_fromUtf8("MainWindow")) 28 | MainWindow.resize(800, 600) 29 | self.centralwidget = QtGui.QWidget(MainWindow) 30 | self.centralwidget.setObjectName(_fromUtf8("centralwidget")) 31 | self.plainTextEdit = QtGui.QPlainTextEdit(self.centralwidget) 32 | self.plainTextEdit.setGeometry(QtCore.QRect(10, 30, 551, 111)) 33 | self.plainTextEdit.setReadOnly(True) 34 | self.plainTextEdit.setObjectName(_fromUtf8("plainTextEdit")) 35 | MainWindow.setCentralWidget(self.centralwidget) 36 | self.menubar = QtGui.QMenuBar(MainWindow) 37 | self.menubar.setGeometry(QtCore.QRect(0, 0, 800, 21)) 38 | self.menubar.setObjectName(_fromUtf8("menubar")) 39 | MainWindow.setMenuBar(self.menubar) 40 | self.statusbar = QtGui.QStatusBar(MainWindow) 41 | self.statusbar.setObjectName(_fromUtf8("statusbar")) 42 | MainWindow.setStatusBar(self.statusbar) 43 | 44 | self.retranslateUi(MainWindow) 45 | QtCore.QMetaObject.connectSlotsByName(MainWindow) 46 | 47 | def retranslateUi(self, MainWindow): 48 | MainWindow.setWindowTitle(_translate("MainWindow", "MainWindow", None)) 49 | 50 | -------------------------------------------------------------------------------- /app/scanner_grc.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/app/scanner_grc.pyc -------------------------------------------------------------------------------- /app/sniffer.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/app/sniffer.pyc -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/.travis.yml: -------------------------------------------------------------------------------- 1 | language: python 2 | python: 3 | - "2.7" 4 | - "2.6" 5 | - "3.3" 6 | - "3.4" 7 | before_install: 8 | - sudo apt-get update -qq 9 | - sudo apt-get install -y tshark 10 | script: 11 | - pip install -r requirements.txt 12 | - cd src/ 13 | - python setup.py install 14 | - cd ../tests 15 | - py.test 16 | 17 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/LICENSE.txt: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 Dor Green 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/requirements.txt: -------------------------------------------------------------------------------- 1 | # Development requirements. Only required for testing 2 | py 3 | pytest 4 | mock 5 | logbook 6 | trollius 7 | lxml -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/MANIFEST.in: -------------------------------------------------------------------------------- 1 | include pyshark/config.ini -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/README.txt: -------------------------------------------------------------------------------- 1 | pyshark 2 | ======= 3 | 4 | Python wrapper for tshark, allowing python packet parsing using wireshark dissectors. 5 | 6 | There are quite a few python packet parsing modules, this one is different because it doesn't actually parse any packets, it simply uses tshark's (wireshark command-line utility) ability to export XMLs to use its parsing. 7 | 8 | This package allows parsing from a capture file or a live capture, using all wireshark dissectors you have installed. 9 | Tested on windows/linux. 10 | 11 | Usage 12 | ===== 13 | 14 | Reading from a capture file: 15 | ---------------------------- 16 | 17 | :: 18 | 19 | import pyshark 20 | cap = pyshark.FileCapture('/tmp/mycapture.cap') 21 | cap 22 | >>> 23 | print cap[0] 24 | Packet (Length: 698) 25 | Layer ETH: 26 | Destination: BLANKED 27 | Source: BLANKED 28 | Type: IP (0x0800) 29 | Layer IP: 30 | Version: 4 31 | Header Length: 20 bytes 32 | Differentiated Services Field: 0x00 (DSCP 0x00: Default; ECN: 0x00: Not-ECT (Not ECN-Capable Transport)) 33 | Total Length: 684s 34 | Identification: 0x254f (9551) 35 | Flags: 0x00 36 | Fragment offset: 0 37 | Time to live: 1 38 | Protocol: UDP (17) 39 | Header checksum: 0xe148 [correct] 40 | Source: BLANKED 41 | Destination: BLANKED 42 | ... 43 | 44 | 45 | Reading from a live interface: 46 | ------------------------------ 47 | 48 | :: 49 | 50 | capture = pyshark.LiveCapture(interface='eth0') 51 | capture.sniff(timeout=50) 52 | capture 53 | >>> 54 | capture[3] 55 | 56 | 57 | for packet in capture.sniff_continuously(packet_count=5): 58 | print 'Just arrived:', packet 59 | 60 | 61 | Accessing packet data: 62 | ---------------------- 63 | 64 | Data can be accessed in multiple ways. 65 | Packets are divided into layers, first you have to reach the appropriate layer and then you can select your field. 66 | 67 | All of the following work:: 68 | 69 | packet['ip'].dst 70 | >>> 192.168.0.1 71 | packet.ip.src 72 | >>> 192.168.0.100 73 | packet[2].src 74 | >>> 192.168.0.100 75 | 76 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/__init__.py: -------------------------------------------------------------------------------- 1 | from pyshark.capture.live_capture import LiveCapture 2 | from pyshark.capture.file_capture import FileCapture 3 | from pyshark.capture.remote_capture import RemoteCapture 4 | from pyshark.capture.inmem_capture import InMemCapture -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/capture/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/KimiNewt-pyshark-3333414/src/pyshark/capture/__init__.py -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/capture/remote_capture.py: -------------------------------------------------------------------------------- 1 | from pyshark import LiveCapture 2 | 3 | 4 | class RemoteCapture(LiveCapture): 5 | """ 6 | A capture which is performed on a remote machine which has an rpcapd service running. 7 | """ 8 | 9 | def __init__(self, remote_host, remote_interface, remote_port=2002, bpf_filter=None, only_summaries=False, 10 | decryption_key=None, encryption_type='wpa-pwk', decode_as=None, tshark_path=None): 11 | """ 12 | Creates a new remote capture which will connect to a remote machine which is running rpcapd. Use the sniff() method 13 | to get packets. 14 | Note: The remote machine should have rpcapd running in null authentication mode (-n). Be warned that the traffic 15 | is unencrypted! 16 | 17 | :param remote_host: The remote host to capture on (IP or hostname). Should be running rpcapd. 18 | :param remote_interface: The remote interface on the remote machine to capture on. Note that on windows it is 19 | not the device display name but the true interface name (i.e. \\Device\\NPF_..). 20 | :param remote_port: The remote port the rpcapd service is listening on 21 | :param bpf_filter: A BPF (tcpdump) filter to apply on the cap before reading. 22 | :param only_summaries: Only produce packet summaries, much faster but includes very little information 23 | :param decryption_key: Key used to encrypt and decrypt captured traffic. 24 | :param encryption_type: Standard of encryption used in captured traffic (must be either 'WEP', 'WPA-PWD', 25 | or 'WPA-PWK'. Defaults to WPA-PWK). 26 | :param decode_as: A dictionary of {decode_criterion_string: decode_as_protocol} that are used to tell tshark 27 | to decode protocols in situations it wouldn't usually, for instance {'tcp.port==8888': 'http'} would make 28 | it attempt to decode any port 8888 traffic as HTTP. See tshark documentation for details. 29 | :param tshark_path: Path of the tshark binary 30 | """ 31 | interface = 'rpcap://%s:%d/%s' % (remote_host, remote_port, remote_interface) 32 | super(RemoteCapture, self).__init__(interface, bpf_filter=bpf_filter, only_summaries=only_summaries, 33 | decryption_key=decryption_key, encryption_type=encryption_type, 34 | tshark_path=tshark_path, decode_as=decode_as) 35 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/config.ini: -------------------------------------------------------------------------------- 1 | [tshark] 2 | # Specify the path to the tshark executable. 3 | # If the configured path does not exist, these locations will be searched: 4 | # (Linux): /usr/bin/tshark 5 | # (Linux): /usr/sbin/tshark 6 | # (Linux): /usr/lib/tshark/tshark 7 | # (Linux): /usr/local/bin/tshark 8 | # (Windows): %ProgramFiles%\Wireshark\tshark.exe 9 | # (Windows): %ProgramFiles(x86)%\Wireshark\tshark.exe 10 | tshark_path = C:\Program Files\Wireshark\tshark.exe 11 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/config.py: -------------------------------------------------------------------------------- 1 | import pyshark 2 | import py 3 | import os 4 | 5 | CONFIG_PATH = os.path.join(os.path.dirname(pyshark.__file__), 'config.ini') 6 | 7 | def get_config(): 8 | return py.iniconfig.IniConfig(CONFIG_PATH) -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/packet/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/KimiNewt-pyshark-3333414/src/pyshark/packet/__init__.py -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/packet/common.py: -------------------------------------------------------------------------------- 1 | class Pickleable(object): 2 | """ 3 | Base class that implements getstate/setstate, since most of the classes are overriding getattr. 4 | """ 5 | 6 | def __getstate__(self): 7 | return self.__dict__ 8 | 9 | def __setstate__(self, data): 10 | self.__dict__.update(data) -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/packet/consts.py: -------------------------------------------------------------------------------- 1 | TRANSPORT_LAYERS = ['UDP', 'TCP'] -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/packet/packet_summary.py: -------------------------------------------------------------------------------- 1 | class PacketSummary(object): 2 | """ 3 | A simple object containing a psml summary. 4 | Can contain various summary information about a packet. 5 | """ 6 | 7 | def __init__(self, structure, values): 8 | self._fields = {} 9 | self._field_order = [] 10 | 11 | for key, val in zip(structure, values): 12 | key, val = str(key), str(val) 13 | self._fields[key] = val 14 | self._field_order.append(key) 15 | setattr(self, key.lower().replace('.', '').replace(',', ''), val) 16 | 17 | def __repr__(self): 18 | protocol, src, dst = self._fields.get('Protocol', '?'), self._fields.get('Source', '?'),\ 19 | self._fields.get('Destination', '?') 20 | return '<%s %s: %s to %s>' % (self.__class__.__name__, protocol, src, dst) 21 | 22 | def __str__(self): 23 | return self.summary_line 24 | 25 | @property 26 | def summary_line(self): 27 | return ' '.join([self._fields[key] for key in self._field_order]) 28 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/tshark/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/KimiNewt-pyshark-3333414/src/pyshark/tshark/__init__.py -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/pyshark/tshark/tshark_xml.py: -------------------------------------------------------------------------------- 1 | """ 2 | This module contains functions to turn TShark XML parts into Packet objects. 3 | """ 4 | import lxml.objectify 5 | from pyshark.packet.layer import Layer 6 | from pyshark.packet.packet import Packet 7 | from pyshark.packet.packet_summary import PacketSummary 8 | 9 | 10 | def psml_structure_from_xml(psml_structure): 11 | if not isinstance(psml_structure, lxml.objectify.ObjectifiedElement): 12 | psml_structure = lxml.objectify.fromstring(psml_structure) 13 | return psml_structure.findall('section') 14 | 15 | 16 | def packet_from_xml_packet(xml_pkt, psml_structure=None): 17 | """ 18 | Gets a TShark XML packet object or string, and returns a pyshark Packet objec.t 19 | 20 | :param xml_pkt: str or xml object. 21 | :param psml_structure: a list of the fields in each packet summary in the psml data. If given, packets will 22 | be returned as a PacketSummary object. 23 | :return: Packet object. 24 | """ 25 | if not isinstance(xml_pkt, lxml.objectify.ObjectifiedElement): 26 | parser = lxml.objectify.makeparser(huge_tree=True) 27 | xml_pkt = lxml.objectify.fromstring(xml_pkt, parser) 28 | if psml_structure: 29 | return _packet_from_psml_packet(xml_pkt, psml_structure) 30 | return _packet_from_pdml_packet(xml_pkt) 31 | 32 | 33 | def _packet_from_psml_packet(psml_packet, structure): 34 | return PacketSummary(structure, psml_packet.findall('section')) 35 | 36 | 37 | def _packet_from_pdml_packet(pdml_packet): 38 | layers = [Layer(proto) for proto in pdml_packet.proto] 39 | geninfo, frame, layers = layers[0], layers[1], layers[2:] 40 | return Packet(layers=layers, frame_info=frame, number=geninfo.get_field_value('num'), 41 | length=geninfo.get_field_value('len'), sniff_time=geninfo.get_field_value('timestamp', raw=True), 42 | captured_length=geninfo.get_field_value('caplen'), 43 | interface_captured=frame.get_field_value('interface_id', raw=True)) 44 | 45 | 46 | 47 | def packets_from_xml(xml_data): 48 | """ 49 | Returns a list of Packet objects from a TShark XML. 50 | 51 | :param xml_data: str containing the XML. 52 | """ 53 | pdml = lxml.objectify.fromstring(xml_data) 54 | packets = [] 55 | 56 | for xml_pkt in pdml.getchildren(): 57 | packets += [packet_from_xml_packet(xml_pkt)] 58 | return packets -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/src/setup.py: -------------------------------------------------------------------------------- 1 | import os 2 | from setuptools import setup, find_packages 3 | 4 | with open(os.path.join(os.path.dirname(__file__), 'README.txt')) as f: 5 | long_description = f.read() 6 | 7 | setup( 8 | name="pyshark", 9 | version="0.3.6", 10 | packages=find_packages(), 11 | package_data={'': ['*.ini', '*.pcapng']}, 12 | install_requires=['lxml', 'py', 'trollius', 'logbook'], 13 | tests_require=['mock', 'pytest'], 14 | url="https://github.com/KimiNewt/pyshark", 15 | long_description=long_description, 16 | author="KimiNewt", 17 | description="Python wrapper for tshark, allowing python packet parsing using wireshark dissectors", 18 | keywords="wireshark capture packets parsing packet", 19 | use_2to3=True, 20 | ) 21 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/tests/caps/capture_test.pcapng: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/KimiNewt-pyshark-3333414/tests/caps/capture_test.pcapng -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/tests/capture/test_capture.py: -------------------------------------------------------------------------------- 1 | from pyshark.capture.capture import Capture 2 | 3 | 4 | def test_capture_gets_decoding_parameters(): 5 | c = Capture(decode_as={'tcp.port==8888': 'http'}) 6 | params = c.get_parameters() 7 | decode_index = params.index('-d') 8 | assert params[decode_index + 1] == 'tcp.port==8888,http' 9 | 10 | 11 | def test_capture_gets_multiple_decoding_parameters(): 12 | c = Capture(decode_as={'tcp.port==8888': 'http', 'tcp.port==6666': 'dns'}) 13 | params = c.get_parameters() 14 | decode_index = params.index('-d') 15 | possible_results = ['tcp.port==8888,http', 'tcp.port==6666,dns'] 16 | assert params[decode_index + 1] in possible_results 17 | possible_results.remove(params[decode_index + 1]) 18 | decode_index = params.index('-d', decode_index + 1) 19 | assert params[decode_index + 1] == possible_results[0] 20 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/tests/capture/test_inmem_capture.py: -------------------------------------------------------------------------------- 1 | import binascii 2 | import pytest 3 | import pyshark 4 | 5 | 6 | @pytest.fixture 7 | def inmem_capture(): 8 | return pyshark.InMemCapture() 9 | 10 | 11 | def arp_packet(last_byte='f'): 12 | """ 13 | Returns an ARP packet from aa:bb:cc:dd:ee:fX 14 | """ 15 | p = "ffffffffffffaabbccddeef%s0806000108000604000104a151c32ad10a0000020000000000000a000001" % last_byte 16 | return binascii.unhexlify(p) 17 | 18 | 19 | def test_can_read_binary_packet(inmem_capture): 20 | pkt = inmem_capture.feed_packet(arp_packet('f')) 21 | assert pkt.eth.src == 'aa:bb:cc:dd:ee:ff' 22 | 23 | 24 | def test_can_read_multiple_binary_packet(inmem_capture): 25 | pkts = inmem_capture.feed_packets([arp_packet('1'), arp_packet('2'), arp_packet('3')]) 26 | assert len(pkts) == 3 27 | 28 | for i, pkt in enumerate(pkts): 29 | assert pkt.eth.src == 'aa:bb:cc:dd:ee:f' + str(i + 1) 30 | 31 | def test_fed_packets_are_added_to_the_list(inmem_capture): 32 | inmem_capture.feed_packet(arp_packet()) 33 | assert len(inmem_capture) == 1 34 | 35 | inmem_capture.feed_packets([arp_packet(), arp_packet()]) 36 | assert len(inmem_capture) == 3 37 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/tests/conftest.py: -------------------------------------------------------------------------------- 1 | import os 2 | import logbook 3 | import pytest 4 | 5 | import pyshark 6 | 7 | @pytest.fixture 8 | def caps_directory(): 9 | return os.path.join(os.path.dirname(__file__), 'caps') 10 | 11 | @pytest.fixture 12 | def lazy_simple_capture(request, caps_directory): 13 | """ 14 | Does not fill the cap with packets. 15 | """ 16 | cap_path = os.path.join(caps_directory, 'capture_test.pcapng') 17 | cap = pyshark.FileCapture(cap_path) 18 | cap.log.level = logbook.DEBUG 19 | 20 | def finalizer(): 21 | cap.close() 22 | cap.eventloop.stop() 23 | request.addfinalizer(finalizer) 24 | return cap 25 | 26 | @pytest.fixture 27 | def simple_capture(lazy_simple_capture): 28 | """ 29 | A capture already full of packets 30 | """ 31 | lazy_simple_capture.load_packets() 32 | return lazy_simple_capture -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/tests/test_basic_parsing.py: -------------------------------------------------------------------------------- 1 | def test_count_packets(simple_capture): 2 | """Test to make sure the right number of packets are read from a known 3 | capture""" 4 | packet_count = sum(1 for _ in simple_capture) 5 | assert packet_count == 24 6 | 7 | 8 | def test_sum_lengths(simple_capture): 9 | """Test to make sure that the right packet length is being read from 10 | tshark's output by comparing the aggregate length of all packets 11 | to a known value""" 12 | total_length = sum(int(packet.length) for packet in simple_capture) 13 | assert total_length == 2178 14 | 15 | 16 | def test_layers(simple_capture): 17 | """Test to make sure the correct protocols are reported for known 18 | packets""" 19 | packet_indexes = (0, 5, 6, 13, 14, 17, 23) 20 | test_values = [simple_capture[i].highest_layer for i in packet_indexes] 21 | known_values = ['DNS', 'DNS', 'ICMP', 'ICMP', 'TCP', 'HTTP', 'TCP'] 22 | assert test_values == known_values 23 | 24 | 25 | def test_ethernet(simple_capture): 26 | """Test to make sure Ethernet fields are being read properly by comparing 27 | packet dissection results to known values""" 28 | packet = simple_capture[0] 29 | test_values = packet.eth.src, packet.eth.dst 30 | known_values = ('00:00:bb:10:20:10', '00:00:bb:02:04:01') 31 | assert test_values == known_values 32 | 33 | 34 | def test_icmp(simple_capture): 35 | """Test to make sure ICMP fields are being read properly by comparing 36 | packet dissection results to known values""" 37 | packet = simple_capture[11] 38 | # The value returned by tshark is locale-dependent. 39 | # Depending on the locale, a comma can be used instead of a dot 40 | # as decimal separator. 41 | resptime = packet.icmp.resptime.replace(',', '.') 42 | assert resptime == '1.667' -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/tests/test_cap_operations.py: -------------------------------------------------------------------------------- 1 | import mock 2 | import time 3 | import pytest 4 | from trollius import TimeoutError 5 | from multiprocessing import Process, Queue 6 | from multiprocessing.queues import Empty 7 | from pyshark.packet.packet_summary import PacketSummary 8 | 9 | 10 | def test_packet_callback_called_for_each_packet(lazy_simple_capture): 11 | # Test cap has 24 packets 12 | mock_callback = mock.Mock() 13 | lazy_simple_capture.apply_on_packets(mock_callback) 14 | assert mock_callback.call_count == 24 15 | 16 | 17 | def test_apply_on_packet_stops_on_timeout(lazy_simple_capture): 18 | def wait(pkt): 19 | time.sleep(5) 20 | with pytest.raises(TimeoutError): 21 | lazy_simple_capture.apply_on_packets(wait, timeout=1) 22 | 23 | 24 | def test_lazy_loading_of_packets_on_getitem(lazy_simple_capture): 25 | # Seventh packet is ICMP 26 | assert 'ICMP' in lazy_simple_capture[6] 27 | 28 | 29 | def test_lazy_loading_of_packet_does_not_recreate_packets(lazy_simple_capture): 30 | # Seventh packet is ICMP 31 | icmp_packet_id = id(lazy_simple_capture[6]) 32 | # load some more 33 | lazy_simple_capture[8] 34 | assert icmp_packet_id == id(lazy_simple_capture[6]) 35 | 36 | 37 | def test_filling_cap_in_increments(lazy_simple_capture): 38 | lazy_simple_capture.load_packets(1) 39 | assert len(lazy_simple_capture) == 1 40 | lazy_simple_capture.load_packets(2) 41 | assert len(lazy_simple_capture) == 3 42 | 43 | 44 | def test_getting_packet_summary(lazy_simple_capture): 45 | lazy_simple_capture.only_summaries = True 46 | assert isinstance(lazy_simple_capture[0], PacketSummary) 47 | 48 | # Since we cannot check the exact fields since they're dependent on wireshark configuration, we'll at least 49 | # make sure some data is in. 50 | assert lazy_simple_capture[0]._fields 51 | 52 | def _iterate_capture_object(cap_obj, q): 53 | for packet in cap_obj: 54 | pass 55 | q.put(True) 56 | 57 | def test_iterate_empty_psml_capture(lazy_simple_capture): 58 | lazy_simple_capture.only_summaries = True 59 | lazy_simple_capture.display_filter = "frame.len == 1" 60 | q = Queue() 61 | p = Process(target=_iterate_capture_object, args=(lazy_simple_capture, q)) 62 | p.start() 63 | p.join(2) 64 | try: 65 | no_hang = q.get_nowait() 66 | except Empty: 67 | no_hang = False 68 | if p.is_alive(): 69 | p.terminate() 70 | assert no_hang 71 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/tests/test_packet_operations.py: -------------------------------------------------------------------------------- 1 | import binascii 2 | import pytest 3 | 4 | 5 | @pytest.fixture 6 | def icmp_packet(simple_capture): 7 | return simple_capture[7] 8 | 9 | 10 | @pytest.mark.parametrize('access_func', [ 11 | lambda pkt: pkt[-1], 12 | lambda pkt: pkt['icmp'], 13 | lambda pkt: pkt['ICMP'], 14 | lambda pkt: pkt.icmp, 15 | ]) 16 | def test_layer_access(icmp_packet, access_func): 17 | """ 18 | Tests that layer access in various ways works the same way. 19 | """ 20 | assert access_func(icmp_packet).layer_name.upper() == 'ICMP' 21 | assert binascii.unhexlify(access_func(icmp_packet).data) == b'abcdefghijklmnopqrstuvwabcdefghi' 22 | 23 | 24 | def test_packet_contains_layer(icmp_packet): 25 | assert 'ICMP' in icmp_packet 26 | 27 | 28 | def test_raw_mode(icmp_packet): 29 | original = icmp_packet.ip.src 30 | raw = icmp_packet.ip.src.raw_value 31 | icmp_packet.ip.raw_mode = True 32 | assert icmp_packet.ip.src != original 33 | assert icmp_packet.ip.src == raw 34 | 35 | 36 | def test_frame_info_access(icmp_packet): 37 | actual = icmp_packet.frame_info.protocols 38 | expected = set(['eth:ip:icmp:data', 'eth:ethertype:ip:icmp:data']) 39 | assert actual in expected 40 | assert icmp_packet.frame_info.number == '8' 41 | -------------------------------------------------------------------------------- /dependencies/KimiNewt-pyshark-3333414/tests/test_tshark.py: -------------------------------------------------------------------------------- 1 | import mock 2 | 3 | from pyshark.tshark.tshark import ( 4 | get_tshark_display_filter_flag, 5 | get_tshark_interfaces, 6 | get_tshark_version, 7 | get_tshark_path, 8 | ) 9 | 10 | 11 | @mock.patch('os.path.exists', autospec=True) 12 | def test_get_tshark_path(mock_exists): 13 | mock_exists.return_value = True 14 | actual = get_tshark_path("/some/path/tshark") 15 | expected = "/some/path/tshark" 16 | assert actual == expected 17 | 18 | 19 | @mock.patch('pyshark.tshark.tshark.check_output', autospec=True) 20 | def test_get_tshark_version(mock_check_output): 21 | mock_check_output.return_value = ( 22 | b'TShark 1.12.1 (Git Rev Unknown from unknown)\n\n'b'Copyright ' 23 | b'1998-2014 Gerald Combs and contributors.\n' 24 | ) 25 | actual = get_tshark_version() 26 | expected = '1.12.1' 27 | assert actual == expected 28 | 29 | @mock.patch('pyshark.tshark.tshark.get_tshark_version', autospec=True) 30 | def test_get_display_filter_flag(mock_get_tshark_version): 31 | mock_get_tshark_version.return_value = '1.10.0' 32 | actual = get_tshark_display_filter_flag() 33 | expected = '-Y' 34 | assert actual == expected 35 | 36 | mock_get_tshark_version.return_value = '1.6.0' 37 | actual = get_tshark_display_filter_flag() 38 | expected = '-R' 39 | assert actual == expected 40 | 41 | @mock.patch('pyshark.tshark.tshark.check_output', autospec=True) 42 | def test_get_tshark_interfaces(mock_check_output): 43 | mock_check_output.return_value = ( 44 | b'1. wlan0\n2. any\n3. lo (Loopback)\n4. eth0\n5. docker0\n' 45 | ) 46 | actual = get_tshark_interfaces() 47 | expected = ['1', '2', '3', '4', '5'] 48 | assert actual == expected 49 | 50 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/AUTHORS: -------------------------------------------------------------------------------- 1 | Holger Krekel, holger at merlinux eu 2 | Benjamin Peterson, benjamin at python org 3 | Ronny Pfannschmidt, Ronny.Pfannschmidt at gmx de 4 | Guido Wesdorp, johnny at johnnydebris net 5 | Samuele Pedroni, pedronis at openend se 6 | Carl Friedrich Bolz, cfbolz at gmx de 7 | Armin Rigo, arigo at tunes org 8 | Maciek Fijalkowski, fijal at genesilico pl 9 | Brian Dorsey, briandorsey at gmail com 10 | Floris Bruynooghe, flub at devork be 11 | merlinux GmbH, Germany, office at merlinux eu 12 | 13 | Contributors include:: 14 | 15 | Ross Lawley 16 | Ralf Schmitt 17 | Chris Lamb 18 | Harald Armin Massa 19 | Martijn Faassen 20 | Ian Bicking 21 | Jan Balster 22 | Grig Gheorghiu 23 | Bob Ippolito 24 | Christian Tismer 25 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/LICENSE: -------------------------------------------------------------------------------- 1 | 2 | Permission is hereby granted, free of charge, to any person obtaining a copy 3 | of this software and associated documentation files (the "Software"), to deal 4 | in the Software without restriction, including without limitation the rights 5 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 6 | copies of the Software, and to permit persons to whom the Software is 7 | furnished to do so, subject to the following conditions: 8 | 9 | The above copyright notice and this permission notice shall be included in all 10 | copies or substantial portions of the Software. 11 | 12 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 14 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 15 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 16 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 17 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 18 | SOFTWARE. 19 | 20 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/MANIFEST.in: -------------------------------------------------------------------------------- 1 | include CHANGELOG 2 | include AUTHORS 3 | include README.txt 4 | include setup.py 5 | include LICENSE 6 | include conftest.py 7 | include tox.ini 8 | graft doc 9 | graft testing 10 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/PKG-INFO: -------------------------------------------------------------------------------- 1 | Metadata-Version: 1.1 2 | Name: py 3 | Version: 1.4.30 4 | Summary: library with cross-python path, ini-parsing, io, code, log facilities 5 | Home-page: http://pylib.readthedocs.org/ 6 | Author: holger krekel, Ronny Pfannschmidt, Benjamin Peterson and others 7 | Author-email: pytest-dev@python.org 8 | License: MIT license 9 | Description: .. image:: https://drone.io/bitbucket.org/pytest-dev/py/status.png 10 | :target: https://drone.io/bitbucket.org/pytest-dev/py/latest 11 | .. image:: https://pypip.in/v/py/badge.png 12 | :target: https://pypi.python.org/pypi/py 13 | 14 | The py lib is a Python development support library featuring 15 | the following tools and modules: 16 | 17 | * py.path: uniform local and svn path objects 18 | * py.apipkg: explicit API control and lazy-importing 19 | * py.iniconfig: easy parsing of .ini files 20 | * py.code: dynamic code generation and introspection 21 | 22 | NOTE: prior to the 1.4 release this distribution used to 23 | contain py.test which is now its own package, see http://pytest.org 24 | 25 | For questions and more information please visit http://pylib.readthedocs.org 26 | 27 | Bugs and issues: http://bitbucket.org/pytest-dev/py/issues/ 28 | 29 | Authors: Holger Krekel and others, 2004-2015 30 | 31 | Platform: unix 32 | Platform: linux 33 | Platform: osx 34 | Platform: cygwin 35 | Platform: win32 36 | Classifier: Development Status :: 6 - Mature 37 | Classifier: Intended Audience :: Developers 38 | Classifier: License :: OSI Approved :: MIT License 39 | Classifier: Operating System :: POSIX 40 | Classifier: Operating System :: Microsoft :: Windows 41 | Classifier: Operating System :: MacOS :: MacOS X 42 | Classifier: Topic :: Software Development :: Testing 43 | Classifier: Topic :: Software Development :: Libraries 44 | Classifier: Topic :: Utilities 45 | Classifier: Programming Language :: Python 46 | Classifier: Programming Language :: Python :: 3 47 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/README.txt: -------------------------------------------------------------------------------- 1 | .. image:: https://drone.io/bitbucket.org/pytest-dev/py/status.png 2 | :target: https://drone.io/bitbucket.org/pytest-dev/py/latest 3 | .. image:: https://pypip.in/v/py/badge.png 4 | :target: https://pypi.python.org/pypi/py 5 | 6 | The py lib is a Python development support library featuring 7 | the following tools and modules: 8 | 9 | * py.path: uniform local and svn path objects 10 | * py.apipkg: explicit API control and lazy-importing 11 | * py.iniconfig: easy parsing of .ini files 12 | * py.code: dynamic code generation and introspection 13 | 14 | NOTE: prior to the 1.4 release this distribution used to 15 | contain py.test which is now its own package, see http://pytest.org 16 | 17 | For questions and more information please visit http://pylib.readthedocs.org 18 | 19 | Bugs and issues: http://bitbucket.org/pytest-dev/py/issues/ 20 | 21 | Authors: Holger Krekel and others, 2004-2015 22 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/build/lib.linux-x86_64-2.7/py/__metainfo.py: -------------------------------------------------------------------------------- 1 | import py 2 | pydir = py.path.local(py.__file__).dirpath() 3 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/build/lib.linux-x86_64-2.7/py/_code/__init__.py: -------------------------------------------------------------------------------- 1 | """ python inspection/code generation API """ 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/build/lib.linux-x86_64-2.7/py/_io/__init__.py: -------------------------------------------------------------------------------- 1 | """ input/output helping """ 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/build/lib.linux-x86_64-2.7/py/_log/__init__.py: -------------------------------------------------------------------------------- 1 | """ logging API ('producers' and 'consumers' connected via keywords) """ 2 | 3 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/build/lib.linux-x86_64-2.7/py/_path/__init__.py: -------------------------------------------------------------------------------- 1 | """ unified file system api """ 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/build/lib.linux-x86_64-2.7/py/_process/__init__.py: -------------------------------------------------------------------------------- 1 | """ high-level sub-process handling """ 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/build/lib.linux-x86_64-2.7/py/_process/cmdexec.py: -------------------------------------------------------------------------------- 1 | import sys 2 | import subprocess 3 | import py 4 | from subprocess import Popen, PIPE 5 | 6 | def cmdexec(cmd): 7 | """ return unicode output of executing 'cmd' in a separate process. 8 | 9 | raise cmdexec.Error exeception if the command failed. 10 | the exception will provide an 'err' attribute containing 11 | the error-output from the command. 12 | if the subprocess module does not provide a proper encoding/unicode strings 13 | sys.getdefaultencoding() will be used, if that does not exist, 'UTF-8'. 14 | """ 15 | process = subprocess.Popen(cmd, shell=True, 16 | universal_newlines=True, 17 | stdout=subprocess.PIPE, stderr=subprocess.PIPE) 18 | out, err = process.communicate() 19 | if sys.version_info[0] < 3: # on py3 we get unicode strings, on py2 not 20 | try: 21 | default_encoding = sys.getdefaultencoding() # jython may not have it 22 | except AttributeError: 23 | default_encoding = sys.stdout.encoding or 'UTF-8' 24 | out = unicode(out, process.stdout.encoding or default_encoding) 25 | err = unicode(err, process.stderr.encoding or default_encoding) 26 | status = process.poll() 27 | if status: 28 | raise ExecutionFailed(status, status, cmd, out, err) 29 | return out 30 | 31 | class ExecutionFailed(py.error.Error): 32 | def __init__(self, status, systemstatus, cmd, out, err): 33 | Exception.__init__(self) 34 | self.status = status 35 | self.systemstatus = systemstatus 36 | self.cmd = cmd 37 | self.err = err 38 | self.out = out 39 | 40 | def __str__(self): 41 | return "ExecutionFailed: %d %s\n%s" %(self.status, self.cmd, self.err) 42 | 43 | # export the exception under the name 'py.process.cmdexec.Error' 44 | cmdexec.Error = ExecutionFailed 45 | try: 46 | ExecutionFailed.__module__ = 'py.process.cmdexec' 47 | ExecutionFailed.__name__ = 'Error' 48 | except (AttributeError, TypeError): 49 | pass 50 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/build/lib.linux-x86_64-2.7/py/_process/killproc.py: -------------------------------------------------------------------------------- 1 | import py 2 | import os, sys 3 | 4 | if sys.platform == "win32" or getattr(os, '_name', '') == 'nt': 5 | try: 6 | import ctypes 7 | except ImportError: 8 | def dokill(pid): 9 | py.process.cmdexec("taskkill /F /PID %d" %(pid,)) 10 | else: 11 | def dokill(pid): 12 | PROCESS_TERMINATE = 1 13 | handle = ctypes.windll.kernel32.OpenProcess( 14 | PROCESS_TERMINATE, False, pid) 15 | ctypes.windll.kernel32.TerminateProcess(handle, -1) 16 | ctypes.windll.kernel32.CloseHandle(handle) 17 | else: 18 | def dokill(pid): 19 | os.kill(pid, 15) 20 | 21 | def kill(pid): 22 | """ kill process by id. """ 23 | dokill(pid) 24 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/build/lib.linux-x86_64-2.7/py/_std.py: -------------------------------------------------------------------------------- 1 | import sys 2 | 3 | class Std(object): 4 | """ makes top-level python modules available as an attribute, 5 | importing them on first access. 6 | """ 7 | 8 | def __init__(self): 9 | self.__dict__ = sys.modules 10 | 11 | def __getattr__(self, name): 12 | try: 13 | m = __import__(name) 14 | except ImportError: 15 | raise AttributeError("py.std: could not import %s" % name) 16 | return m 17 | 18 | std = Std() 19 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/build/lib.linux-x86_64-2.7/py/test.py: -------------------------------------------------------------------------------- 1 | import sys 2 | if __name__ == '__main__': 3 | import pytest 4 | sys.exit(pytest.main()) 5 | else: 6 | import sys, pytest 7 | sys.modules['py.test'] = pytest 8 | 9 | # for more API entry points see the 'tests' definition 10 | # in __init__.py 11 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/dist/py-1.4.30-py2.7.egg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/py-1.4.30/dist/py-1.4.30-py2.7.egg -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/_templates/layout.html: -------------------------------------------------------------------------------- 1 | {% extends "!layout.html" %} 2 | 3 | {% block footer %} 4 | {{ super() }} 5 | 18 | {% endblock %} 19 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/announce/release-0.9.0.txt: -------------------------------------------------------------------------------- 1 | py lib 1.0.0: XXX 2 | ====================================================================== 3 | 4 | Welcome to the 1.0.0 py lib release - a library aiming to 5 | support agile and test-driven python development on various levels. 6 | 7 | XXX 8 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/announce/release-0.9.2.txt: -------------------------------------------------------------------------------- 1 | py lib 0.9.2: bugfix release 2 | ============================= 3 | 4 | Welcome to the 0.9.2 py lib and py.test release - 5 | mainly fixing Windows issues, providing better 6 | packaging and integration with setuptools. 7 | 8 | Here is a quick summary of what the py lib provides: 9 | 10 | * py.test: cross-project testing tool with many advanced features 11 | * py.execnet: ad-hoc code distribution to SSH, Socket and local sub processes 12 | * py.magic.greenlet: micro-threads on standard CPython ("stackless-light") 13 | * py.path: path abstractions over local and subversion files 14 | * rich documentation of py's exported API 15 | * tested against Linux, Win32, OSX, works on python 2.3-2.6 16 | 17 | See here for more information: 18 | 19 | Pypi pages: http://pypi.python.org/pypi/py/ 20 | 21 | Download/Install: http://codespeak.net/py/0.9.2/download.html 22 | 23 | Documentation/API: http://codespeak.net/py/0.9.2/index.html 24 | 25 | best and have fun, 26 | 27 | holger krekel 28 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/announce/release-1.0.1.txt: -------------------------------------------------------------------------------- 1 | 1.0.1: improved reporting, nose/unittest.py support, bug fixes 2 | ----------------------------------------------------------------------- 3 | 4 | This is a bugfix release of pylib/py.test also coming with: 5 | 6 | * improved documentation, improved navigation 7 | * test failure reporting improvements 8 | * support for directly running existing nose/unittest.py style tests 9 | 10 | visit here for more info, including quickstart and tutorials: 11 | 12 | http://pytest.org and http://pylib.org 13 | 14 | 15 | Changelog 1.0.0 to 1.0.1 16 | ------------------------ 17 | 18 | * added a default 'pytest_nose' plugin which handles nose.SkipTest, 19 | nose-style function/method/generator setup/teardown and 20 | tries to report functions correctly. 21 | 22 | * improved documentation, better navigation: see http://pytest.org 23 | 24 | * added a "--help-config" option to show conftest.py / ENV-var names for 25 | all longopt cmdline options, and some special conftest.py variables. 26 | renamed 'conf_capture' conftest setting to 'option_capture' accordingly. 27 | 28 | * unicode fixes: capturing and unicode writes to sys.stdout 29 | (through e.g a print statement) now work within tests, 30 | they are encoded as "utf8" by default, also terminalwriting 31 | was adapted and somewhat unified between windows and linux 32 | 33 | * fix issue #27: better reporting on non-collectable items given on commandline 34 | (e.g. pyc files) 35 | 36 | * fix issue #33: added --version flag (thanks Benjamin Peterson) 37 | 38 | * fix issue #32: adding support for "incomplete" paths to wcpath.status() 39 | 40 | * "Test" prefixed classes are *not* collected by default anymore if they 41 | have an __init__ method 42 | 43 | * monkeypatch setenv() now accepts a "prepend" parameter 44 | 45 | * improved reporting of collection error tracebacks 46 | 47 | * simplified multicall mechanism and plugin architecture, 48 | renamed some internal methods and argnames 49 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/announce/release-1.0.2.txt: -------------------------------------------------------------------------------- 1 | 1.0.2: packaging fixes 2 | ----------------------------------------------------------------------- 3 | 4 | this release is purely a release for fixing packaging issues. 5 | 6 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/announce/release-1.1.1.txt: -------------------------------------------------------------------------------- 1 | py.test/pylib 1.1.1: bugfix release, setuptools plugin registration 2 | -------------------------------------------------------------------------------- 3 | 4 | This is a compatibility fixing release of pylib/py.test to work 5 | better with previous 1.0.x test code bases. It also contains fixes 6 | and changes to work with `execnet>=1.0.0`_ to provide distributed 7 | testing and looponfailing testing modes. py-1.1.1 also introduces 8 | a new mechanism for registering plugins via setuptools. 9 | 10 | What is pylib/py.test? 11 | ----------------------- 12 | 13 | py.test is an advanced automated testing tool working with 14 | Python2, Python3 and Jython versions on all major operating 15 | systems. It has an extensive plugin architecture and can run many 16 | existing common Python test suites without modification. Moreover, 17 | it offers some unique features not found in other 18 | testing tools. See http://pytest.org for more info. 19 | 20 | The pylib also contains a localpath and svnpath implementation 21 | and some developer-oriented command line tools. See 22 | http://pylib.org for more info. 23 | 24 | thanks to all who helped and gave feedback, 25 | have fun, 26 | 27 | holger (http://twitter.com/hpk42) 28 | 29 | .. _`execnet>=1.0.0`: http://codespeak.net/execnet 30 | 31 | Changes between 1.1.1 and 1.1.0 32 | ===================================== 33 | 34 | - introduce automatic plugin registration via 'pytest11' 35 | entrypoints via setuptools' pkg_resources.iter_entry_points 36 | 37 | - fix py.test dist-testing to work with execnet >= 1.0.0b4 38 | 39 | - re-introduce py.test.cmdline.main() for better backward compatibility 40 | 41 | - svn paths: fix a bug with path.check(versioned=True) for svn paths, 42 | allow '%' in svn paths, make svnwc.update() default to interactive mode 43 | like in 1.0.x and add svnwc.update(interactive=False) to inhibit interaction. 44 | 45 | - refine distributed tarball to contain test and no pyc files 46 | 47 | - try harder to have deprecation warnings for py.compat.* accesses 48 | report a correct location 49 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/announce/release-1.3.3.txt: -------------------------------------------------------------------------------- 1 | py.test/pylib 1.3.3: windows and other fixes 2 | =========================================================================== 3 | 4 | pylib/py.test 1.3.3 is a minor bugfix release featuring some improvements 5 | and fixes. See changelog_ for full history. 6 | 7 | have fun, 8 | holger krekel 9 | 10 | .. _changelog: ../changelog.html 11 | 12 | Changes between 1.3.2 and 1.3.3 13 | ================================================== 14 | 15 | - fix issue113: assertion representation problem with triple-quoted strings 16 | (and possibly other cases) 17 | - make conftest loading detect that a conftest file with the same 18 | content was already loaded, avoids surprises in nested directory structures 19 | which can be produced e.g. by Hudson. It probably removes the need to use 20 | --confcutdir in most cases. 21 | - fix terminal coloring for win32 22 | (thanks Michael Foord for reporting) 23 | - fix weirdness: make terminal width detection work on stdout instead of stdin 24 | (thanks Armin Ronacher for reporting) 25 | - remove trailing whitespace in all py/text distribution files 26 | 27 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/announce/release-1.3.4.txt: -------------------------------------------------------------------------------- 1 | py.test/pylib 1.3.4: fixes and new native traceback option 2 | =========================================================================== 3 | 4 | pylib/py.test 1.3.4 is a minor maintenance release mostly containing bug fixes 5 | and a new "--tb=native" traceback option to show "normal" Python standard 6 | tracebacks instead of the py.test enhanced tracebacks. See below for more 7 | change info and http://pytest.org for more general information on features 8 | and configuration of the testing tool. 9 | 10 | Thanks to the issue reporters and generally to Ronny Pfannschmidt for help. 11 | 12 | cheers, 13 | holger krekel 14 | 15 | Changes between 1.3.3 and 1.3.4 16 | ================================================== 17 | 18 | - fix issue111: improve install documentation for windows 19 | - fix issue119: fix custom collectability of __init__.py as a module 20 | - fix issue116: --doctestmodules work with __init__.py files as well 21 | - fix issue115: unify internal exception passthrough/catching/GeneratorExit 22 | - fix issue118: new --tb=native for presenting cpython-standard exceptions 23 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/announce/release-1.4.0.txt: -------------------------------------------------------------------------------- 1 | 2 | .. _`release-1.4.0`: 3 | 4 | py-1.4.0: cross-python lib for path, code, io, ... manipulations 5 | =========================================================================== 6 | 7 | "py" is a small library comprising APIs for filesystem and svn path 8 | manipulations, dynamic code construction and introspection, a Py2/Py3 9 | compatibility namespace ("py.builtin"), IO capturing, terminal colored printing 10 | (on windows and linux), ini-file parsing and a lazy import mechanism. 11 | It runs unmodified on all Python interpreters compatible to Python2.4 up 12 | until Python 3.2. The general goal with "py" is to provide stable APIs 13 | for some common tasks that are continously tested against many Python 14 | interpreters and thus also to help transition. Here are some docs: 15 | 16 | http://pylib.org 17 | 18 | NOTE: The prior py-1.3.X versions contained "py.test" which now comes 19 | as its own separate "pytest" distribution and was just released 20 | as "pytest-2.0.0", see here for the revamped docs: 21 | 22 | http://pytest.org 23 | 24 | And "py.cleanup|py.lookup|py.countloc" etc. helpers are now part of 25 | the pycmd distribution, see http://pypi.python.org/pypi/pycmd 26 | 27 | This makes "py-1.4.0" a simple library which does not install 28 | any command line utilities anymore. 29 | 30 | cheers, 31 | holger 32 | 33 | Changes between 1.3.4 and 1.4.0 34 | ------------------------------------- 35 | 36 | - py.test was moved to a separate "pytest" package. What remains is 37 | a stub hook which will proxy ``import py.test`` to ``pytest``. 38 | - all command line tools ("py.cleanup/lookup/countloc/..." moved 39 | to "pycmd" package) 40 | - removed the old and deprecated "py.magic" namespace 41 | - use apipkg-1.1 and make py.apipkg.initpkg|ApiModule available 42 | - add py.iniconfig module for brain-dead easy ini-config file parsing 43 | - introduce py.builtin.any() 44 | - path objects have a .dirname attribute now (equivalent to 45 | os.path.dirname(path)) 46 | - path.visit() accepts breadthfirst (bf) and sort options 47 | - remove deprecated py.compat namespace 48 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/announce/release-1.4.1.txt: -------------------------------------------------------------------------------- 1 | 2 | .. _`release-1.4.1`: 3 | 4 | py-1.4.1: cross-python lib for fs path, code, io, ... manipulations 5 | =========================================================================== 6 | 7 | This is a bug fix release of the "py" lib, see below for detailed changes. 8 | The py lib is a small library comprising APIs for filesystem and svn path 9 | manipulations, dynamic code construction and introspection, a Py2/Py3 10 | compatibility namespace ("py.builtin"), IO capturing, terminal colored printing 11 | (on windows and linux), ini-file parsing and a lazy import mechanism. 12 | It runs unmodified on all Python interpreters compatible to Python2.4 up 13 | until Python 3.2, PyPy and Jython. The general goal with "py" is to 14 | provide stable APIs for some common tasks that are continously tested 15 | against many Python interpreters and thus also to help transition. Here 16 | are some docs: 17 | 18 | http://pylib.org 19 | 20 | NOTE: The prior py-1.3.X versions contained "py.test" which since py-1.4.0 21 | comes as its own separate "pytest" distribution, see: 22 | 23 | http://pytest.org 24 | 25 | Also, the "py.cleanup|py.lookup|py.countloc" helpers are now part of 26 | the pycmd distribution, see http://pypi.python.org/pypi/pycmd 27 | 28 | 29 | Changes between 1.4.0 and 1.4.1 30 | ================================================== 31 | 32 | - fix issue1 - py.error.* classes to be pickleable 33 | 34 | - fix issue2 - on windows32 use PATHEXT as the list of potential 35 | extensions to find find binaries with py.path.local.sysfind(commandname) 36 | 37 | - fix (pytest-) issue10 and refine assertion reinterpretation 38 | to avoid breaking if the __nonzero__ of an object fails 39 | 40 | - fix (pytest-) issue17 where python3 does not like star-imports, 41 | leading to misrepresentation of import-errors in test modules 42 | 43 | - fix ``py.error.*`` attribute pypy access 44 | 45 | - allow path.samefile(arg) to succeed when arg is a relative filename 46 | 47 | - fix (pytest-) issue20 path.samefile(relpath) works as expected now 48 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/announce/releases.txt: -------------------------------------------------------------------------------- 1 | ============= 2 | Release notes 3 | ============= 4 | 5 | Contents: 6 | 7 | .. toctree:: 8 | :maxdepth: 2 9 | 10 | .. include: release-1.1.0 11 | .. include: release-1.0.2 12 | 13 | release-1.0.1 14 | release-1.0.0 15 | release-0.9.2 16 | release-0.9.0 17 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/changelog.txt: -------------------------------------------------------------------------------- 1 | .. _`changelog`: 2 | 3 | .. include:: ../CHANGELOG 4 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/download.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 11 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/example/genhtml.py: -------------------------------------------------------------------------------- 1 | from py.xml import html 2 | 3 | paras = "First Para", "Second para" 4 | 5 | doc = html.html( 6 | html.head( 7 | html.meta(name="Content-Type", value="text/html; charset=latin1")), 8 | html.body( 9 | [html.p(p) for p in paras])) 10 | 11 | print unicode(doc).encode('latin1') 12 | 13 | 14 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/example/genhtmlcss.py: -------------------------------------------------------------------------------- 1 | import py 2 | html = py.xml.html 3 | 4 | class my(html): 5 | "a custom style" 6 | class body(html.body): 7 | style = html.Style(font_size = "120%") 8 | 9 | class h2(html.h2): 10 | style = html.Style(background = "grey") 11 | 12 | class p(html.p): 13 | style = html.Style(font_weight="bold") 14 | 15 | doc = my.html( 16 | my.head(), 17 | my.body( 18 | my.h2("hello world"), 19 | my.p("bold as bold can") 20 | ) 21 | ) 22 | 23 | print doc.unicode(indent=2) 24 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/example/genxml.py: -------------------------------------------------------------------------------- 1 | 2 | import py 3 | class ns(py.xml.Namespace): 4 | pass 5 | 6 | doc = ns.books( 7 | ns.book( 8 | ns.author("May Day"), 9 | ns.title("python for java programmers"),), 10 | ns.book( 11 | ns.author("why", class_="somecssclass"), 12 | ns.title("Java for Python programmers"),), 13 | publisher="N.N", 14 | ) 15 | print doc.unicode(indent=2).encode('utf8') 16 | 17 | 18 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/img/pylib.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/py-1.4.30/doc/img/pylib.png -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/index.txt: -------------------------------------------------------------------------------- 1 | .. py documentation master file, created by 2 | sphinx-quickstart on Thu Oct 21 08:30:10 2010. 3 | You can adapt this file completely to your liking, but it should at least 4 | contain the root `toctree` directive. 5 | 6 | Welcome to py's documentation! 7 | ================================= 8 | 9 | see :ref:`CHANGELOG ` for latest changes. 10 | 11 | .. note:: 12 | 13 | Since version 1.4, the testing tool "py.test" is part of its own `pytest distribution`_. 14 | 15 | .. _`pytest distribution`: http://pytest.org 16 | 17 | Contents: 18 | 19 | .. toctree:: 20 | 21 | install 22 | path 23 | code 24 | io 25 | log 26 | xml 27 | misc 28 | 29 | :maxdepth: 2 30 | 31 | .. toctree:: 32 | :hidden: 33 | 34 | announce/release-2.0.0 35 | changelog 36 | announce/* 37 | 38 | Indices and tables 39 | ================== 40 | 41 | * :ref:`genindex` 42 | * :ref:`search` 43 | 44 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/io.txt: -------------------------------------------------------------------------------- 1 | ======= 2 | py.io 3 | ======= 4 | 5 | 6 | The 'py' lib provides helper classes for capturing IO during 7 | execution of a program. 8 | 9 | IO Capturing examples 10 | =============================================== 11 | 12 | ``py.io.StdCapture`` 13 | --------------------------- 14 | 15 | Basic Example:: 16 | 17 | >>> import py 18 | >>> capture = py.io.StdCapture() 19 | >>> print "hello" 20 | >>> out,err = capture.reset() 21 | >>> out.strip() == "hello" 22 | True 23 | 24 | For calling functions you may use a shortcut:: 25 | 26 | >>> import py 27 | >>> def f(): print "hello" 28 | >>> res, out, err = py.io.StdCapture.call(f) 29 | >>> out.strip() == "hello" 30 | True 31 | 32 | ``py.io.StdCaptureFD`` 33 | --------------------------- 34 | 35 | If you also want to capture writes to the stdout/stderr 36 | filedescriptors you may invoke:: 37 | 38 | >>> import py, sys 39 | >>> capture = py.io.StdCaptureFD(out=False, in_=False) 40 | >>> sys.stderr.write("world") 41 | >>> out,err = capture.reset() 42 | >>> err 43 | 'world' 44 | 45 | py.io object reference 46 | ============================ 47 | 48 | .. autoclass:: py.io.StdCaptureFD 49 | :members: 50 | :inherited-members: 51 | 52 | .. autoclass:: py.io.StdCapture 53 | :members: 54 | :inherited-members: 55 | 56 | .. autoclass:: py.io.TerminalWriter 57 | :members: 58 | :inherited-members: 59 | 60 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/doc/links.inc: -------------------------------------------------------------------------------- 1 | 2 | .. _`skipping plugin`: plugin/skipping.html 3 | .. _`funcargs mechanism`: funcargs.html 4 | .. _`doctest.py`: http://docs.python.org/library/doctest.html 5 | .. _`xUnit style setup`: xunit_setup.html 6 | .. _`pytest_nose`: plugin/nose.html 7 | .. _`reStructured Text`: http://docutils.sourceforge.net 8 | .. _`Python debugger`: http://docs.python.org/lib/module-pdb.html 9 | .. _nose: http://somethingaboutorange.com/mrl/projects/nose/ 10 | .. _pytest: http://pypi.python.org/pypi/pytest 11 | .. _mercurial: http://mercurial.selenic.com/wiki/ 12 | .. _`setuptools`: http://pypi.python.org/pypi/setuptools 13 | .. _`distribute`: http://pypi.python.org/pypi/distribute 14 | .. _`pip`: http://pypi.python.org/pypi/pip 15 | .. _`virtualenv`: http://pypi.python.org/pypi/virtualenv 16 | .. _hudson: http://hudson-ci.org/ 17 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py.egg-info/PKG-INFO: -------------------------------------------------------------------------------- 1 | Metadata-Version: 1.1 2 | Name: py 3 | Version: 1.4.30 4 | Summary: library with cross-python path, ini-parsing, io, code, log facilities 5 | Home-page: http://pylib.readthedocs.org/ 6 | Author: holger krekel, Ronny Pfannschmidt, Benjamin Peterson and others 7 | Author-email: pytest-dev@python.org 8 | License: MIT license 9 | Description: .. image:: https://drone.io/bitbucket.org/pytest-dev/py/status.png 10 | :target: https://drone.io/bitbucket.org/pytest-dev/py/latest 11 | .. image:: https://pypip.in/v/py/badge.png 12 | :target: https://pypi.python.org/pypi/py 13 | 14 | The py lib is a Python development support library featuring 15 | the following tools and modules: 16 | 17 | * py.path: uniform local and svn path objects 18 | * py.apipkg: explicit API control and lazy-importing 19 | * py.iniconfig: easy parsing of .ini files 20 | * py.code: dynamic code generation and introspection 21 | 22 | NOTE: prior to the 1.4 release this distribution used to 23 | contain py.test which is now its own package, see http://pytest.org 24 | 25 | For questions and more information please visit http://pylib.readthedocs.org 26 | 27 | Bugs and issues: http://bitbucket.org/pytest-dev/py/issues/ 28 | 29 | Authors: Holger Krekel and others, 2004-2015 30 | 31 | Platform: unix 32 | Platform: linux 33 | Platform: osx 34 | Platform: cygwin 35 | Platform: win32 36 | Classifier: Development Status :: 6 - Mature 37 | Classifier: Intended Audience :: Developers 38 | Classifier: License :: OSI Approved :: MIT License 39 | Classifier: Operating System :: POSIX 40 | Classifier: Operating System :: Microsoft :: Windows 41 | Classifier: Operating System :: MacOS :: MacOS X 42 | Classifier: Topic :: Software Development :: Testing 43 | Classifier: Topic :: Software Development :: Libraries 44 | Classifier: Topic :: Utilities 45 | Classifier: Programming Language :: Python 46 | Classifier: Programming Language :: Python :: 3 47 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py.egg-info/dependency_links.txt: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py.egg-info/not-zip-safe: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py.egg-info/top_level.txt: -------------------------------------------------------------------------------- 1 | py 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/__init__.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/py-1.4.30/py/__init__.pyc -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/__metainfo.py: -------------------------------------------------------------------------------- 1 | import py 2 | pydir = py.path.local(py.__file__).dirpath() 3 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/_apipkg.pyc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/py-1.4.30/py/_apipkg.pyc -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/_code/__init__.py: -------------------------------------------------------------------------------- 1 | """ python inspection/code generation API """ 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/_io/__init__.py: -------------------------------------------------------------------------------- 1 | """ input/output helping """ 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/_log/__init__.py: -------------------------------------------------------------------------------- 1 | """ logging API ('producers' and 'consumers' connected via keywords) """ 2 | 3 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/_path/__init__.py: -------------------------------------------------------------------------------- 1 | """ unified file system api """ 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/_process/__init__.py: -------------------------------------------------------------------------------- 1 | """ high-level sub-process handling """ 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/_process/cmdexec.py: -------------------------------------------------------------------------------- 1 | import sys 2 | import subprocess 3 | import py 4 | from subprocess import Popen, PIPE 5 | 6 | def cmdexec(cmd): 7 | """ return unicode output of executing 'cmd' in a separate process. 8 | 9 | raise cmdexec.Error exeception if the command failed. 10 | the exception will provide an 'err' attribute containing 11 | the error-output from the command. 12 | if the subprocess module does not provide a proper encoding/unicode strings 13 | sys.getdefaultencoding() will be used, if that does not exist, 'UTF-8'. 14 | """ 15 | process = subprocess.Popen(cmd, shell=True, 16 | universal_newlines=True, 17 | stdout=subprocess.PIPE, stderr=subprocess.PIPE) 18 | out, err = process.communicate() 19 | if sys.version_info[0] < 3: # on py3 we get unicode strings, on py2 not 20 | try: 21 | default_encoding = sys.getdefaultencoding() # jython may not have it 22 | except AttributeError: 23 | default_encoding = sys.stdout.encoding or 'UTF-8' 24 | out = unicode(out, process.stdout.encoding or default_encoding) 25 | err = unicode(err, process.stderr.encoding or default_encoding) 26 | status = process.poll() 27 | if status: 28 | raise ExecutionFailed(status, status, cmd, out, err) 29 | return out 30 | 31 | class ExecutionFailed(py.error.Error): 32 | def __init__(self, status, systemstatus, cmd, out, err): 33 | Exception.__init__(self) 34 | self.status = status 35 | self.systemstatus = systemstatus 36 | self.cmd = cmd 37 | self.err = err 38 | self.out = out 39 | 40 | def __str__(self): 41 | return "ExecutionFailed: %d %s\n%s" %(self.status, self.cmd, self.err) 42 | 43 | # export the exception under the name 'py.process.cmdexec.Error' 44 | cmdexec.Error = ExecutionFailed 45 | try: 46 | ExecutionFailed.__module__ = 'py.process.cmdexec' 47 | ExecutionFailed.__name__ = 'Error' 48 | except (AttributeError, TypeError): 49 | pass 50 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/_process/killproc.py: -------------------------------------------------------------------------------- 1 | import py 2 | import os, sys 3 | 4 | if sys.platform == "win32" or getattr(os, '_name', '') == 'nt': 5 | try: 6 | import ctypes 7 | except ImportError: 8 | def dokill(pid): 9 | py.process.cmdexec("taskkill /F /PID %d" %(pid,)) 10 | else: 11 | def dokill(pid): 12 | PROCESS_TERMINATE = 1 13 | handle = ctypes.windll.kernel32.OpenProcess( 14 | PROCESS_TERMINATE, False, pid) 15 | ctypes.windll.kernel32.TerminateProcess(handle, -1) 16 | ctypes.windll.kernel32.CloseHandle(handle) 17 | else: 18 | def dokill(pid): 19 | os.kill(pid, 15) 20 | 21 | def kill(pid): 22 | """ kill process by id. """ 23 | dokill(pid) 24 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/_std.py: -------------------------------------------------------------------------------- 1 | import sys 2 | 3 | class Std(object): 4 | """ makes top-level python modules available as an attribute, 5 | importing them on first access. 6 | """ 7 | 8 | def __init__(self): 9 | self.__dict__ = sys.modules 10 | 11 | def __getattr__(self, name): 12 | try: 13 | m = __import__(name) 14 | except ImportError: 15 | raise AttributeError("py.std: could not import %s" % name) 16 | return m 17 | 18 | std = Std() 19 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/py/test.py: -------------------------------------------------------------------------------- 1 | import sys 2 | if __name__ == '__main__': 3 | import pytest 4 | sys.exit(pytest.main()) 5 | else: 6 | import sys, pytest 7 | sys.modules['py.test'] = pytest 8 | 9 | # for more API entry points see the 'tests' definition 10 | # in __init__.py 11 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/setup.cfg: -------------------------------------------------------------------------------- 1 | [wheel] 2 | universal = 1 3 | 4 | [egg_info] 5 | tag_build = 6 | tag_date = 0 7 | tag_svn_revision = 0 8 | 9 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/setup.py: -------------------------------------------------------------------------------- 1 | import os, sys 2 | 3 | from setuptools import setup 4 | 5 | def main(): 6 | setup( 7 | name='py', 8 | description='library with cross-python path, ini-parsing, io, code, log facilities', 9 | long_description = open('README.txt').read(), 10 | version='1.4.30', 11 | url='http://pylib.readthedocs.org/', 12 | license='MIT license', 13 | platforms=['unix', 'linux', 'osx', 'cygwin', 'win32'], 14 | author='holger krekel, Ronny Pfannschmidt, Benjamin Peterson and others', 15 | author_email='pytest-dev@python.org', 16 | classifiers=['Development Status :: 6 - Mature', 17 | 'Intended Audience :: Developers', 18 | 'License :: OSI Approved :: MIT License', 19 | 'Operating System :: POSIX', 20 | 'Operating System :: Microsoft :: Windows', 21 | 'Operating System :: MacOS :: MacOS X', 22 | 'Topic :: Software Development :: Testing', 23 | 'Topic :: Software Development :: Libraries', 24 | 'Topic :: Utilities', 25 | 'Programming Language :: Python', 26 | 'Programming Language :: Python :: 3'], 27 | packages=['py', 28 | 'py._code', 29 | 'py._io', 30 | 'py._log', 31 | 'py._path', 32 | 'py._process', 33 | ], 34 | zip_safe=False, 35 | ) 36 | 37 | if __name__ == '__main__': 38 | main() 39 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/conftest.py: -------------------------------------------------------------------------------- 1 | 2 | pytest_plugins = "pytester", 3 | 4 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/io_/__init__.py: -------------------------------------------------------------------------------- 1 | # 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/log/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/py-1.4.30/testing/log/__init__.py -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/log/test_warning.py: -------------------------------------------------------------------------------- 1 | import py 2 | mypath = py.path.local(__file__).new(ext=".py") 3 | 4 | def test_forwarding_to_warnings_module(): 5 | py.test.deprecated_call(py.log._apiwarn, "1.3", "..") 6 | 7 | def test_apiwarn_functional(recwarn): 8 | capture = py.io.StdCapture() 9 | py.log._apiwarn("x.y.z", "something", stacklevel=1) 10 | out, err = capture.reset() 11 | py.builtin.print_("out", out) 12 | py.builtin.print_("err", err) 13 | assert err.find("x.y.z") != -1 14 | lno = py.code.getrawcode(test_apiwarn_functional).co_firstlineno + 2 15 | exp = "%s:%s" % (mypath, lno) 16 | assert err.find(exp) != -1 17 | 18 | def test_stacklevel(recwarn): 19 | def f(): 20 | py.log._apiwarn("x", "some", stacklevel=2) 21 | # 3 22 | # 4 23 | capture = py.io.StdCapture() 24 | f() 25 | out, err = capture.reset() 26 | lno = py.code.getrawcode(test_stacklevel).co_firstlineno + 6 27 | warning = str(err) 28 | assert warning.find(":%s" % lno) != -1 29 | 30 | def test_stacklevel_initpkg_with_resolve(testdir, recwarn): 31 | testdir.makepyfile(modabc=""" 32 | import py 33 | def f(): 34 | py.log._apiwarn("x", "some", stacklevel="apipkg123") 35 | """) 36 | testdir.makepyfile(apipkg123=""" 37 | def __getattr__(): 38 | import modabc 39 | modabc.f() 40 | """) 41 | p = testdir.makepyfile(""" 42 | import apipkg123 43 | apipkg123.__getattr__() 44 | """) 45 | capture = py.io.StdCapture() 46 | p.pyimport() 47 | out, err = capture.reset() 48 | warning = str(err) 49 | loc = 'test_stacklevel_initpkg_with_resolve.py:2' 50 | assert warning.find(loc) != -1 51 | 52 | def test_stacklevel_initpkg_no_resolve(recwarn): 53 | def f(): 54 | py.log._apiwarn("x", "some", stacklevel="apipkg") 55 | capture = py.io.StdCapture() 56 | f() 57 | out, err = capture.reset() 58 | lno = py.code.getrawcode(test_stacklevel_initpkg_no_resolve).co_firstlineno + 2 59 | warning = str(err) 60 | assert warning.find(":%s" % lno) != -1 61 | 62 | 63 | def test_function(recwarn): 64 | capture = py.io.StdCapture() 65 | py.log._apiwarn("x.y.z", "something", function=test_function) 66 | out, err = capture.reset() 67 | py.builtin.print_("out", out) 68 | py.builtin.print_("err", err) 69 | assert err.find("x.y.z") != -1 70 | lno = py.code.getrawcode(test_function).co_firstlineno 71 | exp = "%s:%s" % (mypath, lno) 72 | assert err.find(exp) != -1 73 | 74 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/path/svntestbase.py: -------------------------------------------------------------------------------- 1 | import sys 2 | import py 3 | from py._path import svnwc as svncommon 4 | from common import CommonFSTests 5 | 6 | class CommonSvnTests(CommonFSTests): 7 | 8 | def test_propget(self, path1): 9 | url = path1.join("samplefile") 10 | value = url.propget('svn:eol-style') 11 | assert value == 'native' 12 | 13 | def test_proplist(self, path1): 14 | url = path1.join("samplefile") 15 | res = url.proplist() 16 | assert res['svn:eol-style'] == 'native' 17 | 18 | def test_info(self, path1): 19 | url = path1.join("samplefile") 20 | res = url.info() 21 | assert res.size > len("samplefile") and res.created_rev >= 0 22 | 23 | def test_log_simple(self, path1): 24 | url = path1.join("samplefile") 25 | logentries = url.log() 26 | for logentry in logentries: 27 | assert logentry.rev == 1 28 | assert hasattr(logentry, 'author') 29 | assert hasattr(logentry, 'date') 30 | 31 | #cache.repositories.put(svnrepourl, 1200, 0) 32 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/process/__init__.py: -------------------------------------------------------------------------------- 1 | # 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/process/test_cmdexec.py: -------------------------------------------------------------------------------- 1 | import py 2 | from py.process import cmdexec 3 | 4 | def exvalue(): 5 | return py.std.sys.exc_info()[1] 6 | 7 | class Test_exec_cmd: 8 | def test_simple(self): 9 | out = cmdexec('echo hallo') 10 | assert out.strip() == 'hallo' 11 | assert py.builtin._istext(out) 12 | 13 | def test_simple_newline(self): 14 | import sys 15 | out = cmdexec(r"""%s -c "print ('hello')" """ % sys.executable) 16 | assert out == 'hello\n' 17 | assert py.builtin._istext(out) 18 | 19 | def test_simple_error(self): 20 | py.test.raises (cmdexec.Error, cmdexec, 'exit 1') 21 | 22 | def test_simple_error_exact_status(self): 23 | try: 24 | cmdexec('exit 1') 25 | except cmdexec.Error: 26 | e = exvalue() 27 | assert e.status == 1 28 | assert py.builtin._istext(e.out) 29 | assert py.builtin._istext(e.err) 30 | 31 | def test_err(self): 32 | try: 33 | cmdexec('echoqweqwe123 hallo') 34 | raise AssertionError("command succeeded but shouldn't") 35 | except cmdexec.Error: 36 | e = exvalue() 37 | assert hasattr(e, 'err') 38 | assert hasattr(e, 'out') 39 | assert e.err or e.out 40 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/process/test_killproc.py: -------------------------------------------------------------------------------- 1 | 2 | import py, sys 3 | 4 | @py.test.mark.skipif("sys.platform.startswith('java')") 5 | def test_kill(tmpdir): 6 | subprocess = py.test.importorskip("subprocess") 7 | t = tmpdir.join("t.py") 8 | t.write("import time ; time.sleep(100)") 9 | proc = py.std.subprocess.Popen([sys.executable, str(t)]) 10 | assert proc.poll() is None # no return value yet 11 | py.process.kill(proc.pid) 12 | ret = proc.wait() 13 | if sys.platform == "win32" and ret == 0: 14 | py.test.skip("XXX on win32, subprocess.Popen().wait() on a killed " 15 | "process does not yield return value != 0") 16 | assert ret != 0 17 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/root/__init__.py: -------------------------------------------------------------------------------- 1 | # 2 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/root/test_error.py: -------------------------------------------------------------------------------- 1 | 2 | import py 3 | 4 | import errno 5 | 6 | def test_error_classes(): 7 | for name in errno.errorcode.values(): 8 | x = getattr(py.error, name) 9 | assert issubclass(x, py.error.Error) 10 | assert issubclass(x, EnvironmentError) 11 | 12 | def test_picklability_issue1(): 13 | e1 = py.error.ENOENT() 14 | s = py.std.pickle.dumps(e1) 15 | e2 = py.std.pickle.loads(s) 16 | assert isinstance(e2, py.error.ENOENT) 17 | 18 | def test_unknown_error(): 19 | num = 3999 20 | cls = py.error._geterrnoclass(num) 21 | assert cls.__name__ == 'UnknownErrno%d' % (num,) 22 | assert issubclass(cls, py.error.Error) 23 | assert issubclass(cls, EnvironmentError) 24 | cls2 = py.error._geterrnoclass(num) 25 | assert cls is cls2 26 | 27 | def test_error_conversion_ENOTDIR(testdir): 28 | p = testdir.makepyfile("") 29 | excinfo = py.test.raises(py.error.Error, py.error.checked_call, p.listdir) 30 | assert isinstance(excinfo.value, EnvironmentError) 31 | assert isinstance(excinfo.value, py.error.Error) 32 | assert "ENOTDIR" in repr(excinfo.value) 33 | 34 | 35 | def test_checked_call_supports_kwargs(tmpdir): 36 | import tempfile 37 | py.error.checked_call(tempfile.mkdtemp, dir=str(tmpdir)) 38 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/root/test_py_imports.py: -------------------------------------------------------------------------------- 1 | import py 2 | import types 3 | import sys 4 | 5 | def checksubpackage(name): 6 | obj = getattr(py, name) 7 | if hasattr(obj, '__map__'): # isinstance(obj, Module): 8 | keys = dir(obj) 9 | assert len(keys) > 0 10 | print (obj.__map__) 11 | for name in list(obj.__map__): 12 | assert hasattr(obj, name), (obj, name) 13 | 14 | def test_dir(): 15 | for name in dir(py): 16 | if not name.startswith('_'): 17 | yield checksubpackage, name 18 | 19 | def test_virtual_module_identity(): 20 | from py import path as path1 21 | from py import path as path2 22 | assert path1 is path2 23 | from py.path import local as local1 24 | from py.path import local as local2 25 | assert local1 is local2 26 | 27 | def test_importall(): 28 | base = py._pydir 29 | nodirs = [ 30 | ] 31 | if sys.version_info >= (3,0): 32 | nodirs.append(base.join('_code', '_assertionold.py')) 33 | else: 34 | nodirs.append(base.join('_code', '_assertionnew.py')) 35 | 36 | def recurse(p): 37 | return p.check(dotfile=0) and p.basename != "attic" 38 | 39 | for p in base.visit('*.py', recurse): 40 | if p.basename == '__init__.py': 41 | continue 42 | relpath = p.new(ext='').relto(base) 43 | if base.sep in relpath: # not py/*.py itself 44 | for x in nodirs: 45 | if p == x or p.relto(x): 46 | break 47 | else: 48 | relpath = relpath.replace(base.sep, '.') 49 | modpath = 'py.%s' % relpath 50 | try: 51 | check_import(modpath) 52 | except py.test.skip.Exception: 53 | pass 54 | 55 | def check_import(modpath): 56 | py.builtin.print_("checking import", modpath) 57 | assert __import__(modpath) 58 | 59 | def test_all_resolves(): 60 | seen = py.builtin.set([py]) 61 | lastlength = None 62 | while len(seen) != lastlength: 63 | lastlength = len(seen) 64 | for item in py.builtin.frozenset(seen): 65 | for value in item.__dict__.values(): 66 | if isinstance(value, type(py.test)): 67 | seen.add(value) 68 | 69 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/testing/root/test_std.py: -------------------------------------------------------------------------------- 1 | 2 | import py 3 | 4 | def test_os(): 5 | import os 6 | assert py.std.os is os 7 | 8 | def test_import_error_converts_to_attributeerror(): 9 | py.test.raises(AttributeError, "py.std.xyzalskdj") 10 | 11 | def test_std_gets_it(): 12 | for x in py.std.sys.modules: 13 | assert x in py.std.__dict__ 14 | -------------------------------------------------------------------------------- /dependencies/py-1.4.30/tox.ini: -------------------------------------------------------------------------------- 1 | [tox] 2 | envlist=py26,py27,py33,py34,external 3 | # py27-xdist causes problems with svn, py25 requires virtualenv==1.9.1 4 | #indexserver= 5 | # default=http://pypi.testrun.org 6 | 7 | [testenv] 8 | changedir=testing 9 | commands=py.test --confcutdir=.. -rfsxX --junitxml={envlogdir}/junit-{envname}.xml [] 10 | deps=pytest 11 | 12 | [testenv:py27-xdist] 13 | basepython=python2.7 14 | deps= 15 | pytest 16 | pytest-xdist 17 | commands= 18 | py.test -n3 -rfsxX --confcutdir=.. --runslowtests \ 19 | --junitxml={envlogdir}/junit-{envname}.xml [] 20 | 21 | [testenv:jython] 22 | changedir=testing 23 | commands= 24 | {envpython} -m pytest --confcutdir=.. -rfsxX --junitxml={envlogdir}/junit-{envname}0.xml {posargs:io_ code} 25 | 26 | [testenv:py25] 27 | setenv = PIP_INSECURE=1 28 | 29 | [testenv:external] 30 | deps= 31 | pytest 32 | jinja2 33 | decorator 34 | commands= 35 | py.test --confcutdir=.. -rfsxX --junitxml={envlogdir}/junit-{envname}.xml {posargs:code} 36 | 37 | [pytest] 38 | rsyncdirs = conftest.py py doc testing 39 | addopts = -rxXf 40 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/.coveragerc: -------------------------------------------------------------------------------- 1 | [run] 2 | omit = 3 | # standlonetemplate is read dynamically and tested by test_genscript 4 | *standalonetemplate.py 5 | # oldinterpret could be removed, as it is no longer used in py26+ 6 | *oldinterpret.py 7 | vendored_packages 8 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/.gitattributes: -------------------------------------------------------------------------------- 1 | CHANGELOG merge=union 2 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/.gitignore: -------------------------------------------------------------------------------- 1 | # Automatically generated by `hgimportsvn` 2 | .svn 3 | .hgsvn 4 | 5 | # Ignore local virtualenvs 6 | lib/ 7 | bin/ 8 | include/ 9 | .Python/ 10 | 11 | # These lines are suggested according to the svn:ignore property 12 | # Feel free to enable them by uncommenting them 13 | *.pyc 14 | *.pyo 15 | *.swp 16 | *.class 17 | *.orig 18 | *~ 19 | 20 | .eggs/ 21 | 22 | doc/*/_build 23 | build/ 24 | dist/ 25 | *.egg-info 26 | issue/ 27 | env/ 28 | .env/ 29 | 3rdparty/ 30 | .tox 31 | .cache 32 | .coverage 33 | .ropeproject 34 | .idea 35 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/.travis.yml: -------------------------------------------------------------------------------- 1 | sudo: false 2 | language: python 3 | python: 4 | - '3.5' 5 | # command to install dependencies 6 | install: "pip install -U tox" 7 | # # command to run tests 8 | env: 9 | matrix: 10 | - TESTENV=coveralls 11 | - TESTENV=doctesting 12 | - TESTENV=flakes 13 | - TESTENV=py26 14 | - TESTENV=py27 15 | - TESTENV=py27-cxfreeze 16 | - TESTENV=py27-nobyte 17 | - TESTENV=py27-pexpect 18 | - TESTENV=py27-subprocess 19 | - TESTENV=py27-trial 20 | - TESTENV=py27-xdist 21 | - TESTENV=py33 22 | - TESTENV=py33 23 | - TESTENV=py34 24 | - TESTENV=py35-pexpect 25 | - TESTENV=py35-trial 26 | - TESTENV=py35-xdist 27 | - TESTENV=py35 28 | - TESTENV=pypy 29 | 30 | script: tox --recreate -e $TESTENV 31 | 32 | notifications: 33 | irc: 34 | channels: 35 | - "chat.freenode.net#pytest" 36 | on_success: change 37 | on_failure: change 38 | skip_join: true 39 | email: 40 | - pytest-commit@python.org 41 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/AUTHORS: -------------------------------------------------------------------------------- 1 | Holger Krekel, holger at merlinux eu 2 | merlinux GmbH, Germany, office at merlinux eu 3 | 4 | Contributors include:: 5 | 6 | Abhijeet Kasurde 7 | Anatoly Bubenkoff 8 | Andreas Zeidler 9 | Andy Freeland 10 | Anthon van der Neut 11 | Armin Rigo 12 | Aron Curzon 13 | Benjamin Peterson 14 | Bob Ippolito 15 | Brian Dorsey 16 | Brian Okken 17 | Brianna Laugher 18 | Bruno Oliveira 19 | Carl Friedrich Bolz 20 | Charles Cloud 21 | Chris Lamb 22 | Christian Theunert 23 | Christian Tismer 24 | Christopher Gilling 25 | Daniel Grana 26 | Daniel Nuri 27 | Dave Hunt 28 | David Mohr 29 | Edison Gustavo Muenz 30 | Eduardo Schettino 31 | Elizaveta Shashkova 32 | Eric Hunsberger 33 | Eric Siegerman 34 | Florian Bruhin 35 | Floris Bruynooghe 36 | Graham Horler 37 | Grig Gheorghiu 38 | Guido Wesdorp 39 | Harald Armin Massa 40 | Ian Bicking 41 | Jaap Broekhuizen 42 | Jan Balster 43 | Janne Vanhala 44 | Jason R. Coombs 45 | Jurko Gospodnetić 46 | Katarzyna Jachim 47 | Kevin Cox 48 | Maciek Fijalkowski 49 | Maho 50 | Marc Schlaich 51 | Mark Abramowitz 52 | Markus Unterwaditzer 53 | Martijn Faassen 54 | Michael Droettboom 55 | Nicolas Delaby 56 | Pieter Mulder 57 | Piotr Banaszkiewicz 58 | Punyashloka Biswal 59 | Ralf Schmitt 60 | Ronny Pfannschmidt 61 | Ross Lawley 62 | Samuele Pedroni 63 | Tom Viner 64 | Trevor Bekolay 65 | Wouter van Ackooy 66 | David Díaz-Barquero 67 | Eric Hunsberger 68 | Simon Gomizelj 69 | Russel Winder 70 | Ben Webb 71 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/LICENSE: -------------------------------------------------------------------------------- 1 | 2 | Permission is hereby granted, free of charge, to any person obtaining a copy 3 | of this software and associated documentation files (the "Software"), to deal 4 | in the Software without restriction, including without limitation the rights 5 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 6 | copies of the Software, and to permit persons to whom the Software is 7 | furnished to do so, subject to the following conditions: 8 | 9 | The above copyright notice and this permission notice shall be included in all 10 | copies or substantial portions of the Software. 11 | 12 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 14 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 15 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 16 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 17 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 18 | SOFTWARE. 19 | 20 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/MANIFEST.in: -------------------------------------------------------------------------------- 1 | include CHANGELOG 2 | include README.rst 3 | include setup.py 4 | include tox.ini 5 | include LICENSE 6 | graft doc 7 | graft testing 8 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/README.rst: -------------------------------------------------------------------------------- 1 | ====== 2 | pytest 3 | ====== 4 | 5 | The ``pytest`` testing tool makes it easy to write small tests, yet 6 | scales to support complex functional testing. 7 | 8 | .. image:: http://img.shields.io/pypi/v/pytest.svg 9 | :target: https://pypi.python.org/pypi/pytest 10 | .. image:: http://img.shields.io/coveralls/pytest-dev/pytest/master.svg 11 | :target: https://coveralls.io/r/pytest-dev/pytest 12 | .. image:: https://travis-ci.org/pytest-dev/pytest.svg?branch=master 13 | :target: https://travis-ci.org/pytest-dev/pytest 14 | .. image:: https://ci.appveyor.com/api/projects/status/mrgbjaua7t33pg6b?svg=true 15 | :target: https://ci.appveyor.com/project/pytestbot/pytest 16 | 17 | Documentation: http://pytest.org/latest/ 18 | 19 | Changelog: http://pytest.org/latest/changelog.html 20 | 21 | Issues: https://github.com/pytest-dev/pytest/issues 22 | 23 | Features 24 | -------- 25 | 26 | - `auto-discovery 27 | `_ 28 | of test modules and functions, 29 | - detailed info on failing `assert statements `_ (no need to remember ``self.assert*`` names) 30 | - `modular fixtures `_ for 31 | managing small or parametrized long-lived test resources. 32 | - multi-paradigm support: you can use ``pytest`` to run test suites based 33 | on `unittest `_ (or trial), 34 | `nose `_ 35 | - single-source compatibility from Python2.6 all the way up to 36 | Python3.5, PyPy-2.3, (jython-2.5 untested) 37 | 38 | 39 | - many `external plugins `_. 40 | 41 | A simple example for a test: 42 | 43 | .. code-block:: python 44 | 45 | # content of test_module.py 46 | def test_function(): 47 | i = 4 48 | assert i == 3 49 | 50 | which can be run with ``py.test test_module.py``. See `getting-started `_ for more examples. 51 | 52 | For much more info, including PDF docs, see 53 | 54 | http://pytest.org 55 | 56 | and report bugs at: 57 | 58 | https://github.com/pytest-dev/pytest/issues 59 | 60 | and checkout or fork repo at: 61 | 62 | https://github.com/pytest-dev/pytest 63 | 64 | 65 | Copyright Holger Krekel and others, 2004-2015 66 | Licensed under the MIT license. 67 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/__init__.py: -------------------------------------------------------------------------------- 1 | # 2 | __version__ = '2.8.1' 3 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/_pluggy.py: -------------------------------------------------------------------------------- 1 | """ 2 | imports symbols from vendored "pluggy" if available, otherwise 3 | falls back to importing "pluggy" from the default namespace. 4 | """ 5 | 6 | try: 7 | from _pytest.vendored_packages.pluggy import * # noqa 8 | from _pytest.vendored_packages.pluggy import __version__ # noqa 9 | except ImportError: 10 | from pluggy import * # noqa 11 | from pluggy import __version__ # noqa 12 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/assertion/reinterpret.py: -------------------------------------------------------------------------------- 1 | import sys 2 | import py 3 | from _pytest.assertion.util import BuiltinAssertionError 4 | u = py.builtin._totext 5 | 6 | 7 | class AssertionError(BuiltinAssertionError): 8 | def __init__(self, *args): 9 | BuiltinAssertionError.__init__(self, *args) 10 | if args: 11 | # on Python2.6 we get len(args)==2 for: assert 0, (x,y) 12 | # on Python2.7 and above we always get len(args) == 1 13 | # with args[0] being the (x,y) tuple. 14 | if len(args) > 1: 15 | toprint = args 16 | else: 17 | toprint = args[0] 18 | try: 19 | self.msg = u(toprint) 20 | except Exception: 21 | self.msg = u( 22 | "<[broken __repr__] %s at %0xd>" 23 | % (toprint.__class__, id(toprint))) 24 | else: 25 | f = py.code.Frame(sys._getframe(1)) 26 | try: 27 | source = f.code.fullsource 28 | if source is not None: 29 | try: 30 | source = source.getstatement(f.lineno, assertion=True) 31 | except IndexError: 32 | source = None 33 | else: 34 | source = str(source.deindent()).strip() 35 | except py.error.ENOENT: 36 | source = None 37 | # this can also occur during reinterpretation, when the 38 | # co_filename is set to "". 39 | if source: 40 | self.msg = reinterpret(source, f, should_fail=True) 41 | else: 42 | self.msg = "" 43 | if not self.args: 44 | self.args = (self.msg,) 45 | 46 | if sys.version_info > (3, 0): 47 | AssertionError.__module__ = "builtins" 48 | 49 | if sys.version_info >= (2, 6) or sys.platform.startswith("java"): 50 | from _pytest.assertion.newinterpret import interpret as reinterpret 51 | else: 52 | from _pytest.assertion.oldinterpret import interpret as reinterpret 53 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/vendored_packages/README.md: -------------------------------------------------------------------------------- 1 | This directory vendors the `pluggy` module. 2 | 3 | For a more detailed discussion for the reasons to vendoring this 4 | package, please see [this issue](https://github.com/pytest-dev/pytest/issues/944). 5 | 6 | To update the current version, execute: 7 | 8 | ``` 9 | $ pip install -U pluggy== --no-compile --target=_pytest/vendored_packages 10 | ``` 11 | 12 | And commit the modified files. The `pluggy-.dist-info` directory 13 | created by `pip` should be ignored. 14 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/vendored_packages/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/_pytest/vendored_packages/__init__.py -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/vendored_packages/pluggy-0.3.1.dist-info/DESCRIPTION.rst: -------------------------------------------------------------------------------- 1 | Plugin registration and hook calling for Python 2 | =============================================== 3 | 4 | This is the plugin manager as used by pytest but stripped 5 | of pytest specific details. 6 | 7 | During the 0.x series this plugin does not have much documentation 8 | except extensive docstrings in the pluggy.py module. 9 | 10 | 11 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/vendored_packages/pluggy-0.3.1.dist-info/METADATA: -------------------------------------------------------------------------------- 1 | Metadata-Version: 2.0 2 | Name: pluggy 3 | Version: 0.3.1 4 | Summary: plugin and hook calling mechanisms for python 5 | Home-page: UNKNOWN 6 | Author: Holger Krekel 7 | Author-email: holger at merlinux.eu 8 | License: MIT license 9 | Platform: unix 10 | Platform: linux 11 | Platform: osx 12 | Platform: win32 13 | Classifier: Development Status :: 4 - Beta 14 | Classifier: Intended Audience :: Developers 15 | Classifier: License :: OSI Approved :: MIT License 16 | Classifier: Operating System :: POSIX 17 | Classifier: Operating System :: Microsoft :: Windows 18 | Classifier: Operating System :: MacOS :: MacOS X 19 | Classifier: Topic :: Software Development :: Testing 20 | Classifier: Topic :: Software Development :: Libraries 21 | Classifier: Topic :: Utilities 22 | Classifier: Programming Language :: Python :: 2 23 | Classifier: Programming Language :: Python :: 2.6 24 | Classifier: Programming Language :: Python :: 2.7 25 | Classifier: Programming Language :: Python :: 3 26 | Classifier: Programming Language :: Python :: 3.3 27 | Classifier: Programming Language :: Python :: 3.4 28 | Classifier: Programming Language :: Python :: 3.5 29 | 30 | Plugin registration and hook calling for Python 31 | =============================================== 32 | 33 | This is the plugin manager as used by pytest but stripped 34 | of pytest specific details. 35 | 36 | During the 0.x series this plugin does not have much documentation 37 | except extensive docstrings in the pluggy.py module. 38 | 39 | 40 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/vendored_packages/pluggy-0.3.1.dist-info/RECORD: -------------------------------------------------------------------------------- 1 | pluggy.py,sha256=v_RfWzyW6DPU1cJu_EFoL_OHq3t13qloVdR6UaMCXQA,29862 2 | pluggy-0.3.1.dist-info/top_level.txt,sha256=xKSCRhai-v9MckvMuWqNz16c1tbsmOggoMSwTgcpYHE,7 3 | pluggy-0.3.1.dist-info/pbr.json,sha256=xX3s6__wOcAyF-AZJX1sdZyW6PUXT-FkfBlM69EEUCg,47 4 | pluggy-0.3.1.dist-info/RECORD,, 5 | pluggy-0.3.1.dist-info/metadata.json,sha256=nLKltOT78dMV-00uXD6Aeemp4xNsz2q59j6ORSDeLjw,1027 6 | pluggy-0.3.1.dist-info/METADATA,sha256=1b85Ho2u4iK30M099k7axMzcDDhLcIMb-A82JUJZnSo,1334 7 | pluggy-0.3.1.dist-info/WHEEL,sha256=AvR0WeTpDaxT645bl5FQxUK6NPsTls2ttpcGJg3j1Xg,110 8 | pluggy-0.3.1.dist-info/DESCRIPTION.rst,sha256=P5Akh1EdIBR6CeqtV2P8ZwpGSpZiTKPw0NyS7jEiD-g,306 9 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/vendored_packages/pluggy-0.3.1.dist-info/WHEEL: -------------------------------------------------------------------------------- 1 | Wheel-Version: 1.0 2 | Generator: bdist_wheel (0.24.0) 3 | Root-Is-Purelib: true 4 | Tag: py2-none-any 5 | Tag: py3-none-any 6 | 7 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/vendored_packages/pluggy-0.3.1.dist-info/metadata.json: -------------------------------------------------------------------------------- 1 | {"license": "MIT license", "name": "pluggy", "metadata_version": "2.0", "generator": "bdist_wheel (0.24.0)", "summary": "plugin and hook calling mechanisms for python", "platform": "unix", "version": "0.3.1", "extensions": {"python.details": {"document_names": {"description": "DESCRIPTION.rst"}, "contacts": [{"role": "author", "email": "holger at merlinux.eu", "name": "Holger Krekel"}]}}, "classifiers": ["Development Status :: 4 - Beta", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: POSIX", "Operating System :: Microsoft :: Windows", "Operating System :: MacOS :: MacOS X", "Topic :: Software Development :: Testing", "Topic :: Software Development :: Libraries", "Topic :: Utilities", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.6", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5"]} -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/vendored_packages/pluggy-0.3.1.dist-info/pbr.json: -------------------------------------------------------------------------------- 1 | {"is_release": false, "git_version": "7d4c9cd"} -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/_pytest/vendored_packages/pluggy-0.3.1.dist-info/top_level.txt: -------------------------------------------------------------------------------- 1 | pluggy 2 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/bench/bench.py: -------------------------------------------------------------------------------- 1 | import sys 2 | 3 | if __name__ == '__main__': 4 | import cProfile 5 | import pytest 6 | import pstats 7 | script = sys.argv[1:] if len(sys.argv) > 1 else "empty.py" 8 | stats = cProfile.run('pytest.cmdline.main(%r)' % script, 'prof') 9 | p = pstats.Stats("prof") 10 | p.strip_dirs() 11 | p.sort_stats('cumulative') 12 | print(p.print_stats(500)) 13 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/bench/bench_argcomplete.py: -------------------------------------------------------------------------------- 1 | 2 | 3 | # 10000 iterations, just for relative comparison 4 | # 2.7.5 3.3.2 5 | # FilesCompleter 75.1109 69.2116 6 | # FastFilesCompleter 0.7383 1.0760 7 | 8 | 9 | if __name__ == '__main__': 10 | import sys 11 | import timeit 12 | from argcomplete.completers import FilesCompleter 13 | from _pytest._argcomplete import FastFilesCompleter 14 | count = 1000 # only a few seconds 15 | setup = 'from __main__ import FastFilesCompleter\nfc = FastFilesCompleter()' 16 | run = 'fc("/d")' 17 | sys.stdout.write('%s\n' % (timeit.timeit(run, 18 | setup=setup.replace('Fast', ''), number=count))) 19 | sys.stdout.write('%s\n' % (timeit.timeit(run, setup=setup, number=count))) 20 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/bench/empty.py: -------------------------------------------------------------------------------- 1 | import py 2 | for i in range(1000): 3 | py.builtin.exec_("def test_func_%d(): pass" % i) 4 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/bench/manyparam.py: -------------------------------------------------------------------------------- 1 | 2 | import pytest 3 | 4 | @pytest.fixture(scope='module', params=range(966)) 5 | def foo(request): 6 | return request.param 7 | 8 | def test_it(foo): 9 | pass 10 | def test_it2(foo): 11 | pass 12 | 13 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/bench/skip.py: -------------------------------------------------------------------------------- 1 | 2 | import pytest 3 | 4 | 5 | SKIP = True 6 | 7 | @pytest.mark.parametrize("x", xrange(5000)) 8 | def test_foo(x): 9 | if SKIP: 10 | pytest.skip("heh") 11 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_getdoctarget.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | 3 | import py 4 | 5 | def get_version_string(): 6 | fn = py.path.local(__file__).join("..", "..", "..", 7 | "_pytest", "__init__.py") 8 | for line in fn.readlines(): 9 | if "version" in line and not line.strip().startswith('#'): 10 | return eval(line.split("=")[-1]) 11 | 12 | def get_minor_version_string(): 13 | return ".".join(get_version_string().split(".")[:2]) 14 | 15 | if __name__ == "__main__": 16 | print (get_minor_version_string()) 17 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_templates/globaltoc.html: -------------------------------------------------------------------------------- 1 |

{{ _('Table Of Contents') }}

2 | 3 | 13 | 14 | {%- if display_toc %} 15 |
16 | {{ toc }} 17 | {%- endif %} 18 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_templates/layout.html: -------------------------------------------------------------------------------- 1 | {% extends "!layout.html" %} 2 | 3 | {% block footer %} 4 | {{ super() }} 5 | 18 | {% endblock %} 19 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_templates/links.html: -------------------------------------------------------------------------------- 1 |

Useful Links

2 | 11 | 12 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_templates/sidebarintro.html: -------------------------------------------------------------------------------- 1 |

About pytest

2 |

3 | pytest is a mature full-featured Python testing tool that helps 4 | you write better programs. 5 |

6 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_themes/.gitignore: -------------------------------------------------------------------------------- 1 | *.pyc 2 | *.pyo 3 | .DS_Store 4 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_themes/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2010 by Armin Ronacher. 2 | 3 | Some rights reserved. 4 | 5 | Redistribution and use in source and binary forms of the theme, with or 6 | without modification, are permitted provided that the following conditions 7 | are met: 8 | 9 | * Redistributions of source code must retain the above copyright 10 | notice, this list of conditions and the following disclaimer. 11 | 12 | * Redistributions in binary form must reproduce the above 13 | copyright notice, this list of conditions and the following 14 | disclaimer in the documentation and/or other materials provided 15 | with the distribution. 16 | 17 | * The names of the contributors may not be used to endorse or 18 | promote products derived from this software without specific 19 | prior written permission. 20 | 21 | We kindly ask you to only use these themes in an unmodified manner just 22 | for Flask and Flask-related products, not for unrelated projects. If you 23 | like the visual style and want to use it for your own projects, please 24 | consider making some larger changes to the themes (such as changing 25 | font faces, sizes, colors or margins). 26 | 27 | THIS THEME IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 28 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 29 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 30 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE 31 | LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 32 | CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 33 | SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 34 | INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 35 | CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 36 | ARISING IN ANY WAY OUT OF THE USE OF THIS THEME, EVEN IF ADVISED OF THE 37 | POSSIBILITY OF SUCH DAMAGE. 38 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_themes/README: -------------------------------------------------------------------------------- 1 | Flask Sphinx Styles 2 | =================== 3 | 4 | This repository contains sphinx styles for Flask and Flask related 5 | projects. To use this style in your Sphinx documentation, follow 6 | this guide: 7 | 8 | 1. put this folder as _themes into your docs folder. Alternatively 9 | you can also use git submodules to check out the contents there. 10 | 2. add this to your conf.py: 11 | 12 | sys.path.append(os.path.abspath('_themes')) 13 | html_theme_path = ['_themes'] 14 | html_theme = 'flask' 15 | 16 | The following themes exist: 17 | 18 | - 'flask' - the standard flask documentation theme for large 19 | projects 20 | - 'flask_small' - small one-page theme. Intended to be used by 21 | very small addon libraries for flask. 22 | 23 | The following options exist for the flask_small theme: 24 | 25 | [options] 26 | index_logo = '' filename of a picture in _static 27 | to be used as replacement for the 28 | h1 in the index.rst file. 29 | index_logo_height = 120px height of the index logo 30 | github_fork = '' repository name on github for the 31 | "fork me" badge 32 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_themes/flask/layout.html: -------------------------------------------------------------------------------- 1 | {%- extends "basic/layout.html" %} 2 | {%- block extrahead %} 3 | {{ super() }} 4 | {% if theme_touch_icon %} 5 | 6 | {% endif %} 7 | 8 | {% endblock %} 9 | {%- block relbar2 %}{% endblock %} 10 | {% block header %} 11 | {{ super() }} 12 | {% if pagename == 'index' %} 13 |
14 | {% endif %} 15 | {% endblock %} 16 | {%- block footer %} 17 | 21 | {% if pagename == 'index' %} 22 |
23 | {% endif %} 24 | {%- endblock %} 25 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_themes/flask/relations.html: -------------------------------------------------------------------------------- 1 |

Related Topics

2 | 20 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/_themes/flask/theme.conf: -------------------------------------------------------------------------------- 1 | [theme] 2 | inherit = basic 3 | stylesheet = flasky.css 4 | pygments_style = flask_theme_support.FlaskyStyle 5 | 6 | [options] 7 | index_logo = '' 8 | index_logo_height = 120px 9 | touch_icon = 10 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/index.rst: -------------------------------------------------------------------------------- 1 | 2 | Release announcements 3 | =========================================== 4 | 5 | .. toctree:: 6 | :maxdepth: 2 7 | 8 | release-2.7.2 9 | release-2.7.1 10 | release-2.7.0 11 | release-2.6.3 12 | release-2.6.2 13 | release-2.6.1 14 | release-2.6.0 15 | release-2.5.2 16 | release-2.5.1 17 | release-2.5.0 18 | release-2.4.2 19 | release-2.4.1 20 | release-2.4.0 21 | release-2.3.5 22 | release-2.3.4 23 | release-2.3.3 24 | release-2.3.2 25 | release-2.3.1 26 | release-2.3.0 27 | release-2.2.4 28 | release-2.2.2 29 | release-2.2.1 30 | release-2.2.0 31 | release-2.1.3 32 | release-2.1.2 33 | release-2.1.1 34 | release-2.1.0 35 | release-2.0.3 36 | release-2.0.2 37 | release-2.0.1 38 | release-2.0.0 39 | 40 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.0.3.rst: -------------------------------------------------------------------------------- 1 | py.test 2.0.3: bug fixes and speed ups 2 | =========================================================================== 3 | 4 | Welcome to pytest-2.0.3, a maintenance and bug fix release of pytest, 5 | a mature testing tool for Python, supporting CPython 2.4-3.2, Jython 6 | and latest PyPy interpreters. See the extensive docs with tested examples here: 7 | 8 | http://pytest.org/ 9 | 10 | If you want to install or upgrade pytest, just type one of:: 11 | 12 | pip install -U pytest # or 13 | easy_install -U pytest 14 | 15 | There also is a bugfix release 1.6 of pytest-xdist, the plugin 16 | that enables seemless distributed and "looponfail" testing for Python. 17 | 18 | best, 19 | holger krekel 20 | 21 | Changes between 2.0.2 and 2.0.3 22 | ---------------------------------------------- 23 | 24 | - fix issue38: nicer tracebacks on calls to hooks, particularly early 25 | configure/sessionstart ones 26 | 27 | - fix missing skip reason/meta information in junitxml files, reported 28 | via http://lists.idyll.org/pipermail/testing-in-python/2011-March/003928.html 29 | 30 | - fix issue34: avoid collection failure with "test" prefixed classes 31 | deriving from object. 32 | 33 | - don't require zlib (and other libs) for genscript plugin without 34 | --genscript actually being used. 35 | 36 | - speed up skips (by not doing a full traceback represenation 37 | internally) 38 | 39 | - fix issue37: avoid invalid characters in junitxml's output 40 | 41 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.1.0.rst: -------------------------------------------------------------------------------- 1 | py.test 2.1.0: perfected assertions and bug fixes 2 | =========================================================================== 3 | 4 | Welcome to the release of pytest-2.1, a mature testing tool for Python, 5 | supporting CPython 2.4-3.2, Jython and latest PyPy interpreters. See 6 | the improved extensive docs (now also as PDF!) with tested examples here: 7 | 8 | http://pytest.org/ 9 | 10 | The single biggest news about this release are **perfected assertions** 11 | courtesy of Benjamin Peterson. You can now safely use ``assert`` 12 | statements in test modules without having to worry about side effects 13 | or python optimization ("-OO") options. This is achieved by rewriting 14 | assert statements in test modules upon import, using a PEP302 hook. 15 | See http://pytest.org/assert.html#advanced-assertion-introspection for 16 | detailed information. The work has been partly sponsored by my company, 17 | merlinux GmbH. 18 | 19 | For further details on bug fixes and smaller enhancements see below. 20 | 21 | If you want to install or upgrade pytest, just type one of:: 22 | 23 | pip install -U pytest # or 24 | easy_install -U pytest 25 | 26 | best, 27 | holger krekel / http://merlinux.eu 28 | 29 | Changes between 2.0.3 and 2.1.0 30 | ---------------------------------------------- 31 | 32 | - fix issue53 call nosestyle setup functions with correct ordering 33 | - fix issue58 and issue59: new assertion code fixes 34 | - merge Benjamin's assertionrewrite branch: now assertions 35 | for test modules on python 2.6 and above are done by rewriting 36 | the AST and saving the pyc file before the test module is imported. 37 | see doc/assert.txt for more info. 38 | - fix issue43: improve doctests with better traceback reporting on 39 | unexpected exceptions 40 | - fix issue47: timing output in junitxml for test cases is now correct 41 | - fix issue48: typo in MarkInfo repr leading to exception 42 | - fix issue49: avoid confusing error when initialization partially fails 43 | - fix issue44: env/username expansion for junitxml file path 44 | - show releaselevel information in test runs for pypy 45 | - reworked doc pages for better navigation and PDF generation 46 | - report KeyboardInterrupt even if interrupted during session startup 47 | - fix issue 35 - provide PDF doc version and download link from index page 48 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.1.1.rst: -------------------------------------------------------------------------------- 1 | py.test 2.1.1: assertion fixes and improved junitxml output 2 | =========================================================================== 3 | 4 | pytest-2.1.1 is a backward compatible maintenance release of the 5 | popular py.test testing tool. See extensive docs with examples here: 6 | 7 | http://pytest.org/ 8 | 9 | Most bug fixes address remaining issues with the perfected assertions 10 | introduced with 2.1.0 - many thanks to the bug reporters and to Benjamin 11 | Peterson for helping to fix them. Also, junitxml output now produces 12 | system-out/err tags which lead to better displays of tracebacks with Jenkins. 13 | 14 | Also a quick note to package maintainers and others interested: there now 15 | is a "pytest" man page which can be generated with "make man" in doc/. 16 | 17 | If you want to install or upgrade pytest, just type one of:: 18 | 19 | pip install -U pytest # or 20 | easy_install -U pytest 21 | 22 | best, 23 | holger krekel / http://merlinux.eu 24 | 25 | Changes between 2.1.0 and 2.1.1 26 | ---------------------------------------------- 27 | 28 | - fix issue64 / pytest.set_trace now works within pytest_generate_tests hooks 29 | - fix issue60 / fix error conditions involving the creation of __pycache__ 30 | - fix issue63 / assertion rewriting on inserts involving strings containing '%' 31 | - fix assertion rewriting on calls with a ** arg 32 | - don't cache rewritten modules if bytecode generation is disabled 33 | - fix assertion rewriting in read-only directories 34 | - fix issue59: provide system-out/err tags for junitxml output 35 | - fix issue61: assertion rewriting on boolean operations with 3 or more operands 36 | - you can now build a man page with "cd doc ; make man" 37 | 38 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.1.2.rst: -------------------------------------------------------------------------------- 1 | py.test 2.1.2: bug fixes and fixes for jython 2 | =========================================================================== 3 | 4 | pytest-2.1.2 is a minor backward compatible maintenance release of the 5 | popular py.test testing tool. pytest is commonly used for unit, 6 | functional- and integration testing. See extensive docs with examples 7 | here: 8 | 9 | http://pytest.org/ 10 | 11 | Most bug fixes address remaining issues with the perfected assertions 12 | introduced in the 2.1 series - many thanks to the bug reporters and to Benjamin 13 | Peterson for helping to fix them. pytest should also work better with 14 | Jython-2.5.1 (and Jython trunk). 15 | 16 | If you want to install or upgrade pytest, just type one of:: 17 | 18 | pip install -U pytest # or 19 | easy_install -U pytest 20 | 21 | best, 22 | holger krekel / http://merlinux.eu 23 | 24 | Changes between 2.1.1 and 2.1.2 25 | ---------------------------------------- 26 | 27 | - fix assertion rewriting on files with windows newlines on some Python versions 28 | - refine test discovery by package/module name (--pyargs), thanks Florian Mayer 29 | - fix issue69 / assertion rewriting fixed on some boolean operations 30 | - fix issue68 / packages now work with assertion rewriting 31 | - fix issue66: use different assertion rewriting caches when the -O option is passed 32 | - don't try assertion rewriting on Jython, use reinterp 33 | 34 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.1.3.rst: -------------------------------------------------------------------------------- 1 | py.test 2.1.3: just some more fixes 2 | =========================================================================== 3 | 4 | pytest-2.1.3 is a minor backward compatible maintenance release of the 5 | popular py.test testing tool. It is commonly used for unit, functional- 6 | and integration testing. See extensive docs with examples here: 7 | 8 | http://pytest.org/ 9 | 10 | The release contains another fix to the perfected assertions introduced 11 | with the 2.1 series as well as the new possibility to customize reporting 12 | for assertion expressions on a per-directory level. 13 | 14 | If you want to install or upgrade pytest, just type one of:: 15 | 16 | pip install -U pytest # or 17 | easy_install -U pytest 18 | 19 | Thanks to the bug reporters and to Ronny Pfannschmidt, Benjamin Peterson 20 | and Floris Bruynooghe who implemented the fixes. 21 | 22 | best, 23 | holger krekel 24 | 25 | Changes between 2.1.2 and 2.1.3 26 | ---------------------------------------- 27 | 28 | - fix issue79: assertion rewriting failed on some comparisons in boolops, 29 | - correctly handle zero length arguments (a la pytest '') 30 | - fix issue67 / junitxml now contains correct test durations 31 | - fix issue75 / skipping test failure on jython 32 | - fix issue77 / Allow assertrepr_compare hook to apply to a subset of tests 33 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.2.1.rst: -------------------------------------------------------------------------------- 1 | pytest-2.2.1: bug fixes, perfect teardowns 2 | =========================================================================== 3 | 4 | 5 | pytest-2.2.1 is a minor backward-compatible release of the the py.test 6 | testing tool. It contains bug fixes and little improvements, including 7 | documentation fixes. If you are using the distributed testing 8 | pluginmake sure to upgrade it to pytest-xdist-1.8. 9 | 10 | For general information see here: 11 | 12 | http://pytest.org/ 13 | 14 | To install or upgrade pytest: 15 | 16 | pip install -U pytest # or 17 | easy_install -U pytest 18 | 19 | Special thanks for helping on this release to Ronny Pfannschmidt, Jurko 20 | Gospodnetic and Ralf Schmitt. 21 | 22 | best, 23 | holger krekel 24 | 25 | 26 | Changes between 2.2.0 and 2.2.1 27 | ---------------------------------------- 28 | 29 | - fix issue99 (in pytest and py) internallerrors with resultlog now 30 | produce better output - fixed by normalizing pytest_internalerror 31 | input arguments. 32 | - fix issue97 / traceback issues (in pytest and py) improve traceback output 33 | in conjunction with jinja2 and cython which hack tracebacks 34 | - fix issue93 (in pytest and pytest-xdist) avoid "delayed teardowns": 35 | the final test in a test node will now run its teardown directly 36 | instead of waiting for the end of the session. Thanks Dave Hunt for 37 | the good reporting and feedback. The pytest_runtest_protocol as well 38 | as the pytest_runtest_teardown hooks now have "nextitem" available 39 | which will be None indicating the end of the test run. 40 | - fix collection crash due to unknown-source collected items, thanks 41 | to Ralf Schmitt (fixed by depending on a more recent pylib) 42 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.2.2.rst: -------------------------------------------------------------------------------- 1 | pytest-2.2.2: bug fixes 2 | =========================================================================== 3 | 4 | pytest-2.2.2 (updated to 2.2.3 to fix packaging issues) is a minor 5 | backward-compatible release of the versatile py.test testing tool. It 6 | contains bug fixes and a few refinements particularly to reporting with 7 | "--collectonly", see below for betails. 8 | 9 | For general information see here: 10 | 11 | http://pytest.org/ 12 | 13 | To install or upgrade pytest: 14 | 15 | pip install -U pytest # or 16 | easy_install -U pytest 17 | 18 | Special thanks for helping on this release to Ronny Pfannschmidt 19 | and Ralf Schmitt and the contributors of issues. 20 | 21 | best, 22 | holger krekel 23 | 24 | 25 | Changes between 2.2.1 and 2.2.2 26 | ---------------------------------------- 27 | 28 | - fix issue101: wrong args to unittest.TestCase test function now 29 | produce better output 30 | - fix issue102: report more useful errors and hints for when a 31 | test directory was renamed and some pyc/__pycache__ remain 32 | - fix issue106: allow parametrize to be applied multiple times 33 | e.g. from module, class and at function level. 34 | - fix issue107: actually perform session scope finalization 35 | - don't check in parametrize if indirect parameters are funcarg names 36 | - add chdir method to monkeypatch funcarg 37 | - fix crash resulting from calling monkeypatch undo a second time 38 | - fix issue115: make --collectonly robust against early failure 39 | (missing files/directories) 40 | - "-qq --collectonly" now shows only files and the number of tests in them 41 | - "-q --collectonly" now shows test ids 42 | - allow adding of attributes to test reports such that it also works 43 | with distributed testing (no upgrade of pytest-xdist needed) 44 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.2.4.rst: -------------------------------------------------------------------------------- 1 | pytest-2.2.4: bug fixes, better junitxml/unittest/python3 compat 2 | =========================================================================== 3 | 4 | pytest-2.2.4 is a minor backward-compatible release of the versatile 5 | py.test testing tool. It contains bug fixes and a few refinements 6 | to junitxml reporting, better unittest- and python3 compatibility. 7 | 8 | For general information see here: 9 | 10 | http://pytest.org/ 11 | 12 | To install or upgrade pytest: 13 | 14 | pip install -U pytest # or 15 | easy_install -U pytest 16 | 17 | Special thanks for helping on this release to Ronny Pfannschmidt 18 | and Benjamin Peterson and the contributors of issues. 19 | 20 | best, 21 | holger krekel 22 | 23 | Changes between 2.2.3 and 2.2.4 24 | ----------------------------------- 25 | 26 | - fix error message for rewritten assertions involving the % operator 27 | - fix issue 126: correctly match all invalid xml characters for junitxml 28 | binary escape 29 | - fix issue with unittest: now @unittest.expectedFailure markers should 30 | be processed correctly (you can also use @pytest.mark markers) 31 | - document integration with the extended distribute/setuptools test commands 32 | - fix issue 140: propperly get the real functions 33 | of bound classmethods for setup/teardown_class 34 | - fix issue #141: switch from the deceased paste.pocoo.org to bpaste.net 35 | - fix issue #143: call unconfigure/sessionfinish always when 36 | configure/sessionstart where called 37 | - fix issue #144: better mangle test ids to junitxml classnames 38 | - upgrade distribute_setup.py to 0.6.27 39 | 40 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.3.1.rst: -------------------------------------------------------------------------------- 1 | pytest-2.3.1: fix regression with factory functions 2 | =========================================================================== 3 | 4 | pytest-2.3.1 is a quick follow-up release: 5 | 6 | - fix issue202 - regression with fixture functions/funcarg factories: 7 | using "self" is now safe again and works as in 2.2.4. Thanks 8 | to Eduard Schettino for the quick bug report. 9 | 10 | - disable pexpect pytest self tests on Freebsd - thanks Koob for the 11 | quick reporting 12 | 13 | - fix/improve interactive docs with --markers 14 | 15 | See 16 | 17 | http://pytest.org/ 18 | 19 | for general information. To install or upgrade pytest: 20 | 21 | pip install -U pytest # or 22 | easy_install -U pytest 23 | 24 | best, 25 | holger krekel 26 | 27 | 28 | Changes between 2.3.0 and 2.3.1 29 | ----------------------------------- 30 | 31 | - fix issue202 - fix regression: using "self" from fixture functions now 32 | works as expected (it's the same "self" instance that a test method 33 | which uses the fixture sees) 34 | 35 | - skip pexpect using tests (test_pdb.py mostly) on freebsd* systems 36 | due to pexpect not supporting it properly (hanging) 37 | 38 | - link to web pages from --markers output which provides help for 39 | pytest.mark.* usage. 40 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.3.2.rst: -------------------------------------------------------------------------------- 1 | pytest-2.3.2: some fixes and more traceback-printing speed 2 | =========================================================================== 3 | 4 | pytest-2.3.2 is a another stabilization release: 5 | 6 | - issue 205: fixes a regression with conftest detection 7 | - issue 208/29: fixes traceback-printing speed in some bad cases 8 | - fix teardown-ordering for parametrized setups 9 | - fix unittest and trial compat behaviour with respect to runTest() methods 10 | - issue 206 and others: some improvements to packaging 11 | - fix issue127 and others: improve some docs 12 | 13 | See 14 | 15 | http://pytest.org/ 16 | 17 | for general information. To install or upgrade pytest: 18 | 19 | pip install -U pytest # or 20 | easy_install -U pytest 21 | 22 | best, 23 | holger krekel 24 | 25 | 26 | Changes between 2.3.1 and 2.3.2 27 | ----------------------------------- 28 | 29 | - fix issue208 and fix issue29 use new py version to avoid long pauses 30 | when printing tracebacks in long modules 31 | 32 | - fix issue205 - conftests in subdirs customizing 33 | pytest_pycollect_makemodule and pytest_pycollect_makeitem 34 | now work properly 35 | 36 | - fix teardown-ordering for parametrized setups 37 | 38 | - fix issue127 - better documentation for pytest_addoption 39 | and related objects. 40 | 41 | - fix unittest behaviour: TestCase.runtest only called if there are 42 | test methods defined 43 | 44 | - improve trial support: don't collect its empty 45 | unittest.TestCase.runTest() method 46 | 47 | - "python setup.py test" now works with pytest itself 48 | 49 | - fix/improve internal/packaging related bits: 50 | 51 | - exception message check of test_nose.py now passes on python33 as well 52 | 53 | - issue206 - fix test_assertrewrite.py to work when a global 54 | PYTHONDONTWRITEBYTECODE=1 is present 55 | 56 | - add tox.ini to pytest distribution so that ignore-dirs and others config 57 | bits are properly distributed for maintainers who run pytest-own tests 58 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.3.3.rst: -------------------------------------------------------------------------------- 1 | pytest-2.3.3: integration fixes, py24 suport, ``*/**`` shown in traceback 2 | =========================================================================== 3 | 4 | pytest-2.3.3 is a another stabilization release of the py.test tool 5 | which offers uebersimple assertions, scalable fixture mechanisms 6 | and deep customization for testing with Python. Particularly, 7 | this release provides: 8 | 9 | - integration fixes and improvements related to flask, numpy, nose, 10 | unittest, mock 11 | 12 | - makes pytest work on py24 again (yes, people sometimes still need to use it) 13 | 14 | - show ``*,**`` args in pytest tracebacks 15 | 16 | Thanks to Manuel Jacob, Thomas Waldmann, Ronny Pfannschmidt, Pavel Repin 17 | and Andreas Taumoefolau for providing patches and all for the issues. 18 | 19 | See 20 | 21 | http://pytest.org/ 22 | 23 | for general information. To install or upgrade pytest: 24 | 25 | pip install -U pytest # or 26 | easy_install -U pytest 27 | 28 | best, 29 | holger krekel 30 | 31 | Changes between 2.3.2 and 2.3.3 32 | ----------------------------------- 33 | 34 | - fix issue214 - parse modules that contain special objects like e. g. 35 | flask's request object which blows up on getattr access if no request 36 | is active. thanks Thomas Waldmann. 37 | 38 | - fix issue213 - allow to parametrize with values like numpy arrays that 39 | do not support an __eq__ operator 40 | 41 | - fix issue215 - split test_python.org into multiple files 42 | 43 | - fix issue148 - @unittest.skip on classes is now recognized and avoids 44 | calling setUpClass/tearDownClass, thanks Pavel Repin 45 | 46 | - fix issue209 - reintroduce python2.4 support by depending on newer 47 | pylib which re-introduced statement-finding for pre-AST interpreters 48 | 49 | - nose support: only call setup if its a callable, thanks Andrew 50 | Taumoefolau 51 | 52 | - fix issue219 - add py2.4-3.3 classifiers to TROVE list 53 | 54 | - in tracebacks *,** arg values are now shown next to normal arguments 55 | (thanks Manuel Jacob) 56 | 57 | - fix issue217 - support mock.patch with pytest's fixtures - note that 58 | you need either mock-1.0.1 or the python3.3 builtin unittest.mock. 59 | 60 | - fix issue127 - improve documentation for pytest_addoption() and 61 | add a ``config.getoption(name)`` helper function for consistency. 62 | 63 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.3.4.rst: -------------------------------------------------------------------------------- 1 | pytest-2.3.4: stabilization, more flexible selection via "-k expr" 2 | =========================================================================== 3 | 4 | pytest-2.3.4 is a small stabilization release of the py.test tool 5 | which offers uebersimple assertions, scalable fixture mechanisms 6 | and deep customization for testing with Python. This release 7 | comes with the following fixes and features: 8 | 9 | - make "-k" option accept an expressions the same as with "-m" so that one 10 | can write: -k "name1 or name2" etc. This is a slight usage incompatibility 11 | if you used special syntax like "TestClass.test_method" which you now 12 | need to write as -k "TestClass and test_method" to match a certain 13 | method in a certain test class. 14 | - allow to dynamically define markers via 15 | item.keywords[...]=assignment integrating with "-m" option 16 | - yielded test functions will now have autouse-fixtures active but 17 | cannot accept fixtures as funcargs - it's anyway recommended to 18 | rather use the post-2.0 parametrize features instead of yield, see: 19 | http://pytest.org/latest/example/parametrize.html 20 | - fix autouse-issue where autouse-fixtures would not be discovered 21 | if defined in a a/conftest.py file and tests in a/tests/test_some.py 22 | - fix issue226 - LIFO ordering for fixture teardowns 23 | - fix issue224 - invocations with >256 char arguments now work 24 | - fix issue91 - add/discuss package/directory level setups in example 25 | - fixes related to autouse discovery and calling 26 | 27 | Thanks in particular to Thomas Waldmann for spotting and reporting issues. 28 | 29 | See 30 | 31 | http://pytest.org/ 32 | 33 | for general information. To install or upgrade pytest: 34 | 35 | pip install -U pytest # or 36 | easy_install -U pytest 37 | 38 | best, 39 | holger krekel 40 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.4.1.rst: -------------------------------------------------------------------------------- 1 | pytest-2.4.1: fixing three regressions compared to 2.3.5 2 | =========================================================================== 3 | 4 | pytest-2.4.1 is a quick follow up release to fix three regressions 5 | compared to 2.3.5 before they hit more people: 6 | 7 | - When using parser.addoption() unicode arguments to the 8 | "type" keyword should also be converted to the respective types. 9 | thanks Floris Bruynooghe, @dnozay. (fixes issue360 and issue362) 10 | 11 | - fix dotted filename completion when using argcomplete 12 | thanks Anthon van der Neuth. (fixes issue361) 13 | 14 | - fix regression when a 1-tuple ("arg",) is used for specifying 15 | parametrization (the values of the parametrization were passed 16 | nested in a tuple). Thanks Donald Stufft. 17 | 18 | - also merge doc typo fixes, thanks Andy Dirnberger 19 | 20 | as usual, docs at http://pytest.org and upgrades via:: 21 | 22 | pip install -U pytest 23 | 24 | have fun, 25 | holger krekel 26 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.4.2.rst: -------------------------------------------------------------------------------- 1 | pytest-2.4.2: colorama on windows, plugin/tmpdir fixes 2 | =========================================================================== 3 | 4 | pytest-2.4.2 is another bug-fixing release: 5 | 6 | - on Windows require colorama and a newer py lib so that py.io.TerminalWriter() 7 | now uses colorama instead of its own ctypes hacks. (fixes issue365) 8 | thanks Paul Moore for bringing it up. 9 | 10 | - fix "-k" matching of tests where "repr" and "attr" and other names would 11 | cause wrong matches because of an internal implementation quirk 12 | (don't ask) which is now properly implemented. fixes issue345. 13 | 14 | - avoid tmpdir fixture to create too long filenames especially 15 | when parametrization is used (issue354) 16 | 17 | - fix pytest-pep8 and pytest-flakes / pytest interactions 18 | (collection names in mark plugin was assuming an item always 19 | has a function which is not true for those plugins etc.) 20 | Thanks Andi Zeidler. 21 | 22 | - introduce node.get_marker/node.add_marker API for plugins 23 | like pytest-pep8 and pytest-flakes to avoid the messy 24 | details of the node.keywords pseudo-dicts. Adapted 25 | docs. 26 | 27 | - remove attempt to "dup" stdout at startup as it's icky. 28 | the normal capturing should catch enough possibilities 29 | of tests messing up standard FDs. 30 | 31 | - add pluginmanager.do_configure(config) as a link to 32 | config.do_configure() for plugin-compatibility 33 | 34 | as usual, docs at http://pytest.org and upgrades via:: 35 | 36 | pip install -U pytest 37 | 38 | have fun, 39 | holger krekel 40 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.5.1.rst: -------------------------------------------------------------------------------- 1 | pytest-2.5.1: fixes and new home page styling 2 | =========================================================================== 3 | 4 | pytest is a mature Python testing tool with more than a 1000 tests 5 | against itself, passing on many different interpreters and platforms. 6 | 7 | The 2.5.1 release maintains the "zero-reported-bugs" promise by fixing 8 | the three bugs reported since the last release a few days ago. It also 9 | features a new home page styling implemented by Tobias Bieniek, based on 10 | the flask theme from Armin Ronacher: 11 | 12 | http://pytest.org 13 | 14 | If you have anything more to improve styling and docs, 15 | we'd be very happy to merge further pull requests. 16 | 17 | On the coding side, the release also contains a little enhancement to 18 | fixture decorators allowing to directly influence generation of test 19 | ids, thanks to Floris Bruynooghe. Other thanks for helping with 20 | this release go to Anatoly Bubenkoff and Ronny Pfannschmidt. 21 | 22 | As usual, you can upgrade from pypi via:: 23 | 24 | pip install -U pytest 25 | 26 | have fun and a nice remaining "bug-free" time of the year :) 27 | holger krekel 28 | 29 | 2.5.1 30 | ----------------------------------- 31 | 32 | - merge new documentation styling PR from Tobias Bieniek. 33 | 34 | - fix issue403: allow parametrize of multiple same-name functions within 35 | a collection node. Thanks Andreas Kloeckner and Alex Gaynor for reporting 36 | and analysis. 37 | 38 | - Allow parameterized fixtures to specify the ID of the parameters by 39 | adding an ids argument to pytest.fixture() and pytest.yield_fixture(). 40 | Thanks Floris Bruynooghe. 41 | 42 | - fix issue404 by always using the binary xml escape in the junitxml 43 | plugin. Thanks Ronny Pfannschmidt. 44 | 45 | - fix issue407: fix addoption docstring to point to argparse instead of 46 | optparse. Thanks Daniel D. Wright. 47 | 48 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.5.2.rst: -------------------------------------------------------------------------------- 1 | pytest-2.5.2: fixes 2 | =========================================================================== 3 | 4 | pytest is a mature Python testing tool with more than a 1000 tests 5 | against itself, passing on many different interpreters and platforms. 6 | 7 | The 2.5.2 release fixes a few bugs with two maybe-bugs remaining and 8 | actively being worked on (and waiting for the bug reporter's input). 9 | We also have a new contribution guide thanks to Piotr Banaszkiewicz 10 | and others. 11 | 12 | See docs at: 13 | 14 | http://pytest.org 15 | 16 | As usual, you can upgrade from pypi via:: 17 | 18 | pip install -U pytest 19 | 20 | Thanks to the following people who contributed to this release: 21 | 22 | Anatoly Bubenkov 23 | Ronny Pfannschmidt 24 | Floris Bruynooghe 25 | Bruno Oliveira 26 | Andreas Pelme 27 | Jurko Gospodnetić 28 | Piotr Banaszkiewicz 29 | Simon Liedtke 30 | lakka 31 | Lukasz Balcerzak 32 | Philippe Muller 33 | Daniel Hahler 34 | 35 | have fun, 36 | holger krekel 37 | 38 | 2.5.2 39 | ----------------------------------- 40 | 41 | - fix issue409 -- better interoperate with cx_freeze by not 42 | trying to import from collections.abc which causes problems 43 | for py27/cx_freeze. Thanks Wolfgang L. for reporting and tracking it down. 44 | 45 | - fixed docs and code to use "pytest" instead of "py.test" almost everywhere. 46 | Thanks Jurko Gospodnetic for the complete PR. 47 | 48 | - fix issue425: mention at end of "py.test -h" that --markers 49 | and --fixtures work according to specified test path (or current dir) 50 | 51 | - fix issue413: exceptions with unicode attributes are now printed 52 | correctly also on python2 and with pytest-xdist runs. (the fix 53 | requires py-1.4.20) 54 | 55 | - copy, cleanup and integrate py.io capture 56 | from pylib 1.4.20.dev2 (rev 13d9af95547e) 57 | 58 | - address issue416: clarify docs as to conftest.py loading semantics 59 | 60 | - fix issue429: comparing byte strings with non-ascii chars in assert 61 | expressions now work better. Thanks Floris Bruynooghe. 62 | 63 | - make capfd/capsys.capture private, its unused and shouldnt be exposed 64 | 65 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.6.1.rst: -------------------------------------------------------------------------------- 1 | pytest-2.6.1: fixes and new xfail feature 2 | =========================================================================== 3 | 4 | pytest is a mature Python testing tool with more than a 1100 tests 5 | against itself, passing on many different interpreters and platforms. 6 | The 2.6.1 release is drop-in compatible to 2.5.2 and actually fixes some 7 | regressions introduced with 2.6.0. It also brings a little feature 8 | to the xfail marker which now recognizes expected exceptions, 9 | see the CHANGELOG below. 10 | 11 | See docs at: 12 | 13 | http://pytest.org 14 | 15 | As usual, you can upgrade from pypi via:: 16 | 17 | pip install -U pytest 18 | 19 | Thanks to all who contributed, among them: 20 | 21 | Floris Bruynooghe 22 | Bruno Oliveira 23 | Nicolas Delaby 24 | 25 | have fun, 26 | holger krekel 27 | 28 | Changes 2.6.1 29 | ================= 30 | 31 | - No longer show line numbers in the --verbose output, the output is now 32 | purely the nodeid. The line number is still shown in failure reports. 33 | Thanks Floris Bruynooghe. 34 | 35 | - fix issue437 where assertion rewriting could cause pytest-xdist slaves 36 | to collect different tests. Thanks Bruno Oliveira. 37 | 38 | - fix issue555: add "errors" attribute to capture-streams to satisfy 39 | some distutils and possibly other code accessing sys.stdout.errors. 40 | 41 | - fix issue547 capsys/capfd also work when output capturing ("-s") is disabled. 42 | 43 | - address issue170: allow pytest.mark.xfail(...) to specify expected exceptions via 44 | an optional "raises=EXC" argument where EXC can be a single exception 45 | or a tuple of exception classes. Thanks David Mohr for the complete 46 | PR. 47 | 48 | - fix integration of pytest with unittest.mock.patch decorator when 49 | it uses the "new" argument. Thanks Nicolas Delaby for test and PR. 50 | 51 | - fix issue with detecting conftest files if the arguments contain 52 | "::" node id specifications (copy pasted from "-v" output) 53 | 54 | - fix issue544 by only removing "@NUM" at the end of "::" separated parts 55 | and if the part has an ".py" extension 56 | 57 | - don't use py.std import helper, rather import things directly. 58 | Thanks Bruno Oliveira. 59 | 60 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.6.2.rst: -------------------------------------------------------------------------------- 1 | pytest-2.6.2: few fixes and cx_freeze support 2 | =========================================================================== 3 | 4 | pytest is a mature Python testing tool with more than a 1100 tests 5 | against itself, passing on many different interpreters and platforms. 6 | This release is drop-in compatible to 2.5.2 and 2.6.X. It also 7 | brings support for including pytest with cx_freeze or similar 8 | freezing tools into your single-file app distribution. For details 9 | see the CHANGELOG below. 10 | 11 | See docs at: 12 | 13 | http://pytest.org 14 | 15 | As usual, you can upgrade from pypi via:: 16 | 17 | pip install -U pytest 18 | 19 | Thanks to all who contributed, among them: 20 | 21 | Floris Bruynooghe 22 | Benjamin Peterson 23 | Bruno Oliveira 24 | 25 | have fun, 26 | holger krekel 27 | 28 | 2.6.2 29 | ----------- 30 | 31 | - Added function pytest.freeze_includes(), which makes it easy to embed 32 | pytest into executables using tools like cx_freeze. 33 | See docs for examples and rationale. Thanks Bruno Oliveira. 34 | 35 | - Improve assertion rewriting cache invalidation precision. 36 | 37 | - fixed issue561: adapt autouse fixture example for python3. 38 | 39 | - fixed issue453: assertion rewriting issue with __repr__ containing 40 | "\n{", "\n}" and "\n~". 41 | 42 | - fix issue560: correctly display code if an "else:" or "finally:" is 43 | followed by statements on the same line. 44 | 45 | - Fix example in monkeypatch documentation, thanks t-8ch. 46 | 47 | - fix issue572: correct tmpdir doc example for python3. 48 | 49 | - Do not mark as universal wheel because Python 2.6 is different from 50 | other builds due to the extra argparse dependency. Fixes issue566. 51 | Thanks sontek. 52 | 53 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.6.3.rst: -------------------------------------------------------------------------------- 1 | pytest-2.6.3: fixes and little improvements 2 | =========================================================================== 3 | 4 | pytest is a mature Python testing tool with more than a 1100 tests 5 | against itself, passing on many different interpreters and platforms. 6 | This release is drop-in compatible to 2.5.2 and 2.6.X. 7 | See below for the changes and see docs at: 8 | 9 | http://pytest.org 10 | 11 | As usual, you can upgrade from pypi via:: 12 | 13 | pip install -U pytest 14 | 15 | Thanks to all who contributed, among them: 16 | 17 | Floris Bruynooghe 18 | Oleg Sinyavskiy 19 | Uwe Schmitt 20 | Charles Cloud 21 | Wolfgang Schnerring 22 | 23 | have fun, 24 | holger krekel 25 | 26 | Changes 2.6.3 27 | ====================== 28 | 29 | - fix issue575: xunit-xml was reporting collection errors as failures 30 | instead of errors, thanks Oleg Sinyavskiy. 31 | 32 | - fix issue582: fix setuptools example, thanks Laszlo Papp and Ronny 33 | Pfannschmidt. 34 | 35 | - Fix infinite recursion bug when pickling capture.EncodedFile, thanks 36 | Uwe Schmitt. 37 | 38 | - fix issue589: fix bad interaction with numpy and others when showing 39 | exceptions. Check for precise "maximum recursion depth exceed" exception 40 | instead of presuming any RuntimeError is that one (implemented in py 41 | dep). Thanks Charles Cloud for analysing the issue. 42 | 43 | - fix conftest related fixture visibility issue: when running with a 44 | CWD outside a test package pytest would get fixture discovery wrong. 45 | Thanks to Wolfgang Schnerring for figuring out a reproducable example. 46 | 47 | - Introduce pytest_enter_pdb hook (needed e.g. by pytest_timeout to cancel the 48 | timeout when interactively entering pdb). Thanks Wolfgang Schnerring. 49 | 50 | - check xfail/skip also with non-python function test items. Thanks 51 | Floris Bruynooghe. 52 | 53 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.7.1.rst: -------------------------------------------------------------------------------- 1 | pytest-2.7.1: bug fixes 2 | ======================= 3 | 4 | pytest is a mature Python testing tool with more than a 1100 tests 5 | against itself, passing on many different interpreters and platforms. 6 | This release is supposed to be drop-in compatible to 2.7.0. 7 | 8 | See below for the changes and see docs at: 9 | 10 | http://pytest.org 11 | 12 | As usual, you can upgrade from pypi via:: 13 | 14 | pip install -U pytest 15 | 16 | Thanks to all who contributed to this release, among them: 17 | 18 | Bruno Oliveira 19 | Holger Krekel 20 | Ionel Maries Cristian 21 | Floris Bruynooghe 22 | 23 | Happy testing, 24 | The py.test Development Team 25 | 26 | 27 | 2.7.1 (compared to 2.7.0) 28 | ------------------------- 29 | 30 | - fix issue731: do not get confused by the braces which may be present 31 | and unbalanced in an object's repr while collapsing False 32 | explanations. Thanks Carl Meyer for the report and test case. 33 | 34 | - fix issue553: properly handling inspect.getsourcelines failures in 35 | FixtureLookupError which would lead to to an internal error, 36 | obfuscating the original problem. Thanks talljosh for initial 37 | diagnose/patch and Bruno Oliveira for final patch. 38 | 39 | - fix issue660: properly report scope-mismatch-access errors 40 | independently from ordering of fixture arguments. Also 41 | avoid the pytest internal traceback which does not provide 42 | information to the user. Thanks Holger Krekel. 43 | 44 | - streamlined and documented release process. Also all versions 45 | (in setup.py and documentation generation) are now read 46 | from _pytest/__init__.py. Thanks Holger Krekel. 47 | 48 | - fixed docs to remove the notion that yield-fixtures are experimental. 49 | They are here to stay :) Thanks Bruno Oliveira. 50 | 51 | - Support building wheels by using environment markers for the 52 | requirements. Thanks Ionel Maries Cristian. 53 | 54 | - fixed regression to 2.6.4 which surfaced e.g. in lost stdout capture printing 55 | when tests raised SystemExit. Thanks Holger Krekel. 56 | 57 | - reintroduced _pytest fixture of the pytester plugin which is used 58 | at least by pytest-xdist. 59 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/announce/release-2.7.2.rst: -------------------------------------------------------------------------------- 1 | pytest-2.7.2: bug fixes 2 | ======================= 3 | 4 | pytest is a mature Python testing tool with more than a 1100 tests 5 | against itself, passing on many different interpreters and platforms. 6 | This release is supposed to be drop-in compatible to 2.7.1. 7 | 8 | See below for the changes and see docs at: 9 | 10 | http://pytest.org 11 | 12 | As usual, you can upgrade from pypi via:: 13 | 14 | pip install -U pytest 15 | 16 | Thanks to all who contributed to this release, among them: 17 | 18 | Bruno Oliveira 19 | Floris Bruynooghe 20 | Punyashloka Biswal 21 | Aron Curzon 22 | Benjamin Peterson 23 | Thomas De Schampheleire 24 | Edison Gustavo Muenz 25 | Holger Krekel 26 | 27 | Happy testing, 28 | The py.test Development Team 29 | 30 | 31 | 2.7.2 (compared to 2.7.1) 32 | ----------------------------- 33 | 34 | - fix issue767: pytest.raises value attribute does not contain the exception 35 | instance on Python 2.6. Thanks Eric Siegerman for providing the test 36 | case and Bruno Oliveira for PR. 37 | 38 | - Automatically create directory for junitxml and results log. 39 | Thanks Aron Curzon. 40 | 41 | - fix issue713: JUnit XML reports for doctest failures. 42 | Thanks Punyashloka Biswal. 43 | 44 | - fix issue735: assertion failures on debug versions of Python 3.4+ 45 | Thanks Benjamin Peterson. 46 | 47 | - fix issue114: skipif marker reports to internal skipping plugin; 48 | Thanks Floris Bruynooghe for reporting and Bruno Oliveira for the PR. 49 | 50 | - fix issue748: unittest.SkipTest reports to internal pytest unittest plugin. 51 | Thanks Thomas De Schampheleire for reporting and Bruno Oliveira for the PR. 52 | 53 | - fix issue718: failed to create representation of sets containing unsortable 54 | elements in python 2. Thanks Edison Gustavo Muenz 55 | 56 | - fix issue756, fix issue752 (and similar issues): depend on py-1.4.29 57 | which has a refined algorithm for traceback generation. 58 | 59 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/bash-completion.rst: -------------------------------------------------------------------------------- 1 | 2 | .. _bash_completion: 3 | 4 | Setting up bash completion 5 | ========================== 6 | 7 | When using bash as your shell, ``pytest`` can use argcomplete 8 | (https://argcomplete.readthedocs.org/) for auto-completion. 9 | For this ``argcomplete`` needs to be installed **and** enabled. 10 | 11 | Install argcomplete using:: 12 | 13 | sudo pip install 'argcomplete>=0.5.7' 14 | 15 | For global activation of all argcomplete enabled python applications run:: 16 | 17 | sudo activate-global-python-argcomplete 18 | 19 | For permanent (but not global) ``pytest`` activation, use:: 20 | 21 | register-python-argcomplete py.test >> ~/.bashrc 22 | 23 | For one-time activation of argcomplete for ``pytest`` only, use:: 24 | 25 | eval "$(register-python-argcomplete py.test)" 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/changelog.rst: -------------------------------------------------------------------------------- 1 | 2 | .. _changelog: 3 | 4 | Changelog history 5 | ================================= 6 | 7 | .. include:: ../../CHANGELOG 8 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/check_sphinx.py: -------------------------------------------------------------------------------- 1 | import py 2 | import subprocess 3 | def test_build_docs(tmpdir): 4 | doctrees = tmpdir.join("doctrees") 5 | htmldir = tmpdir.join("html") 6 | subprocess.check_call([ 7 | "sphinx-build", "-W", "-bhtml", 8 | "-d", str(doctrees), ".", str(htmldir)]) 9 | 10 | def test_linkcheck(tmpdir): 11 | doctrees = tmpdir.join("doctrees") 12 | htmldir = tmpdir.join("html") 13 | subprocess.check_call( 14 | ["sphinx-build", "-blinkcheck", 15 | "-d", str(doctrees), ".", str(htmldir)]) 16 | 17 | 18 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/conftest.py: -------------------------------------------------------------------------------- 1 | collect_ignore = ["conf.py"] 2 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/contact.rst: -------------------------------------------------------------------------------- 1 | 2 | .. _`contact channels`: 3 | .. _`contact`: 4 | 5 | Contact channels 6 | =================================== 7 | 8 | - `pytest issue tracker`_ to report bugs or suggest features (for version 9 | 2.0 and above). 10 | 11 | - `pytest on stackoverflow.com `_ 12 | to post questions with the tag ``pytest``. New Questions will usually 13 | be seen by pytest users or developers and answered quickly. 14 | 15 | - `Testing In Python`_: a mailing list for Python testing tools and discussion. 16 | 17 | - `pytest-dev at python.org (mailing list)`_ pytest specific announcements and discussions. 18 | 19 | - `pytest-commit at python.org (mailing list)`_: for commits and new issues 20 | 21 | - :doc:`contribution guide ` for help on submitting pull 22 | requests to bitbucket (including using git via gitifyhg). 23 | 24 | - #pylib on irc.freenode.net IRC channel for random questions. 25 | 26 | - private mail to Holger.Krekel at gmail com if you want to communicate sensitive issues 27 | 28 | 29 | - `merlinux.eu`_ offers pytest and tox-related professional teaching and 30 | consulting. 31 | 32 | .. _`pytest issue tracker`: https://github.com/pytest-dev/pytest/issues 33 | .. _`old issue tracker`: http://bitbucket.org/hpk42/py-trunk/issues/ 34 | 35 | .. _`merlinux.eu`: http://merlinux.eu 36 | 37 | .. _`get an account`: 38 | 39 | .. _tetamap: http://tetamap.wordpress.com 40 | 41 | .. _`@pylibcommit`: http://twitter.com/pylibcommit 42 | 43 | 44 | .. _`Testing in Python`: http://lists.idyll.org/listinfo/testing-in-python 45 | .. _FOAF: http://en.wikipedia.org/wiki/FOAF 46 | .. _`py-dev`: 47 | .. _`development mailing list`: 48 | .. _`pytest-dev at python.org (mailing list)`: http://mail.python.org/mailman/listinfo/pytest-dev 49 | .. _`py-svn`: 50 | .. _`pytest-commit at python.org (mailing list)`: http://mail.python.org/mailman/listinfo/pytest-commit 51 | 52 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/contents.rst: -------------------------------------------------------------------------------- 1 | .. _toc: 2 | 3 | Full pytest documentation 4 | =========================== 5 | 6 | `Download latest version as PDF `_ 7 | 8 | .. `Download latest version as EPUB `_ 9 | 10 | .. toctree:: 11 | :maxdepth: 2 12 | 13 | overview 14 | apiref 15 | example/index 16 | plugins 17 | cache 18 | contributing 19 | plugins_index/index 20 | talks 21 | 22 | .. only:: html 23 | .. toctree:: 24 | 25 | funcarg_compare 26 | announce/index 27 | 28 | .. only:: html 29 | .. toctree:: 30 | :hidden: 31 | 32 | changelog 33 | 34 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/contributing.rst: -------------------------------------------------------------------------------- 1 | .. _contributing: 2 | 3 | .. include:: ../../CONTRIBUTING.rst 4 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/assertion/global_testmodule_config/conftest.py: -------------------------------------------------------------------------------- 1 | import pytest, py 2 | mydir = py.path.local(__file__).dirpath() 3 | 4 | def pytest_runtest_setup(item): 5 | if isinstance(item, pytest.Function): 6 | if not item.fspath.relto(mydir): 7 | return 8 | mod = item.getparent(pytest.Module).obj 9 | if hasattr(mod, 'hello'): 10 | print ("mod.hello %r" % (mod.hello,)) 11 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/assertion/global_testmodule_config/test_hello.py: -------------------------------------------------------------------------------- 1 | 2 | hello = "world" 3 | 4 | def test_func(): 5 | pass 6 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/assertion/test_failures.py: -------------------------------------------------------------------------------- 1 | 2 | import py 3 | failure_demo = py.path.local(__file__).dirpath('failure_demo.py') 4 | pytest_plugins = 'pytester', 5 | 6 | def test_failure_demo_fails_properly(testdir): 7 | target = testdir.tmpdir.join(failure_demo.basename) 8 | failure_demo.copy(target) 9 | failure_demo.copy(testdir.tmpdir.join(failure_demo.basename)) 10 | result = testdir.runpytest(target, syspathinsert=True) 11 | result.stdout.fnmatch_lines([ 12 | "*42 failed*" 13 | ]) 14 | assert result.ret != 0 15 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/assertion/test_setup_flow_example.py: -------------------------------------------------------------------------------- 1 | def setup_module(module): 2 | module.TestStateFullThing.classcount = 0 3 | 4 | class TestStateFullThing: 5 | def setup_class(cls): 6 | cls.classcount += 1 7 | 8 | def teardown_class(cls): 9 | cls.classcount -= 1 10 | 11 | def setup_method(self, method): 12 | self.id = eval(method.__name__[5:]) 13 | 14 | def test_42(self): 15 | assert self.classcount == 1 16 | assert self.id == 42 17 | 18 | def test_23(self): 19 | assert self.classcount == 1 20 | assert self.id == 23 21 | 22 | def teardown_module(module): 23 | assert module.TestStateFullThing.classcount == 0 24 | 25 | """ For this example the control flow happens as follows:: 26 | import test_setup_flow_example 27 | setup_module(test_setup_flow_example) 28 | setup_class(TestStateFullThing) 29 | instance = TestStateFullThing() 30 | setup_method(instance, instance.test_42) 31 | instance.test_42() 32 | setup_method(instance, instance.test_23) 33 | instance.test_23() 34 | teardown_class(TestStateFullThing) 35 | teardown_module(test_setup_flow_example) 36 | 37 | Note that ``setup_class(TestStateFullThing)`` is called and not 38 | ``TestStateFullThing.setup_class()`` which would require you 39 | to insert ``setup_class = classmethod(setup_class)`` to make 40 | your setup function callable. 41 | """ 42 | 43 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/conftest.py: -------------------------------------------------------------------------------- 1 | collect_ignore = ["nonpython"] 2 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/costlysetup/conftest.py: -------------------------------------------------------------------------------- 1 | 2 | import pytest 3 | 4 | @pytest.fixture("session") 5 | def setup(request): 6 | setup = CostlySetup() 7 | request.addfinalizer(setup.finalize) 8 | return setup 9 | 10 | class CostlySetup: 11 | def __init__(self): 12 | import time 13 | print ("performing costly setup") 14 | time.sleep(5) 15 | self.timecostly = 1 16 | 17 | def finalize(self): 18 | del self.timecostly 19 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/costlysetup/sub1/__init__.py: -------------------------------------------------------------------------------- 1 | # 2 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/costlysetup/sub1/test_quick.py: -------------------------------------------------------------------------------- 1 | 2 | def test_quick(setup): 3 | pass 4 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/costlysetup/sub2/__init__.py: -------------------------------------------------------------------------------- 1 | # 2 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/costlysetup/sub2/test_two.py: -------------------------------------------------------------------------------- 1 | def test_something(setup): 2 | assert setup.timecostly == 1 3 | 4 | def test_something_more(setup): 5 | assert setup.timecostly == 1 6 | 7 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/index.rst: -------------------------------------------------------------------------------- 1 | 2 | .. _examples: 3 | 4 | Usages and Examples 5 | =========================================== 6 | 7 | Here is a (growing) list of examples. :ref:`Contact ` us if you 8 | need more examples or have questions. Also take a look at the 9 | :ref:`comprehensive documentation ` which contains many example 10 | snippets as well. Also, `pytest on stackoverflow.com 11 | `_ often comes with example 12 | answers. 13 | 14 | For basic examples, see 15 | 16 | - :doc:`../getting-started` for basic introductory examples 17 | - :ref:`assert` for basic assertion examples 18 | - :ref:`fixtures` for basic fixture/setup examples 19 | - :ref:`parametrize` for basic test function parametrization 20 | - :doc:`../unittest` for basic unittest integration 21 | - :doc:`../nose` for basic nosetests integration 22 | 23 | The following examples aim at various use cases you might encounter. 24 | 25 | .. toctree:: 26 | :maxdepth: 2 27 | 28 | reportingdemo 29 | simple 30 | parametrize 31 | markers 32 | special 33 | pythoncollection 34 | nonpython 35 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/layout1/setup.cfg: -------------------------------------------------------------------------------- 1 | [pytest] 2 | testfilepatterns = 3 | ${topdir}/tests/unit/test_${basename} 4 | ${topdir}/tests/functional/*.py 5 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/multipython.py: -------------------------------------------------------------------------------- 1 | """ 2 | module containing a parametrized tests testing cross-python 3 | serialization via the pickle module. 4 | """ 5 | import py 6 | import pytest 7 | 8 | pythonlist = ['python2.6', 'python2.7', 'python3.3'] 9 | @pytest.fixture(params=pythonlist) 10 | def python1(request, tmpdir): 11 | picklefile = tmpdir.join("data.pickle") 12 | return Python(request.param, picklefile) 13 | 14 | @pytest.fixture(params=pythonlist) 15 | def python2(request, python1): 16 | return Python(request.param, python1.picklefile) 17 | 18 | class Python: 19 | def __init__(self, version, picklefile): 20 | self.pythonpath = py.path.local.sysfind(version) 21 | if not self.pythonpath: 22 | pytest.skip("%r not found" %(version,)) 23 | self.picklefile = picklefile 24 | def dumps(self, obj): 25 | dumpfile = self.picklefile.dirpath("dump.py") 26 | dumpfile.write(py.code.Source(""" 27 | import pickle 28 | f = open(%r, 'wb') 29 | s = pickle.dump(%r, f, protocol=2) 30 | f.close() 31 | """ % (str(self.picklefile), obj))) 32 | py.process.cmdexec("%s %s" %(self.pythonpath, dumpfile)) 33 | 34 | def load_and_is_true(self, expression): 35 | loadfile = self.picklefile.dirpath("load.py") 36 | loadfile.write(py.code.Source(""" 37 | import pickle 38 | f = open(%r, 'rb') 39 | obj = pickle.load(f) 40 | f.close() 41 | res = eval(%r) 42 | if not res: 43 | raise SystemExit(1) 44 | """ % (str(self.picklefile), expression))) 45 | print (loadfile) 46 | py.process.cmdexec("%s %s" %(self.pythonpath, loadfile)) 47 | 48 | @pytest.mark.parametrize("obj", [42, {}, {1:3},]) 49 | def test_basic_objects(python1, python2, obj): 50 | python1.dumps(obj) 51 | python2.load_and_is_true("obj == %s" % obj) 52 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/nonpython/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/example/nonpython/__init__.py -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/nonpython/conftest.py: -------------------------------------------------------------------------------- 1 | # content of conftest.py 2 | 3 | import pytest 4 | 5 | def pytest_collect_file(parent, path): 6 | if path.ext == ".yml" and path.basename.startswith("test"): 7 | return YamlFile(path, parent) 8 | 9 | class YamlFile(pytest.File): 10 | def collect(self): 11 | import yaml # we need a yaml parser, e.g. PyYAML 12 | raw = yaml.safe_load(self.fspath.open()) 13 | for name, spec in raw.items(): 14 | yield YamlItem(name, self, spec) 15 | 16 | class YamlItem(pytest.Item): 17 | def __init__(self, name, parent, spec): 18 | super(YamlItem, self).__init__(name, parent) 19 | self.spec = spec 20 | 21 | def runtest(self): 22 | for name, value in self.spec.items(): 23 | # some custom test execution (dumb example follows) 24 | if name != value: 25 | raise YamlException(self, name, value) 26 | 27 | def repr_failure(self, excinfo): 28 | """ called when self.runtest() raises an exception. """ 29 | if isinstance(excinfo.value, YamlException): 30 | return "\n".join([ 31 | "usecase execution failed", 32 | " spec failed: %r: %r" % excinfo.value.args[1:3], 33 | " no further details known at this point." 34 | ]) 35 | 36 | def reportinfo(self): 37 | return self.fspath, 0, "usecase: %s" % self.name 38 | 39 | class YamlException(Exception): 40 | """ custom exception for error reporting. """ 41 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/nonpython/test_simple.yml: -------------------------------------------------------------------------------- 1 | # test_simple.yml 2 | ok: 3 | sub1: sub1 4 | 5 | hello: 6 | world: world 7 | some: other 8 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/py2py3/conftest.py: -------------------------------------------------------------------------------- 1 | import sys 2 | import pytest 3 | 4 | py3 = sys.version_info[0] >= 3 5 | 6 | class DummyCollector(pytest.collect.File): 7 | def collect(self): 8 | return [] 9 | 10 | def pytest_pycollect_makemodule(path, parent): 11 | bn = path.basename 12 | if "py3" in bn and not py3 or ("py2" in bn and py3): 13 | return DummyCollector(path, parent=parent) 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/py2py3/test_py2.py: -------------------------------------------------------------------------------- 1 | 2 | def test_exception_syntax(): 3 | try: 4 | 0/0 5 | except ZeroDivisionError, e: 6 | pass 7 | 8 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/py2py3/test_py3.py: -------------------------------------------------------------------------------- 1 | 2 | def test_exception_syntax(): 3 | try: 4 | 0/0 5 | except ZeroDivisionError as e: 6 | pass 7 | 8 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/pythoncollection.py: -------------------------------------------------------------------------------- 1 | 2 | # run this with $ py.test --collect-only test_collectonly.py 3 | # 4 | def test_function(): 5 | pass 6 | 7 | class TestClass: 8 | def test_method(self): 9 | pass 10 | def test_anothermethod(self): 11 | pass 12 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/special.rst: -------------------------------------------------------------------------------- 1 | A session-fixture which can look at all collected tests 2 | ---------------------------------------------------------------- 3 | 4 | A session-scoped fixture effectively has access to all 5 | collected test items. Here is an example of a fixture 6 | function which walks all collected tests and looks 7 | if their test class defines a ``callme`` method and 8 | calls it:: 9 | 10 | # content of conftest.py 11 | 12 | import pytest 13 | 14 | @pytest.fixture(scope="session", autouse=True) 15 | def callattr_ahead_of_alltests(request): 16 | print ("callattr_ahead_of_alltests called") 17 | seen = set([None]) 18 | session = request.node 19 | for item in session.items: 20 | cls = item.getparent(pytest.Class) 21 | if cls not in seen: 22 | if hasattr(cls.obj, "callme"): 23 | cls.obj.callme() 24 | seen.add(cls) 25 | 26 | test classes may now define a ``callme`` method which 27 | will be called ahead of running any tests:: 28 | 29 | # content of test_module.py 30 | 31 | class TestHello: 32 | @classmethod 33 | def callme(cls): 34 | print ("callme called!") 35 | 36 | def test_method1(self): 37 | print ("test_method1 called") 38 | 39 | def test_method2(self): 40 | print ("test_method1 called") 41 | 42 | class TestOther: 43 | @classmethod 44 | def callme(cls): 45 | print ("callme other called") 46 | def test_other(self): 47 | print ("test other") 48 | 49 | # works with unittest as well ... 50 | import unittest 51 | 52 | class SomeTest(unittest.TestCase): 53 | @classmethod 54 | def callme(self): 55 | print ("SomeTest callme called") 56 | 57 | def test_unit1(self): 58 | print ("test_unit1 method called") 59 | 60 | If you run this without output capturing:: 61 | 62 | $ py.test -q -s test_module.py 63 | callattr_ahead_of_alltests called 64 | callme called! 65 | callme other called 66 | SomeTest callme called 67 | test_method1 called 68 | .test_method1 called 69 | .test other 70 | .test_unit1 method called 71 | . 72 | 4 passed in 0.12 seconds 73 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/example/xfail_demo.py: -------------------------------------------------------------------------------- 1 | import pytest 2 | xfail = pytest.mark.xfail 3 | 4 | @xfail 5 | def test_hello(): 6 | assert 0 7 | 8 | @xfail(run=False) 9 | def test_hello2(): 10 | assert 0 11 | 12 | @xfail("hasattr(os, 'sep')") 13 | def test_hello3(): 14 | assert 0 15 | 16 | @xfail(reason="bug 110") 17 | def test_hello4(): 18 | assert 0 19 | 20 | @xfail('pytest.__version__[0] != "17"') 21 | def test_hello5(): 22 | assert 0 23 | 24 | def test_hello6(): 25 | pytest.xfail("reason") 26 | 27 | @xfail(raises=IndexError) 28 | def test_hello7(): 29 | x = [] 30 | x[1] = 1 31 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/feedback.rst: -------------------------------------------------------------------------------- 1 | 2 | What users say: 3 | 4 | `py.test is pretty much the best thing ever`_ (Alex Gaynor) 5 | 6 | 7 | .. _`py.test is pretty much the best thing ever`_ (Alex Gaynor) 8 | http://twitter.com/#!/alex_gaynor/status/22389410366 9 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/funcargs.rst: -------------------------------------------------------------------------------- 1 | 2 | ======================================================= 3 | funcargs: resource injection and parametrization 4 | ======================================================= 5 | 6 | pytest-2.3 introduces major refinements to fixture management 7 | of which the funcarg mechanism introduced with pytest-2.0 remains 8 | a core part. The documentation has been refactored as well 9 | and you can read on here: 10 | 11 | - :ref:`fixtures` 12 | - :ref:`parametrize` 13 | - :ref:`funcargcompare` 14 | 15 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/genapi.py: -------------------------------------------------------------------------------- 1 | import textwrap 2 | import inspect 3 | 4 | class Writer: 5 | def __init__(self, clsname): 6 | self.clsname = clsname 7 | 8 | def __enter__(self): 9 | self.file = open("%s.api" % self.clsname, "w") 10 | return self 11 | 12 | def __exit__(self, *args): 13 | self.file.close() 14 | print "wrote", self.file.name 15 | 16 | def line(self, line): 17 | self.file.write(line+"\n") 18 | 19 | def docmethod(self, method): 20 | doc = " ".join(method.__doc__.split()) 21 | indent = " " 22 | w = textwrap.TextWrapper(initial_indent=indent, 23 | subsequent_indent=indent) 24 | 25 | spec = inspect.getargspec(method) 26 | del spec.args[0] 27 | self.line(".. py:method:: " + method.__name__ + 28 | inspect.formatargspec(*spec)) 29 | self.line("") 30 | self.line(w.fill(doc)) 31 | self.line("") 32 | 33 | def pytest_funcarg__a(request): 34 | with Writer("request") as writer: 35 | writer.docmethod(request.getfuncargvalue) 36 | writer.docmethod(request.cached_setup) 37 | writer.docmethod(request.addfinalizer) 38 | writer.docmethod(request.applymarker) 39 | 40 | def test_hello(a): 41 | pass 42 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/img/cramer2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/img/cramer2.png -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/img/gaynor3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/img/gaynor3.png -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/img/keleshev.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/img/keleshev.png -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/img/pullrequest.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/img/pullrequest.png -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/img/pylib.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/img/pylib.png -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/img/pytest1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/img/pytest1.png -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/img/pytest1favi.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/img/pytest1favi.ico -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/img/theuni.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/img/theuni.png -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/links.inc: -------------------------------------------------------------------------------- 1 | 2 | .. _`skipping plugin`: plugin/skipping.html 3 | .. _`funcargs mechanism`: funcargs.html 4 | .. _`doctest.py`: http://docs.python.org/library/doctest.html 5 | .. _`xUnit style setup`: xunit_setup.html 6 | .. _`pytest_nose`: plugin/nose.html 7 | .. _`reStructured Text`: http://docutils.sourceforge.net 8 | .. _`Python debugger`: http://docs.python.org/lib/module-pdb.html 9 | .. _nose: https://nose.readthedocs.org/en/latest/ 10 | .. _pytest: http://pypi.python.org/pypi/pytest 11 | .. _mercurial: http://mercurial.selenic.com/wiki/ 12 | .. _`setuptools`: http://pypi.python.org/pypi/setuptools 13 | .. _`easy_install`: 14 | .. _`distribute docs`: 15 | .. _`distribute`: http://pypi.python.org/pypi/distribute 16 | .. _`pip`: http://pypi.python.org/pypi/pip 17 | .. _`virtualenv`: http://pypi.python.org/pypi/virtualenv 18 | .. _hudson: http://hudson-ci.org/ 19 | .. _jenkins: http://jenkins-ci.org/ 20 | .. _tox: http://testrun.org/tox 21 | .. _pylib: http://py.readthedocs.org/en/latest/ 22 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/mark.rst: -------------------------------------------------------------------------------- 1 | 2 | .. _mark: 3 | 4 | Marking test functions with attributes 5 | ================================================================= 6 | 7 | .. currentmodule:: _pytest.mark 8 | 9 | By using the ``pytest.mark`` helper you can easily set 10 | metadata on your test functions. There are 11 | some builtin markers, for example: 12 | 13 | * :ref:`skipif ` - skip a test function if a certain condition is met 14 | * :ref:`xfail ` - produce an "expected failure" outcome if a certain 15 | condition is met 16 | * :ref:`parametrize ` to perform multiple calls 17 | to the same test function. 18 | 19 | It's easy to create custom markers or to apply markers 20 | to whole test classes or modules. See :ref:`mark examples` for examples 21 | which also serve as documentation. 22 | 23 | .. note:: 24 | 25 | Marks can only be applied to tests, having no effect on 26 | :ref:`fixtures `. 27 | 28 | 29 | API reference for mark related objects 30 | ------------------------------------------------ 31 | 32 | .. autoclass:: MarkGenerator 33 | :members: 34 | 35 | .. autoclass:: MarkDecorator 36 | :members: 37 | 38 | .. autoclass:: MarkInfo 39 | :members: 40 | 41 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/naming20.rst: -------------------------------------------------------------------------------- 1 | 2 | .. _naming20: 3 | 4 | New pytest names in 2.0 (flat is better than nested) 5 | ---------------------------------------------------- 6 | 7 | If you used older version of the ``py`` distribution (which 8 | included the py.test command line tool and Python name space) 9 | you accessed helpers and possibly collection classes through 10 | the ``py.test`` Python namespaces. The new ``pytest`` 11 | Python module flaty provides the same objects, following 12 | these renaming rules:: 13 | 14 | py.test.XYZ -> pytest.XYZ 15 | py.test.collect.XYZ -> pytest.XYZ 16 | py.test.cmdline.main -> pytest.main 17 | 18 | The old ``py.test.*`` ways to access functionality remain 19 | valid but you are encouraged to do global renaming according 20 | to the above rules in your test code. 21 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/nose.rst: -------------------------------------------------------------------------------- 1 | Running tests written for nose 2 | ======================================= 3 | 4 | .. include:: links.inc 5 | 6 | ``pytest`` has basic support for running tests written for nose_. 7 | 8 | .. _nosestyle: 9 | 10 | Usage 11 | ------------- 12 | 13 | After :ref:`installation` type:: 14 | 15 | python setup.py develop # make sure tests can import our package 16 | py.test # instead of 'nosetests' 17 | 18 | and you should be able to run your nose style tests and 19 | make use of pytest's capabilities. 20 | 21 | Supported nose Idioms 22 | ---------------------- 23 | 24 | * setup and teardown at module/class/method level 25 | * SkipTest exceptions and markers 26 | * setup/teardown decorators 27 | * yield-based tests and their setup 28 | * ``__test__`` attribute on modules/classes/functions 29 | * general usage of nose utilities 30 | 31 | Unsupported idioms / known issues 32 | ---------------------------------- 33 | 34 | - unittest-style ``setUp, tearDown, setUpClass, tearDownClass`` 35 | are recognized only on ``unittest.TestCase`` classes but not 36 | on plain classes. ``nose`` supports these methods also on plain 37 | classes but pytest deliberately does not. As nose and pytest already 38 | both support ``setup_class, teardown_class, setup_method, teardown_method`` 39 | it doesn't seem useful to duplicate the unittest-API like nose does. 40 | If you however rather think pytest should support the unittest-spelling on 41 | plain classes please post `to this issue 42 | `_. 43 | 44 | - nose imports test modules with the same import path (e.g. 45 | ``tests.test_mod``) but different file system paths 46 | (e.g. ``tests/test_mode.py`` and ``other/tests/test_mode.py``) 47 | by extending sys.path/import semantics. pytest does not do that 48 | but there is discussion in `issue268 `_ for adding some support. Note that 49 | `nose2 choose to avoid this sys.path/import hackery `_. 50 | 51 | - nose-style doctests are not collected and executed correctly, 52 | also doctest fixtures don't work. 53 | 54 | - no nose-configuration is recognized 55 | 56 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/overview.rst: -------------------------------------------------------------------------------- 1 | ================================================== 2 | Getting started basics 3 | ================================================== 4 | 5 | .. toctree:: 6 | :maxdepth: 2 7 | 8 | index 9 | getting-started 10 | usage 11 | goodpractises 12 | projects 13 | faq 14 | 15 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/plugins_index/bitbucket.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/plugins_index/bitbucket.png -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/plugins_index/github.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yosriayed/GSM-scanner/27233b9eeaee7943ee3e78fa76cf73986be774a8/dependencies/pytest-2.8.1/doc/en/plugins_index/github.png -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/pytest.ini: -------------------------------------------------------------------------------- 1 | [pytest] 2 | # just defined to prevent the root level tox.ini from kicking in 3 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/setup.rst: -------------------------------------------------------------------------------- 1 | 2 | setup: is now an "autouse fixture" 3 | ======================================================== 4 | 5 | During development prior to the pytest-2.3 release the name 6 | ``pytest.setup`` was used but before the release it was renamed 7 | and moved to become part of the general fixture mechanism, 8 | namely :ref:`autouse fixtures` 9 | 10 | 11 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/status.rst: -------------------------------------------------------------------------------- 1 | pytest development status 2 | ================================ 3 | 4 | https://travis-ci.org/pytest-dev/pytest 5 | 6 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/config.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 11 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/dist.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 11 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/extend.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 11 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/index.rst: -------------------------------------------------------------------------------- 1 | ======================================= 2 | pytest documentation index 3 | ======================================= 4 | 5 | 6 | features_: overview and discussion of features. 7 | 8 | quickstart_: getting started with writing a simple test. 9 | 10 | `talks, tutorials, examples`_: tutorial examples, slides 11 | 12 | funcargs_: powerful parametrized test function setup 13 | 14 | `plugins`_: list of available plugins with usage examples and feature details. 15 | 16 | customize_: configuration, customization, extensions 17 | 18 | changelog_: history of changes covering last releases 19 | 20 | **Continuous Integration of pytest's own tests and plugins with Hudson**: 21 | 22 | `http://hudson.testrun.org/view/pytest`_ 23 | 24 | .. _`http://hudson.testrun.org/view/pytest`: http://hudson.testrun.org/view/pytest/ 25 | 26 | 27 | .. _changelog: ../changelog.html 28 | .. _`plugins`: plugin/index.html 29 | .. _`talks, tutorials, examples`: talks.html 30 | .. _quickstart: quickstart.html 31 | .. _features: features.html 32 | .. _funcargs: funcargs.html 33 | .. _customize: customize.html 34 | 35 | 36 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/mission.rst: -------------------------------------------------------------------------------- 1 | 2 | Mission 3 | ==================================== 4 | 5 | ``pytest`` strives to make testing a fun and no-boilerplate effort. 6 | 7 | The tool is distributed as a `pytest` package. Its project independent 8 | ``py.test`` command line tool helps you to: 9 | 10 | * rapidly collect and run tests 11 | * run unit- or doctests, functional or integration tests 12 | * distribute tests to multiple environments 13 | * use local or global plugins for custom test types and setup 14 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/plugin/coverage.rst: -------------------------------------------------------------------------------- 1 | 2 | Write and report coverage data with the 'coverage' package. 3 | =========================================================== 4 | 5 | 6 | .. contents:: 7 | :local: 8 | 9 | Note: Original code by Ross Lawley. 10 | 11 | Install 12 | -------------- 13 | 14 | Use pip to (un)install:: 15 | 16 | pip install pytest-coverage 17 | pip uninstall pytest-coverage 18 | 19 | or alternatively use easy_install to install:: 20 | 21 | easy_install pytest-coverage 22 | 23 | 24 | Usage 25 | ------------- 26 | 27 | To get full test coverage reports for a particular package type:: 28 | 29 | py.test --cover-report=report 30 | 31 | command line options 32 | -------------------- 33 | 34 | 35 | ``--cover=COVERPACKAGES`` 36 | (multi allowed) only include info from specified package. 37 | ``--cover-report=REPORT_TYPE`` 38 | html: Directory for html output. 39 | report: Output a text report. 40 | annotate: Annotate your source code for which lines were executed and which were not. 41 | xml: Output an xml report compatible with the cobertura plugin for hudson. 42 | ``--cover-directory=DIRECTORY`` 43 | Directory for the reports (html / annotate results) defaults to ./coverage 44 | ``--cover-xml-file=XML_FILE`` 45 | File for the xml report defaults to ./coverage.xml 46 | ``--cover-show-missing`` 47 | Show missing files 48 | ``--cover-ignore-errors=IGNORE_ERRORS`` 49 | Ignore errors of finding source files for code. 50 | 51 | .. include:: links.txt 52 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/plugin/django.rst: -------------------------------------------------------------------------------- 1 | pytest_django plugin (EXTERNAL) 2 | ========================================== 3 | 4 | pytest_django is a plugin for ``pytest`` that provides a set of useful tools for testing Django applications, checkout Ben Firshman's `pytest_django github page`_. 5 | 6 | .. _`pytest_django github page`: http://github.com/bfirsh/pytest_django/tree/master 7 | 8 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/plugin/figleaf.rst: -------------------------------------------------------------------------------- 1 | 2 | report test coverage using the 'figleaf' package. 3 | ================================================= 4 | 5 | 6 | .. contents:: 7 | :local: 8 | 9 | Install 10 | --------------- 11 | 12 | To install the plugin issue:: 13 | 14 | easy_install pytest-figleaf # or 15 | pip install pytest-figleaf 16 | 17 | and if you are using pip you can also uninstall:: 18 | 19 | pip uninstall pytest-figleaf 20 | 21 | 22 | Usage 23 | --------------- 24 | 25 | After installation you can simply type:: 26 | 27 | py.test --figleaf [...] 28 | 29 | to enable figleaf coverage in your test run. A default ".figleaf" data file 30 | and "html" directory will be created. You can use command line options 31 | to control where data and html files are created. 32 | 33 | command line options 34 | -------------------- 35 | 36 | 37 | ``--figleaf`` 38 | trace python coverage with figleaf and write HTML for files below the current working dir 39 | ``--fig-data=dir`` 40 | set tracing file, default: ".figleaf". 41 | ``--fig-html=dir`` 42 | set html reporting dir, default "html". 43 | 44 | .. include:: links.txt 45 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/plugin/genscript.rst: -------------------------------------------------------------------------------- 1 | 2 | (deprecated) generate standalone test script to be distributed along with an application. 3 | ============================================================================ 4 | 5 | 6 | .. contents:: 7 | :local: 8 | 9 | 10 | 11 | command line options 12 | -------------------- 13 | 14 | 15 | ``--genscript=path`` 16 | create standalone ``pytest`` script at given target path. 17 | 18 | Start improving this plugin in 30 seconds 19 | ========================================= 20 | 21 | 22 | 1. Download `pytest_genscript.py`_ plugin source code 23 | 2. put it somewhere as ``pytest_genscript.py`` into your import path 24 | 3. a subsequent ``pytest`` run will use your local version 25 | 26 | Checkout customize_, other plugins_ or `get in contact`_. 27 | 28 | .. include:: links.txt 29 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/plugin/helpconfig.rst: -------------------------------------------------------------------------------- 1 | 2 | provide version info, conftest/environment config names. 3 | ======================================================== 4 | 5 | 6 | .. contents:: 7 | :local: 8 | 9 | 10 | 11 | command line options 12 | -------------------- 13 | 14 | 15 | ``--version`` 16 | display py lib version and import information. 17 | ``-p name`` 18 | early-load given plugin (multi-allowed). 19 | ``--traceconfig`` 20 | trace considerations of conftest.py files. 21 | ``--nomagic`` 22 | don't reinterpret asserts, no traceback cutting. 23 | ``--debug`` 24 | generate and show internal debugging information. 25 | ``--help-config`` 26 | show available conftest.py and ENV-variable names. 27 | 28 | Start improving this plugin in 30 seconds 29 | ========================================= 30 | 31 | 32 | 1. Download `pytest_helpconfig.py`_ plugin source code 33 | 2. put it somewhere as ``pytest_helpconfig.py`` into your import path 34 | 3. a subsequent ``pytest`` run will use your local version 35 | 36 | Checkout customize_, other plugins_ or `get in contact`_. 37 | 38 | .. include:: links.txt 39 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/plugin/index.rst: -------------------------------------------------------------------------------- 1 | 2 | advanced python testing 3 | ======================= 4 | 5 | skipping_ advanced skipping for python test functions, classes or modules. 6 | 7 | mark_ generic mechanism for marking python functions. 8 | 9 | pdb_ interactive debugging with the Python Debugger. 10 | 11 | figleaf_ (external) report test coverage using the 'figleaf' package. 12 | 13 | monkeypatch_ safely patch object attributes, dicts and environment variables. 14 | 15 | coverage_ (external) Write and report coverage data with the 'coverage' package. 16 | 17 | cov_ (external) produce code coverage reports using the 'coverage' package, including support for distributed testing. 18 | 19 | capture_ configurable per-test stdout/stderr capturing mechanisms. 20 | 21 | capturelog_ (external) capture output of logging module. 22 | 23 | recwarn_ helpers for asserting deprecation and other warnings. 24 | 25 | tmpdir_ provide temporary directories to test functions. 26 | 27 | 28 | distributed testing, CI and deployment 29 | ====================================== 30 | 31 | xdist_ (external) loop on failing tests, distribute test runs to CPUs and hosts. 32 | 33 | pastebin_ submit failure or test session information to a pastebin service. 34 | 35 | junitxml_ logging of test results in JUnit-XML format, for use with Hudson 36 | 37 | resultlog_ non-xml machine-readable logging of test results. 38 | 39 | genscript_ generate standalone test script to be distributed along with an application. 40 | 41 | 42 | testing domains and conventions codecheckers 43 | ============================================ 44 | 45 | oejskit_ (external) run javascript tests in real life browsers 46 | 47 | django_ (external) for testing django applications 48 | 49 | unittest_ automatically discover and run traditional "unittest.py" style tests. 50 | 51 | nose_ nose-compatibility plugin: allow to run nose test suites natively. 52 | 53 | doctest_ collect and execute doctests from modules and test files. 54 | 55 | restdoc_ perform ReST syntax, local and remote reference tests on .rst/.txt files. 56 | 57 | 58 | internal, debugging, help functionality 59 | ======================================= 60 | 61 | helpconfig_ provide version info, conftest/environment config names. 62 | 63 | terminal_ Implements terminal reporting of the full testing process. 64 | 65 | hooklog_ log invocations of extension hooks to a file. 66 | 67 | 68 | .. include:: links.txt 69 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/plugin/nose.rst: -------------------------------------------------------------------------------- 1 | 2 | nose-compatibility plugin: allow to run nose test suites natively. 3 | ================================================================== 4 | 5 | 6 | .. contents:: 7 | :local: 8 | 9 | This is an experimental plugin for allowing to run tests written 10 | in 'nosetests' style with ``pytest``. 11 | 12 | Usage 13 | ------------- 14 | 15 | type:: 16 | 17 | py.test # instead of 'nosetests' 18 | 19 | and you should be able to run nose style tests and at the same 20 | time can make full use of pytest's capabilities. 21 | 22 | Supported nose Idioms 23 | ---------------------- 24 | 25 | * setup and teardown at module/class/method level 26 | * SkipTest exceptions and markers 27 | * setup/teardown decorators 28 | * yield-based tests and their setup 29 | * general usage of nose utilities 30 | 31 | Unsupported idioms / issues 32 | ---------------------------------- 33 | 34 | - nose-style doctests are not collected and executed correctly, 35 | also fixtures don't work. 36 | 37 | - no nose-configuration is recognized 38 | 39 | If you find other issues or have suggestions please run:: 40 | 41 | py.test --pastebin=all 42 | 43 | and send the resulting URL to a ``pytest`` contact channel, 44 | at best to the mailing list. 45 | 46 | Start improving this plugin in 30 seconds 47 | ========================================= 48 | 49 | 50 | 1. Download `pytest_nose.py`_ plugin source code 51 | 2. put it somewhere as ``pytest_nose.py`` into your import path 52 | 3. a subsequent ``pytest`` run will use your local version 53 | 54 | Checkout customize_, other plugins_ or `get in contact`_. 55 | 56 | .. include:: links.txt 57 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/plugin/oejskit.rst: -------------------------------------------------------------------------------- 1 | pytest_oejskit plugin (EXTERNAL) 2 | ========================================== 3 | 4 | The `oejskit`_ offers a ``pytest`` plugin for running Javascript tests in live browsers. Running inside the browsers comes with some speed cost, on the other hand it means for example the code is tested against the real-word DOM implementations. 5 | The approach enables to write integration tests such that the JavaScript code is tested against server-side Python code mocked as necessary. Any server-side framework that can already be exposed through WSGI (or for which a subset of WSGI can be written to accommodate the jskit own needs) can play along. 6 | 7 | For more info and download please visit the `oejskit PyPI`_ page. 8 | 9 | .. _`oejskit`: 10 | .. _`oejskit PyPI`: http://pypi.python.org/pypi/oejskit 11 | 12 | .. source link 'http://bitbucket.org/pedronis/js-infrastructure/src/tip/pytest_jstests.py', 13 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/plugin/terminal.rst: -------------------------------------------------------------------------------- 1 | 2 | Implements terminal reporting of the full testing process. 3 | ========================================================== 4 | 5 | 6 | .. contents:: 7 | :local: 8 | 9 | This is a good source for looking at the various reporting hooks. 10 | 11 | command line options 12 | -------------------- 13 | 14 | 15 | ``-v, --verbose`` 16 | increase verbosity. 17 | ``-r chars`` 18 | show extra test summary info as specified by chars (f)ailed, (s)skipped, (x)failed, (X)passed. 19 | ``-l, --showlocals`` 20 | show locals in tracebacks (disabled by default). 21 | ``--report=opts`` 22 | (deprecated, use -r) 23 | ``--tb=style`` 24 | traceback print mode (long/short/line/no). 25 | ``--fulltrace`` 26 | don't cut any tracebacks (default is to cut). 27 | ``--fixtures`` 28 | show available function arguments, sorted by plugin 29 | 30 | Start improving this plugin in 30 seconds 31 | ========================================= 32 | 33 | 34 | 1. Download `pytest_terminal.py`_ plugin source code 35 | 2. put it somewhere as ``pytest_terminal.py`` into your import path 36 | 3. a subsequent ``pytest`` run will use your local version 37 | 38 | Checkout customize_, other plugins_ or `get in contact`_. 39 | 40 | .. include:: links.txt 41 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/doc/en/test/test.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 11 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/extra/get_issues.py: -------------------------------------------------------------------------------- 1 | import json 2 | import py 3 | import textwrap 4 | 5 | issues_url = "http://bitbucket.org/api/1.0/repositories/pytest-dev/pytest/issues" 6 | 7 | import requests 8 | 9 | def get_issues(): 10 | chunksize = 50 11 | start = 0 12 | issues = [] 13 | while 1: 14 | post_data = {"accountname": "pytest-dev", 15 | "repo_slug": "pytest", 16 | "start": start, 17 | "limit": chunksize} 18 | print ("getting from", start) 19 | r = requests.get(issues_url, params=post_data) 20 | data = r.json() 21 | issues.extend(data["issues"]) 22 | if start + chunksize >= data["count"]: 23 | return issues 24 | start += chunksize 25 | 26 | kind2num = "bug enhancement task proposal".split() 27 | 28 | status2num = "new open resolved duplicate invalid wontfix".split() 29 | 30 | def main(args): 31 | cachefile = py.path.local(args.cache) 32 | if not cachefile.exists() or args.refresh: 33 | issues = get_issues() 34 | cachefile.write(json.dumps(issues)) 35 | else: 36 | issues = json.loads(cachefile.read()) 37 | 38 | open_issues = [x for x in issues 39 | if x["status"] in ("new", "open")] 40 | 41 | def kind_and_id(x): 42 | kind = x["metadata"]["kind"] 43 | return kind2num.index(kind), len(issues)-int(x["local_id"]) 44 | open_issues.sort(key=kind_and_id) 45 | report(open_issues) 46 | 47 | def report(issues): 48 | for issue in issues: 49 | metadata = issue["metadata"] 50 | priority = issue["priority"] 51 | title = issue["title"] 52 | content = issue["content"] 53 | kind = metadata["kind"] 54 | status = issue["status"] 55 | id = issue["local_id"] 56 | link = "https://bitbucket.org/pytest-dev/pytest/issue/%s/" % id 57 | print("----") 58 | print(status, kind, link) 59 | print(title) 60 | #print() 61 | #lines = content.split("\n") 62 | #print ("\n".join(lines[:3])) 63 | #if len(lines) > 3 or len(content) > 240: 64 | # print ("...") 65 | 66 | if __name__ == "__main__": 67 | import argparse 68 | parser = argparse.ArgumentParser("process bitbucket issues") 69 | parser.add_argument("--refresh", action="store_true", 70 | help="invalidate cache, refresh issues") 71 | parser.add_argument("--cache", action="store", default="issues.json", 72 | help="cache file") 73 | args = parser.parse_args() 74 | main(args) 75 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/extra/setup-py.test/setup.py: -------------------------------------------------------------------------------- 1 | import sys 2 | from distutils.core import setup 3 | 4 | if __name__ == "__main__": 5 | if "sdist" not in sys.argv[1:]: 6 | raise ValueError("please use 'pytest' pypi package instead of 'py.test'") 7 | setup( 8 | name="py.test", 9 | version="0.0", 10 | description="please use 'pytest' for installation", 11 | ) 12 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/plugin-test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # this assumes plugins are installed as sister directories 4 | 5 | set -e 6 | cd ../pytest-pep8 7 | py.test 8 | cd ../pytest-instafail 9 | py.test 10 | cd ../pytest-cache 11 | py.test 12 | cd ../pytest-xprocess 13 | py.test 14 | #cd ../pytest-cov 15 | #py.test 16 | cd ../pytest-capturelog 17 | py.test 18 | cd ../pytest-xdist 19 | py.test 20 | 21 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/pytest.py: -------------------------------------------------------------------------------- 1 | # PYTHON_ARGCOMPLETE_OK 2 | """ 3 | pytest: unit and functional testing with Python. 4 | """ 5 | __all__ = [ 6 | 'main', 7 | 'UsageError', 8 | 'cmdline', 9 | 'hookspec', 10 | 'hookimpl', 11 | '__version__', 12 | ] 13 | 14 | if __name__ == '__main__': # if run as a script or by 'python -m pytest' 15 | # we trigger the below "else" condition by the following import 16 | import pytest 17 | raise SystemExit(pytest.main()) 18 | 19 | # else we are imported 20 | 21 | from _pytest.config import ( 22 | main, UsageError, _preloadplugins, cmdline, 23 | hookspec, hookimpl 24 | ) 25 | from _pytest import __version__ 26 | 27 | _preloadplugins() # to populate pytest.* namespace so help(pytest) works 28 | 29 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/requirements-docs.txt: -------------------------------------------------------------------------------- 1 | sphinx==1.2.3 2 | regendoc 3 | pyyaml 4 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/runtox.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | 3 | if __name__ == "__main__": 4 | import subprocess 5 | import sys 6 | subprocess.call([sys.executable, "-m", "tox", 7 | "-i", "ALL=https://devpi.net/hpk/dev/", 8 | "--develop"] + sys.argv[1:]) 9 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/setup.cfg: -------------------------------------------------------------------------------- 1 | [build_sphinx] 2 | source-dir = doc/en/ 3 | build-dir = doc/build 4 | all_files = 1 5 | 6 | [upload_sphinx] 7 | upload-dir = doc/en/build/html 8 | 9 | [bdist_wheel] 10 | universal = 1 11 | 12 | [devpi:upload] 13 | formats = sdist.tgz,bdist_wheel 14 | 15 | [egg_info] 16 | tag_build = 17 | tag_date = 0 18 | tag_svn_revision = 0 19 | 20 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/testing/cx_freeze/install_cx_freeze.py: -------------------------------------------------------------------------------- 1 | """ 2 | Installs cx_freeze from source, but first patching 3 | setup.py as described here: 4 | 5 | http://stackoverflow.com/questions/25107697/compiling-cx-freeze-under-ubuntu 6 | """ 7 | import glob 8 | import tarfile 9 | import os 10 | import sys 11 | import platform 12 | import py 13 | 14 | if __name__ == '__main__': 15 | if 'ubuntu' not in platform.version().lower(): 16 | 17 | print('Not Ubuntu, installing using pip. (platform.version() is %r)' % 18 | platform.version()) 19 | res = os.system('pip install cx_freeze') 20 | if res != 0: 21 | sys.exit(res) 22 | sys.exit(0) 23 | 24 | rootdir = py.path.local.make_numbered_dir(prefix='cx_freeze') 25 | 26 | res = os.system('pip install --download %s --no-use-wheel ' 27 | 'cx_freeze' % rootdir) 28 | if res != 0: 29 | sys.exit(res) 30 | 31 | packages = glob.glob('%s/*.tar.gz' % rootdir) 32 | assert len(packages) == 1 33 | tar_filename = packages[0] 34 | 35 | tar_file = tarfile.open(tar_filename) 36 | try: 37 | tar_file.extractall(path=str(rootdir)) 38 | finally: 39 | tar_file.close() 40 | 41 | basename = os.path.basename(tar_filename).replace('.tar.gz', '') 42 | setup_py_filename = '%s/%s/setup.py' % (rootdir, basename) 43 | with open(setup_py_filename) as f: 44 | lines = f.readlines() 45 | 46 | line_to_patch = 'if not vars.get("Py_ENABLE_SHARED", 0):' 47 | for index, line in enumerate(lines): 48 | if line_to_patch in line: 49 | indent = line[:line.index(line_to_patch)] 50 | lines[index] = indent + 'if True:\n' 51 | print('Patched line %d' % (index + 1)) 52 | break 53 | else: 54 | sys.exit('Could not find line in setup.py to patch!') 55 | 56 | with open(setup_py_filename, 'w') as f: 57 | f.writelines(lines) 58 | 59 | os.chdir('%s/%s' % (rootdir, basename)) 60 | res = os.system('python setup.py install') 61 | if res != 0: 62 | sys.exit(res) 63 | 64 | sys.exit(0) 65 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/testing/cx_freeze/runtests_script.py: -------------------------------------------------------------------------------- 1 | """ 2 | This is the script that is actually frozen into an executable: simply executes 3 | py.test main(). 4 | """ 5 | 6 | if __name__ == '__main__': 7 | import sys 8 | import pytest 9 | sys.exit(pytest.main()) -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/testing/cx_freeze/runtests_setup.py: -------------------------------------------------------------------------------- 1 | """ 2 | Sample setup.py script that generates an executable with pytest runner embedded. 3 | """ 4 | if __name__ == '__main__': 5 | from cx_Freeze import setup, Executable 6 | import pytest 7 | 8 | setup( 9 | name="runtests", 10 | version="0.1", 11 | description="exemple of how embedding py.test into an executable using cx_freeze", 12 | executables=[Executable("runtests_script.py")], 13 | options={"build_exe": {'includes': pytest.freeze_includes()}}, 14 | ) 15 | 16 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/testing/cx_freeze/tests/test_doctest.txt: -------------------------------------------------------------------------------- 1 | 2 | 3 | Testing doctest:: 4 | 5 | >>> 1 + 1 6 | 2 7 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/testing/cx_freeze/tests/test_trivial.py: -------------------------------------------------------------------------------- 1 | 2 | def test_upper(): 3 | assert 'foo'.upper() == 'FOO' 4 | 5 | def test_lower(): 6 | assert 'FOO'.lower() == 'foo' -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/testing/cx_freeze/tox_run.py: -------------------------------------------------------------------------------- 1 | """ 2 | Called by tox.ini: uses the generated executable to run the tests in ./tests/ 3 | directory. 4 | 5 | .. note:: somehow calling "build/runtests_script" directly from tox doesn't 6 | seem to work (at least on Windows). 7 | """ 8 | if __name__ == '__main__': 9 | import os 10 | import sys 11 | 12 | executable = os.path.join(os.getcwd(), 'build', 'runtests_script') 13 | if sys.platform.startswith('win'): 14 | executable += '.exe' 15 | sys.exit(os.system('%s tests' % executable)) -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/testing/python/raises.py: -------------------------------------------------------------------------------- 1 | import pytest 2 | 3 | class TestRaises: 4 | def test_raises(self): 5 | source = "int('qwe')" 6 | excinfo = pytest.raises(ValueError, source) 7 | code = excinfo.traceback[-1].frame.code 8 | s = str(code.fullsource) 9 | assert s == source 10 | 11 | def test_raises_exec(self): 12 | pytest.raises(ValueError, "a,x = []") 13 | 14 | def test_raises_syntax_error(self): 15 | pytest.raises(SyntaxError, "qwe qwe qwe") 16 | 17 | def test_raises_function(self): 18 | pytest.raises(ValueError, int, 'hello') 19 | 20 | def test_raises_callable_no_exception(self): 21 | class A: 22 | def __call__(self): 23 | pass 24 | try: 25 | pytest.raises(ValueError, A()) 26 | except pytest.raises.Exception: 27 | pass 28 | 29 | def test_raises_flip_builtin_AssertionError(self): 30 | # we replace AssertionError on python level 31 | # however c code might still raise the builtin one 32 | from _pytest.assertion.util import BuiltinAssertionError # noqa 33 | pytest.raises(AssertionError,""" 34 | raise BuiltinAssertionError 35 | """) 36 | 37 | def test_raises_as_contextmanager(self, testdir): 38 | testdir.makepyfile(""" 39 | from __future__ import with_statement 40 | import py, pytest 41 | 42 | def test_simple(): 43 | with pytest.raises(ZeroDivisionError) as excinfo: 44 | assert isinstance(excinfo, py.code.ExceptionInfo) 45 | 1/0 46 | print (excinfo) 47 | assert excinfo.type == ZeroDivisionError 48 | assert isinstance(excinfo.value, ZeroDivisionError) 49 | 50 | def test_noraise(): 51 | with pytest.raises(pytest.raises.Exception): 52 | with pytest.raises(ValueError): 53 | int() 54 | 55 | def test_raise_wrong_exception_passes_by(): 56 | with pytest.raises(ZeroDivisionError): 57 | with pytest.raises(ValueError): 58 | 1/0 59 | """) 60 | result = testdir.runpytest() 61 | result.stdout.fnmatch_lines([ 62 | '*3 passed*', 63 | ]) 64 | 65 | def test_noclass(self): 66 | with pytest.raises(TypeError): 67 | pytest.raises('wrong', lambda: None) 68 | 69 | def test_tuple(self): 70 | with pytest.raises((KeyError, ValueError)): 71 | raise KeyError('oops') 72 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/testing/test_genscript.py: -------------------------------------------------------------------------------- 1 | import pytest 2 | import sys 3 | 4 | 5 | @pytest.fixture(scope="module") 6 | def standalone(request): 7 | return Standalone(request) 8 | 9 | class Standalone: 10 | def __init__(self, request): 11 | self.testdir = request.getfuncargvalue("testdir") 12 | script = "mypytest" 13 | result = self.testdir.runpytest("--genscript=%s" % script) 14 | assert result.ret == 0 15 | self.script = self.testdir.tmpdir.join(script) 16 | assert self.script.check() 17 | 18 | def run(self, anypython, testdir, *args): 19 | return testdir._run(anypython, self.script, *args) 20 | 21 | def test_gen(testdir, anypython, standalone): 22 | if sys.version_info >= (2,7): 23 | result = testdir._run(anypython, "-c", 24 | "import sys;print (sys.version_info >=(2,7))") 25 | assert result.ret == 0 26 | if result.stdout.str() == "False": 27 | pytest.skip("genscript called from python2.7 cannot work " 28 | "earlier python versions") 29 | result = standalone.run(anypython, testdir, '--version') 30 | if result.ret == 2: 31 | result.stderr.fnmatch_lines(["*ERROR: setuptools not installed*"]) 32 | elif result.ret == 0: 33 | result.stderr.fnmatch_lines([ 34 | "*imported from*mypytest*" 35 | ]) 36 | p = testdir.makepyfile("def test_func(): assert 0") 37 | result = standalone.run(anypython, testdir, p) 38 | assert result.ret != 0 39 | else: 40 | pytest.fail("Unexpected return code") 41 | 42 | 43 | def test_freeze_includes(): 44 | """ 45 | Smoke test for freeze_includes(), to ensure that it works across all 46 | supported python versions. 47 | """ 48 | includes = pytest.freeze_includes() 49 | assert len(includes) > 1 50 | assert '_pytest.genscript' in includes 51 | 52 | -------------------------------------------------------------------------------- /dependencies/pytest-2.8.1/testing/test_helpconfig.py: -------------------------------------------------------------------------------- 1 | from _pytest.main import EXIT_NOTESTSCOLLECTED 2 | import pytest 3 | 4 | def test_version(testdir, pytestconfig): 5 | result = testdir.runpytest("--version") 6 | assert result.ret == 0 7 | #p = py.path.local(py.__file__).dirpath() 8 | result.stderr.fnmatch_lines([ 9 | '*pytest*%s*imported from*' % (pytest.__version__, ) 10 | ]) 11 | if pytestconfig.pluginmanager.list_plugin_distinfo(): 12 | result.stderr.fnmatch_lines([ 13 | "*setuptools registered plugins:", 14 | "*at*", 15 | ]) 16 | 17 | def test_help(testdir): 18 | result = testdir.runpytest("--help") 19 | assert result.ret == 0 20 | result.stdout.fnmatch_lines(""" 21 | *-v*verbose* 22 | *setup.cfg* 23 | *minversion* 24 | *to see*markers*py.test --markers* 25 | *to see*fixtures*py.test --fixtures* 26 | """) 27 | 28 | def test_hookvalidation_unknown(testdir): 29 | testdir.makeconftest(""" 30 | def pytest_hello(xyz): 31 | pass 32 | """) 33 | result = testdir.runpytest() 34 | assert result.ret != 0 35 | result.stderr.fnmatch_lines([ 36 | '*unknown hook*pytest_hello*' 37 | ]) 38 | 39 | def test_hookvalidation_optional(testdir): 40 | testdir.makeconftest(""" 41 | import pytest 42 | @pytest.hookimpl(optionalhook=True) 43 | def pytest_hello(xyz): 44 | pass 45 | """) 46 | result = testdir.runpytest() 47 | assert result.ret == EXIT_NOTESTSCOLLECTED 48 | 49 | def test_traceconfig(testdir): 50 | result = testdir.runpytest("--traceconfig") 51 | result.stdout.fnmatch_lines([ 52 | "*using*pytest*py*", 53 | "*active plugins*", 54 | ]) 55 | 56 | def test_debug(testdir, monkeypatch): 57 | result = testdir.runpytest_subprocess("--debug") 58 | assert result.ret == EXIT_NOTESTSCOLLECTED 59 | p = testdir.tmpdir.join("pytestdebug.log") 60 | assert "pytest_sessionstart" in p.read() 61 | 62 | def test_PYTEST_DEBUG(testdir, monkeypatch): 63 | monkeypatch.setenv("PYTEST_DEBUG", "1") 64 | result = testdir.runpytest_subprocess() 65 | assert result.ret == EXIT_NOTESTSCOLLECTED 66 | result.stderr.fnmatch_lines([ 67 | "*pytest_plugin_registered*", 68 | "*manager*PluginManager*" 69 | ]) 70 | -------------------------------------------------------------------------------- /dependencies/readme: -------------------------------------------------------------------------------- 1 | In each folder : 2 | Run in a console : "python setup.py install" 3 | Pyshark need to be installed the last. 4 | you need also to install gr-gsm in gnuradio with pybombs app_store 5 | -------------------------------------------------------------------------------- /dependencies/readme~: -------------------------------------------------------------------------------- 1 | In each folder : 2 | Run in a console : "python setup.py install" 3 | Pyshark need to be installed the last. 4 | you need also to install gr-gsm in gnuradio with pybombs app_store 5 | -------------------------------------------------------------------------------- /readme~: -------------------------------------------------------------------------------- 1 | 2 | This application scan all GSM carriers in the area and detect the beacon channels of each GSM operator. It provide also a list of neighbor beacons. 3 | This list can be used to commit a man in the middle attack on a chosen operator by launching (openbts/yatebts) with one of his ARFCN in the list. 4 | 5 | the folder grc contains the gnuradio-companion flow graphs 6 | the folder app contains the python scripts of the application 7 | the folder dependencies 8 | 9 | 10 | --------------------------------------------------------------------------------