Skip to main content

Create test set and post test results to PractiTest

Project description

PostTestResultsToPractiTest package

Config file requirements:

Need to create a file called userInputs.ini at the root of your project and add the following lines to the content of that file.  You'll need to update those values with your specific ones. 

    ```
    [UserInputs]
    PractiTestProjectName=<PractiTest's Project Name>
    PractiTestTestSetName_ToCloneFrom=<TestSetNameToCloneFrom>
    PractiTestTestSetName_New=<NewTestSetNameToBeCreated>
    PT_Token=<yourPractiTestToken>
    ```

This package makes use of PractiTest's APIs to do the following:

1. Use this package to clone test_set (test set needs to be created along with its instances before usage)

Example of how to use it (in Python):
```
    from PostTestResultsToPractiTest import Orchestrator
    Orchestrator.CreateTestSetProcess()
```

2. Use this package to post test results to the test_set created in step1.

Example of how to use it (in Python):
```
    from PostTestResultsToPractiTest import Orchestrator
    from PostTestResultsToPractiTest.EnumClass import TestResultStatus
    Orchestrator.PostToPractiTest("NameOfYourFeatureFileInBDD-including-extension-.feature", TestResultStatus.UNSTABLE, "Output message if any")
```
Note that TestResultStatus is an enum class, available values are TestResultStatus.PASS, estResultStatus.FAIL, and TestResultStatus.UNSTABLE

3. Use this package to create test set, fill with instances, and post results all within an automation run.

Example of how to use it (in Python):
```
    from PostTestResultsToPractiTest import Orchestrator
    customFields = {'---f-112372': 'Example'}
    testSetId = Orchestrator.CreateTestSetFromFeature(featureFileName, releaseVersion, customFields)
    testId = Orchestrator.RetrieveTestId(testName)
    instanceId = Orchestrator.CreateInstance(testSetId, testId)
    Orchestrator.PostToPractiTestWithFile(instanceId, passFailStatus, fileDir, fileName)
```
Note that passFailStatus is just a boolean value on whether the test passed or failed.
The variables fileDir and fileName are the directory and file name respectively for the file that you would like to attach
with your test results (logs, reports, etc.).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

posttestresultstopractitest-0.0.11.tar.gz (6.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

posttestresultstopractitest-0.0.11-py3-none-any.whl (12.0 kB view details)

Uploaded Python 3

File details

Details for the file posttestresultstopractitest-0.0.11.tar.gz.

File metadata

File hashes

Hashes for posttestresultstopractitest-0.0.11.tar.gz
Algorithm Hash digest
SHA256 12db79cb8b8277b1d424b4ac3360d7ad9a78a8c9328f7a6895551089dd1d3b9e
MD5 477cca1461d810ae7d1d5c3767bad95a
BLAKE2b-256 0e48ef17ac5b9b79255a56688578e3c0d13f0f5deb0839115b6e1e256c33752b

See more details on using hashes here.

File details

Details for the file posttestresultstopractitest-0.0.11-py3-none-any.whl.

File metadata

File hashes

Hashes for posttestresultstopractitest-0.0.11-py3-none-any.whl
Algorithm Hash digest
SHA256 e6250089e63420b3d6cf2dd72543b17d03e0b71f78835bd10eebe70d5bb71859
MD5 b0d9589a6c21ef422fa74b36586c4416
BLAKE2b-256 c07875042b78e19499ac61b59ca87d2ffffacdf133b7008a85d63fa78c80ce3d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page