Saravanan666/pypi-org huggingface dataset:
Package: pytest-telegram
pytest-telegramPytest to Telegram reporting pluginFree software: MIT licenseRequirementsRequestsInstallationYou can install “pytest-telegram” viapip:$ pip install pytest-telegramUsageUse this plugin by running pytest normally and use the following options to customize report:>>> telegram:
    --telegram_id=CHAT_ID
                        Id of telegram chat
    --telegram_token=BOT_TOKEN
                        Telegram Bot token
    --telegram_report_url=URL
                        Link for test report, optional
    --telegram_custom_text=TEXT
                        Custom text, will be added for message, supports '\n' as newline, optional
    --telegram_success_sticker_id=FILE_ID
                        File id of telegram sticker which will be attach to Success report
    --telegram_fail_sticker_id=FILE_ID
                        File id of telegram sticker which will be attach to Failed report
    --telegram_disable_stickers
                        Disables stickers for bot
    --telegram_list_failed
                        Bot will send failed test namesExample$ pytest ./tests –telegram_id=100559633 –telegram_token=123:qwe –telegram_report_url=http://path.to.report –telegram_custom_text=”This is custom text”Success report:Failed report:IssuesIf you encounter any problems, pleasefile an issuealong with a detailed description.History1.0.0Initial release.1.0.3Fixed multiline custom text.1.1.0Added option for disabling stickers.Added option for list failed tests.1.2.0Added test session time to report.
Package: pytest-telegram-notifier
pytest-telegram-notifierTo activate the plugin, you must use the parameter--telegram-notifierCustom path or configuration file name--telegram-notifier-config-file <custom-path>An example of plugin configuration:[Telegram]parse_mode=markdownEnvironment variablesTELEGRAM_BOT_CHAT_ID=<chat-id>
TELEGRAM_BOT_ACCESS_TOKEN=<access-token>An example of Telegram message
Package: pytest-tempdir
Adds support for a predictable and repeatable temporary directory.ThisPytestplugin was generated withCookiecutteralong with@hackebrot’sCookiecutter-pytest-plugintemplate.FeaturesAdds support for a predictable and repeatable temporary directory through thetempdirfixture which gets cleaned up in the end of the test run
session(this behaviour can be disabled).RequirementsNone!InstallationYou can install “pytest-tempdir” viapipfromPyPI:$ pip install pytest-tempdirUsageSimply define apytest_tempdir_basenamefunction on yourconftest.pywhich returns a string to define the basename or pass--tempdir-basename.If you wish to leave the temporary directory intact for further inspection
after the tests suite ends, pass--tempdir-no-clean.ContributingContributions are very welcome. Tests can be run withtox, please ensure
the coverage at least stays the same before you submit a pull request.LicenseDistributed under the terms of theApache 2.0license, “pytest-tempdir” is free and open source softwareIssuesIf you encounter any problems, pleasefile an issuealong with a detailed description.Changelogv2019.9.16Fix hookspec definitionv2019.9.15Backwards compatiblev2019.9.14Take into account long paths on darwin for the tempdir rootv2019.7.18Lower log levelv2018.8.11Lower log call logging levelv2016.8.20Support pytest 2.x and 3.xv2015.12.6Each absolute path gets it’s own counterv2015.11.29Append a counter value to existing directory namesv2015.11.17Fix more encoding issues when running setup and the system locale is not setv2015.11.16Fix encoding issue when running setup and the system locale is not setv2015.11.8Fix stale tempdir cleanup logicv2015.11.6Wipe the tempdir directory on test session start if it existsv2015.11.4First working release
Package: pytest-terraform-fixture
pytest-terraform-fixture================🚀 Description-----------`--terraform-dir` で指定したディレクトリにある Terraform で作成されるリソースを動的に pytest の fixture として自動で定義してくれる pluginです🚀 Install-------github から引っ張ってきて。```shpip install pytest-terraform-fixture```🚀 Usage-----Terraform で作成したいリソースを記述する (ここでは `instance_a` のリソースを定義したとする)```terraformprovider "nifcloud" {access_key = "xxxxx"secret_key = "yyyyy"region     = "jp-east-1"endpoint   = "jp-east-1.conputing.api.nifcloud.com"}resource "nifcloud_instance" "instance_a" {instance_id             = "hogehogea"image_id                = "89"key_name                = "ssh_key"instance_type           = "large"description             = "pytest-terraform"availability_zone       = "east-11"disable_api_termination = "false"ip_type                 = "none"}```pytest で `instance_a` をリソースを使うテストを作成します (自動的に `instance_a` をfixutreとして定義してくれる)```pythonimport pytestfrom python_terraform import Terraformdef test_terraform_fixture(instance_a):# instance_a を作成するテストassert True```後は、 `*.tf` のディレクトリを指定して実行```shpytest --terraform-dir={実施したい *.tf をもつディレクトリ}```🚀 Requirements------------このプロジェクトを実行するには以下が必要です:* [python](https://www.python.org/) 3.4.+* [terraform](https://www.terraform.io) 0.11.+🚀 Contributing------------PR歓迎してます🚀 Support and Migration---------------------特に無し🚀 License-------- [MIT License](http://petitviolet.mit-license.org/)
Package: pytest-testbook
A plugin for executing tests written in Jupyter notebookThisPytestplugin was generated withCookiecutteralong with@hackebrot’sCookiecutter-pytest-plugintemplate.FeaturesTODORequirementsLatest version of Python (currently Python 3.5); Sorry, I haven’t tested it on Python 2.7 or any other versions.Latest version of pytest (currently pytest 2.9)JupyterInstallationYou can install “pytest-testbook” viapipfromPyPI:$ pip install pytest-testbookUsageTODOContributingContributions are very welcome. Tests can be run withtox, please ensure
the coverage at least stays the same before you submit a pull request.LicenseDistributed under the terms of theMITlicense, “pytest-testbook” is free and open source softwareIssuesIf you encounter any problems, pleasefile an issuealong with a detailed description.
Package: pytest-testdirectory
Testing code by invoking executable which potentially creates and deletes
files and directories can be hard and error prone.The purpose of this module is to simplify this task.pytest-testdirectory provides a py.test fixture for working with temporary
directories.Table of Contents:InstallationUsageRelase new versionSource codeDeveloper NotesTestsNotesInstallationTo install pytest-testdirectory:pip install pytest-testdirectoryUsageTo make it easy to use in with py.test the TestDirectory object can be
injected into a test function by using the testdirectory fixture.Example:def test_this_function(testdirectory):
    images = testdirectory.mkdir('images')
    images.copy_files('test/images/*')

    r = testdirectory.run('imagecompress --path=images')

    # r is an RunResult object containing information about the command
    # we just executed
    assert r.stdout.match('*finished successfully*')The testdirectory is an instance of TestDirectory and represents an actual
temporary directory somewhere on the machine running the test code. Using
the API we can create additional temporary directories, populate them with
an initial set of files and finally run some executable and observe its
behavior.Relase new versionEdit NEWS.rst and wscript (set correct VERSION)Run./waf uploadSource codeThe main functionality is found insrc/testdirectory.pyand the
corresponding unit test is intest/test_testdirectory.pyif you
want to play/modify/fix the code this would, in most cases, be the place
to start.Developer NotesWe try to make our projects as independent as possible of a local system setup.
For example with our native code (C/C++) we compile as much as possible from
source, since this makes us independent of what is currently installed
(libraries etc.) on a specific machine.To “fetch” sources we use Waf (https://waf.io/) augmented with dependency
resolution capabilities:https://github.com/steinwurf/wafThe goal is to enable a work-flow where running:./waf configure
./waf build --run_testsConfigures, builds and runs any available tests for a given project, such that
you as a developer can start hacking at the code.For Python project this is a bit unconventional, but we think it works well.TestsThe tests will run automatically by passing--run_teststo waf:./waf --run_testsThis follows what seems to be “best practice” advise, namely to install the
package in editable mode in a virtualenv.NotesWhy use ansrcfolder (https://hynek.me/articles/testing-packaging/).
tl;dr you should run your tests in the same environment as your users would
run your code. So by placing the source files in a non-importable folder you
avoid accidentally having access to resources not added to the Python
package your users will install…Python packaging guide:https://packaging.python.org/distributing/
Package: pytest-testdox
pytest-testdoxATestDox formatreporter for pytest.Installpip install pytest-testdoxUsageAdd the parameter--testdoxwhen runningpytest. For example:pytest--testdoxyour-tests/Tip: If you don't want to type--testdoxevery time you runpytest, add it
toaddoptsin yourini file.
For example:# content of pytest.ini or tox.ini[pytest]addopts=--testdox# or if you use setup.cfg[tool:pytest]addopts=--testdoxWhen using--testdox, the plugin will disable itself when not running on a
terminal. If you want the testdox report no matter what, use the parameter--force-testdoxinstead.Markers@pytest.mark.describeOverride the class name in the testdox report. For example:# test_demo.py@pytest.mark.describe('create_file')classTestCreateFile():deftest_creates_a_file_in_the_so(self):passWill produce the output:test_demo.py

create_file
 [x] creates a file in the so@pytest.mark.itOverride the test title in the testdox report. For example:# test_demo.pyclassTestCreateFile():@pytest.mark.it('Creates a local file in the SO')deftest_creates_a_file_in_the_so(self):passWill produce the output:test_demo.py

Create File
 [x] Creates a local file in the SOConfiguration file optionstestdox_formatSpecifies TestDox report format,plaintextorutf8(default:utf8). For example:# content of pytest.ini# (or tox.ini or setup.cfg)[pytest]testdox_format=plaintext$pytesttest_demo.py============================= test session starts ==============================platform darwin -- Python 3.5.0, pytest-3.0.7, py-1.4.33, pluggy-0.4.0rootdir: /private/tmp/demo, inifile: pytest.iniplugins: testdox-devcollected 2 itemstest_demo.pyPytest Testdox[x] prints a BDD style output to your tests[x] lets you focus on the behavior
Package: pytest-test-grouping
Welcome to pytest-test-groups!pytest-test-groups allows you to split your test runs into groups of a specific
size to make it easier to split up your test runs.Usage# Install pytest-test-groups
pip install pytest-test-groups

# Split the tests into 10 groups and run the second group
py.test --test-group-count 10 --test-group=2

# Randomize the test order, split into 10 groups, and run the second group
py.test --test-group-count 10 --test-group=2 --test-group-random-seed=12345Why would I use this?Sometimes you may have some long running test jobs that take a
while to complete. This can be a major headache when trying to
run tests quickly. pytest-test-groups allows you to easily say
“split my tests into groups of 10 tests and run the second group”.
This is primarily useful in the context of CI builds.
Package: pytest-test-groups
Welcome to pytest-test-groups!pytest-test-groups allows you to split your test runs into groups of a specific
size to make it easier to split up your test runs.Usage# Install pytest-test-groups
pip install pytest-test-groups

# Split the tests into 10 groups and run the second group
py.test --test-group-count 10 --test-group=2

# Randomize the test order, split into 10 groups, and run the second group
py.test --test-group-count 10 --test-group=2 --test-group-random-seed=12345Why would I use this?Sometimes you may have some long running test jobs that take a
while to complete. This can be a major headache when trying to
run tests quickly. pytest-test-groups allows you to easily say
“split my tests into groups of 10 tests and run the second group”.
This is primarily useful in the context of CI builds.
Package: pytest-testinfra
Latest documentation:https://testinfra.readthedocs.io/en/latestAboutWith Testinfra you can write unit tests in Python to testactual stateof
your servers configured by management tools likeSalt,Ansible,Puppet,Chefand so on.Testinfra aims to be aServerspecequivalent in python and is written as
a plugin to the powerfulPytesttest engineLicenseApache License 2.0The logo is licensed under theCreative Commons NoDerivatives 4.0 LicenseIf you have some other use in mind, contact us.Quick startInstall testinfra using pip:$ pip install pytest-testinfra

# or install the devel version
$ pip install 'git+https://github.com/pytest-dev/pytest-testinfra@main#egg=pytest-testinfra'Write your first tests file totest_myinfra.py:deftest_passwd_file(host):passwd=host.file("/etc/passwd")assertpasswd.contains("root")assertpasswd.user=="root"assertpasswd.group=="root"assertpasswd.mode==0o644deftest_nginx_is_installed(host):nginx=host.package("nginx")assertnginx.is_installedassertnginx.version.startswith("1.2")deftest_nginx_running_and_enabled(host):nginx=host.service("nginx")assertnginx.is_runningassertnginx.is_enabledAnd run it:$ py.test -v test_myinfra.py


====================== test session starts ======================
platform linux -- Python 2.7.3 -- py-1.4.26 -- pytest-2.6.4
plugins: testinfra
collected 3 items

test_myinfra.py::test_passwd_file[local] PASSED
test_myinfra.py::test_nginx_is_installed[local] PASSED
test_myinfra.py::test_nginx_running_and_enabled[local] PASSED

=================== 3 passed in 0.66 seconds ====================
Package: pytest-testinfra-winrm-transport
Latest documentation:https://testinfra.readthedocs.io/en/latestAboutWith Testinfra you can write unit tests in Python to testactual stateof
your servers configured by management tools likeSalt,Ansible,Puppet,Chefand so on.Testinfra aims to be aServerspecequivalent in python and is written as
a plugin to the powerfulPytesttest engineLicenseApache License 2.0The logo is licensed under theCreative Commons NoDerivatives 4.0 LicenseIf you have some other use in mind, contact us.Quick startInstall testinfra using pip:$ pip install pytest-testinfra

# or install the devel version
$ pip install 'git+https://github.com/pytest-dev/pytest-testinfra@main#egg=pytest-testinfra'Write your first tests file totest_myinfra.py:deftest_passwd_file(host):passwd=host.file("/etc/passwd")assertpasswd.contains("root")assertpasswd.user=="root"assertpasswd.group=="root"assertpasswd.mode==0o644deftest_nginx_is_installed(host):nginx=host.package("nginx")assertnginx.is_installedassertnginx.version.startswith("1.2")deftest_nginx_running_and_enabled(host):nginx=host.service("nginx")assertnginx.is_runningassertnginx.is_enabledAnd run it:$ py.test -v test_myinfra.py


====================== test session starts ======================
platform linux -- Python 2.7.3 -- py-1.4.26 -- pytest-2.6.4
plugins: testinfra
collected 3 items

test_myinfra.py::test_passwd_file[local] PASSED
test_myinfra.py::test_nginx_is_installed[local] PASSED
test_myinfra.py::test_nginx_running_and_enabled[local] PASSED

=================== 3 passed in 0.66 seconds ====================
Package: pytest-testmon
This is a pytest plug-in which automatically selects and re-executes
only tests affected by recent changes. How is this possible in dynamic
language like Python and how reliable is it? Read here:Determining
affected testsQuickstartpip install pytest-testmon

# build the dependency database and save it to .testmondata
pytest --testmon

# change some of your code (with test coverage)

# only run tests affected by recent changes
pytest --testmonTo learn more about different options you can use with testmon, please
head totestmon.orgCall for opensource projects: try testmon in CI with no effort or risk.We would like to run testmon within your project, collect data and improve!
We'll prepare the PR for you and set everything up so that no tests are deselected initially.
You can start using the full functionality whenever the reliability and time savings seem right!
PleaseSIGN UPand we'll contact you shortly.
Package: pytest-testmon-oc
Testmon OCThis is a pytest plug-in fork fromtestmon.
Testmon OC only tests affected by recent changes.
Not re-run for test failed before.Quickstartpip install pytest-testmon

# build the dependency database and save it to .testmondata
pytest --testmon

# change some of your code (with test coverage)

# only run tests affected by recent changes
pytest --testmonTo learn more about different options you can use with testmon, please
head totestmon.org
Package: pytest-testmon-skip-libraries
Testmon-skip-libariesThis is a fork of pytest-testmon that adds functionality to ignore changes to
libraries used by the code. The standard version of pytest-testmon looks not
only at the python code for changes, but also versions of dependencies. This
makes it unsuitable for sharing among developers (who may have a different local
set of dependencies), or CI/CD systems where your local, staging and production
environments may differ in the number and versions of dependencies used.From the original repo:This is a pytest plug-in which automatically selects and re-executes
only tests affected by recent changes. How is this possible in dynamic
language like Python and how reliable is it? Read here:Determining
affected testsQuickstartpip install pytest-testmon-skip-libraries

# build the dependency database and save it to .testmondata
pytest --testmon

# change some of your code (with test coverage)

# only run tests affected by recent changes
pytest --testmon

# only run tests affected by recent changes while ignoring changes
# to any libraries used by the code
pytest --testmon --skip-librariesTo learn more about different options you can use with testmon, please
head totestmon.org
Package: pytest-testobject
Plugin to use TestObject Suites with PytestThisPytestplugin was generated withCookiecutteralong with@hackebrot’sCookiecutter-pytest-plugintemplate.FeaturesUse TestObject’s Suites feature to group types of tests.Run tests with different iOS and Android devices without re-writing codeRequirementsSeerequirements.txtTo run from source install via:$ pip install -r requirements.txtInstallationYou can install “pytest-testobject” viapipfromPyPI$ pip install pytest-testobjectUsageAdd your credentials via the following flags:--to-username=TO_USERNAME
--to-api-key=TO_API_KEY
--to-suite-id=TO_SUITE_IDFor these to work your tests need to be on a class.Add the fixtures to_suite and to_driver to your class.
Then use the to_driver fixture on your tests as your driver instance.So it’ll look something like this:@pytest.mark.usefixtures("to_suite","to_driver")classTestTODriver(object):deftest_saucelabs(self,to_driver):#Do stuff like to_driver.get(...)ContributingContributions are very welcome. Tests can be run withtox, please ensure
the coverage at least stays the same before you submit a pull request.LicenseDistributed under the terms of theMITlicense, “pytest-testobject” is free and open source softwareIssuesIf you encounter any problems, pleasefile an issuealong with a detailed description.
Package: pytest-testrail-api-client
testrail-api-clienttestrail-api-client - is a client for provide integration with TestRailGeneral information aboutTestRail ApiRequirementsrequestspytestgherkin-officialpytest-bddInstallationpipinstallpytest-testrail-api-clientConfigurationStarting from version 0.3 you can configure testrail client credentials with 3 way:Way 1. Directly set credentials in class constructorfrompytest_testrail_api_client.test_railimportTestRailtest_rail=TestRail('your_host','your_username','your_token')Way 2. Set credentials in pytest.ini or in test_rail.ini This files must be in root folder project path Add
group [pytest]
Add variables:testrail-emailtestrail-keytestrail-urlExamplepytest.iniortest_rail.ini[saucelab]testrail-email=your_email
testrail-key=your_token
testrail-url=your_hostWhen you add credentials to ini file:frompytest_testrail_api_client.test_railimportTestRailtest_rail=TestRail()Way 3. You can set environment variables:TESTRAIL_EMAILTESTRAIL_KEYTESTRAIL_URLWhen you add credentials to environment variables:frompytest_testrail_api_client.test_railimportTestRailtest_rail=TestRail()Features in version: 0.3.1Access to TestRail ApiExport feature files to TestRail (use pytest --pytest_testrail_export_test_cases
--pytest-testrail-feature-files-relative-path "%RELATIVE_PATH%")Export tests results to TestRail (use pytest --pytest-testrail-export-test-results --pytest-testrail-test-plan-id
%PLAN_ID% --pytest-testrail-test-configuration-name %CONFIGURATION%)Scenarios validation (please, see pytest_testrail_api_client/client_config.py)Tags replacing (for example: you have automation status "To Be Automated" and you use tag "to_automate" if feactures
you can set it in variable REPLACE_TAGS - it will bind these tags)Priority replace: variable PRIORITY_REPLACEUsage examplesfrompytest_testrail_api_client.test_railimportTestRailtest_rail=TestRail()case=test_rail.cases.get_case(1)
Package: pytest-testrail-client
pytest-testrail-client is a plugin forpytestthat provides integration of pytest and pytest-bdd with TestRailIt provides capabilities of exporting Test Cases and Test Results to TestRailTable of ContentsRequirementsInstallationFeatures and UsageTestRail ConfigurationExport Test Cases to TestRailImplementation detailsExport Tests to TestRailImplementation detailsResourcesRequirementsFollowing prerequisites are needed in order to use pytest-testrail-client:cucumber-tag-expressions >= 2.0.0gherkin-official >= 4.1.0pytest >= 4.2pytest-bdd >= 3.3.0requestsInstallationTo install pytest-testrail-client:pip install pytest-testrail-clientFeatures and UsageTestRail Configurationpytest-testrail-client configuration data can be provided in three different ways:By using Environment Variables:TESTRAIL_URL=[URL of TestRail instance]
TESTRAIL_EMAIL= [email [of user to be used for communication]]
TESTRAIL_KEY=key [of user to be used for communication]
TESTRAIL_PROJECT_ID=[project id to which the data is sent]
JIRA_PROJECT_KEY=[Jira project key for integration with Jira]By using command line arguments:--pytest-testrail-client True / False
--testrail-url [URL of TestRail instance]
--testrail-email [email [of user to be used for communication]]
--testrail-key key [of user to be used for communication]
--testrail-project-id [project id to which the data is sent]
--jira-project-key [Jira project key for integration with Jira]By usingpytest.inifile:[pytest-testrail-client]
pytest-testrail-client = True / False
testrail-url = [URL of TestRail instance]
testrail-email = [email [of user to be used for communication]]
testrail-key = key [of user to be used for communication]
testrail-project-id = [project id to which the data is sent]
jira-project-key = [Jira project key for integration with Jira]Note:
- Please follow TestRail instructions for generatinguser_key- Jira integration is done withTestRail for Jira Test Management- TestRail Project type shall beMultiple Test Suites to manage casesExport Test Cases to TestRailpython -m pytest -v --pytest-testrail-export-test-cases --pytest-testrail-feature-files-relative-path "features"Read more aboutTestRailTest Suites and CasesImplementation detailsTODOExport Tests to TestRailpython -m pytest ./tests -v --pytest-testrail-export-test-results --pytest-testrail-test-plan-id [ID of Plan to be used] --pytest-testrail-test-configuration-name [str: Id of Test Configuration to be used]Read more aboutTestRailTest Plans and ConfigurationsImplementation detailsTODOResources