deadline-cloud-test-fixtures


Namedeadline-cloud-test-fixtures JSON
Version 0.17.0 PyPI version JSON
download
home_pageNone
SummaryThis package contains pytest fixtures that are used to test AWS Deadline Cloud Python packages.
upload_time2024-11-13 19:29:19
maintainerNone
docs_urlNone
authorAmazon Web Services
requires_python>=3.9
licenseApache-2.0
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # AWS Deadline Cloud Test Fixtures

[![pypi](https://img.shields.io/pypi/v/deadline-cloud-test-fixtures.svg?style=flat)](https://pypi.python.org/pypi/deadline-cloud-test-fixtures)
[![python](https://img.shields.io/pypi/pyversions/deadline-cloud-test-fixtures.svg?style=flat)](https://pypi.python.org/pypi/deadline-cloud-test-fixtures)
[![license](https://img.shields.io/pypi/l/deadline-cloud-test-fixtures.svg?style=flat)](https://github.com/aws-deadline/deadline-cloud-test-fixtures/blob/mainline/LICENSE)

This package contains pytest fixtures that are used to test AWS Deadline Cloud Python packages.

## Usage

To use this package:
1. Install it into your test environment
1. Configure environment variables needed for your tests (see [src/deadline_test_fixtures/example_config.sh](https://github.com/casillas2/deadline-cloud-test-fixtures/blob/mainline/src/deadline_test_fixtures/example_config.sh) for available options)
1. Use the fixtures in your tests (see [src/deadline_test_fixtures/fixtures.py](https://github.com/casillas2/deadline-cloud-test-fixtures/blob/mainline/src/deadline_test_fixtures/fixtures.py) for available fixtures)

For example, to use the `worker` fixture:

```py
from deadline_test_fixtures import DeadlineWorker

def test_something_with_the_worker(worker: DeadlineWorker) -> None:
    # GIVEN
    worker.start()

    # WHEN
    result = worker.send_command("some command")

    # THEN
    assert result.stdout == "expected output"
```

You can also import the classes from this package directly to build your own fixtures

```py
# double_worker.py
from deadline_test_fixtures import (
    DeadlineWorker,
    EC2InstanceWorker,
    DockerContainerWorker,
)

class DoubleWorker(DeadlineWorker):

    def __init__(
        self,
        # args...
    ) -> None:
        self.ec2_worker = EC2InstanceWorker(
            # args...
        )
        self.docker_worker = DockerContainerWorker(
            # args...
        )
    
    def start(self) -> None:
        self.ec2_worker.start()
        self.docker_worker.start()
    
    # etc.


# test_something.py
from .double_worker import DoubleWorker

import pytest

@pytest.fixture
def double_worker() -> DoubleWorker:
    return DoubleWorker(
        # args...
    )

def test_something(double_worker: DoubleWorker) -> None:
    # GIVEN
    double_worker.start()

    # etc.
```

## Telemetry

This library collects telemetry data by default. Telemetry events contain non-personally-identifiable information that helps us understand how users interact with our software so we know what features our customers use, and/or what existing pain points are.

You can opt out of telemetry data collection by either:

1. Setting the environment variable: `DEADLINE_CLOUD_TELEMETRY_OPT_OUT=true`
2. Setting the config file: `deadline config set telemetry.opt_out true`

Note that setting the environment variable supersedes the config file setting.

## Build / Test / Release

### Build the package.
```
hatch build
```

### Run tests
```
hatch run test
```

### Run linting
```
hatch run lint
```

### Run formating
```
hatch run fmt
```

### Run a tests for all supported Python versions.
```
hatch run all:test
```

## Compatibility

This library requires:

1. Python 3.9 or higher; and
2. Linux, MacOS, or Windows operating system.

## Versioning

This package's version follows [Semantic Versioning 2.0](https://semver.org/), but is still considered to be in its 
initial development, thus backwards incompatible versions are denoted by minor version bumps. To help illustrate how
versions will increment during this initial development stage, they are described below:

1. The MAJOR version is currently 0, indicating initial development. 
2. The MINOR version is currently incremented when backwards incompatible changes are introduced to the public API. 
3. The PATCH version is currently incremented when bug fixes or backwards compatible changes are introduced to the public API. 

## Downloading

You can download this package from:
- [GitHub releases](https://github.com/casillas2/deadline-cloud-test-fixtures/releases)

## Security

See [CONTRIBUTING](CONTRIBUTING.md#security-issue-notifications) for more information.

## License

This project is licensed under the Apache-2.0 License.


            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "deadline-cloud-test-fixtures",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": null,
    "keywords": null,
    "author": "Amazon Web Services",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/31/d1/9dd4e8be73ed417c986c5c6d8c63406f17c8c4e5126ec94e1d741edab928/deadline_cloud_test_fixtures-0.17.0.tar.gz",
    "platform": null,
    "description": "# AWS Deadline Cloud Test Fixtures\n\n[![pypi](https://img.shields.io/pypi/v/deadline-cloud-test-fixtures.svg?style=flat)](https://pypi.python.org/pypi/deadline-cloud-test-fixtures)\n[![python](https://img.shields.io/pypi/pyversions/deadline-cloud-test-fixtures.svg?style=flat)](https://pypi.python.org/pypi/deadline-cloud-test-fixtures)\n[![license](https://img.shields.io/pypi/l/deadline-cloud-test-fixtures.svg?style=flat)](https://github.com/aws-deadline/deadline-cloud-test-fixtures/blob/mainline/LICENSE)\n\nThis package contains pytest fixtures that are used to test AWS Deadline Cloud Python packages.\n\n## Usage\n\nTo use this package:\n1. Install it into your test environment\n1. Configure environment variables needed for your tests (see [src/deadline_test_fixtures/example_config.sh](https://github.com/casillas2/deadline-cloud-test-fixtures/blob/mainline/src/deadline_test_fixtures/example_config.sh) for available options)\n1. Use the fixtures in your tests (see [src/deadline_test_fixtures/fixtures.py](https://github.com/casillas2/deadline-cloud-test-fixtures/blob/mainline/src/deadline_test_fixtures/fixtures.py) for available fixtures)\n\nFor example, to use the `worker` fixture:\n\n```py\nfrom deadline_test_fixtures import DeadlineWorker\n\ndef test_something_with_the_worker(worker: DeadlineWorker) -> None:\n    # GIVEN\n    worker.start()\n\n    # WHEN\n    result = worker.send_command(\"some command\")\n\n    # THEN\n    assert result.stdout == \"expected output\"\n```\n\nYou can also import the classes from this package directly to build your own fixtures\n\n```py\n# double_worker.py\nfrom deadline_test_fixtures import (\n    DeadlineWorker,\n    EC2InstanceWorker,\n    DockerContainerWorker,\n)\n\nclass DoubleWorker(DeadlineWorker):\n\n    def __init__(\n        self,\n        # args...\n    ) -> None:\n        self.ec2_worker = EC2InstanceWorker(\n            # args...\n        )\n        self.docker_worker = DockerContainerWorker(\n            # args...\n        )\n    \n    def start(self) -> None:\n        self.ec2_worker.start()\n        self.docker_worker.start()\n    \n    # etc.\n\n\n# test_something.py\nfrom .double_worker import DoubleWorker\n\nimport pytest\n\n@pytest.fixture\ndef double_worker() -> DoubleWorker:\n    return DoubleWorker(\n        # args...\n    )\n\ndef test_something(double_worker: DoubleWorker) -> None:\n    # GIVEN\n    double_worker.start()\n\n    # etc.\n```\n\n## Telemetry\n\nThis library collects telemetry data by default. Telemetry events contain non-personally-identifiable information that helps us understand how users interact with our software so we know what features our customers use, and/or what existing pain points are.\n\nYou can opt out of telemetry data collection by either:\n\n1. Setting the environment variable: `DEADLINE_CLOUD_TELEMETRY_OPT_OUT=true`\n2. Setting the config file: `deadline config set telemetry.opt_out true`\n\nNote that setting the environment variable supersedes the config file setting.\n\n## Build / Test / Release\n\n### Build the package.\n```\nhatch build\n```\n\n### Run tests\n```\nhatch run test\n```\n\n### Run linting\n```\nhatch run lint\n```\n\n### Run formating\n```\nhatch run fmt\n```\n\n### Run a tests for all supported Python versions.\n```\nhatch run all:test\n```\n\n## Compatibility\n\nThis library requires:\n\n1. Python 3.9 or higher; and\n2. Linux, MacOS, or Windows operating system.\n\n## Versioning\n\nThis package's version follows [Semantic Versioning 2.0](https://semver.org/), but is still considered to be in its \ninitial development, thus backwards incompatible versions are denoted by minor version bumps. To help illustrate how\nversions will increment during this initial development stage, they are described below:\n\n1. The MAJOR version is currently 0, indicating initial development. \n2. The MINOR version is currently incremented when backwards incompatible changes are introduced to the public API. \n3. The PATCH version is currently incremented when bug fixes or backwards compatible changes are introduced to the public API. \n\n## Downloading\n\nYou can download this package from:\n- [GitHub releases](https://github.com/casillas2/deadline-cloud-test-fixtures/releases)\n\n## Security\n\nSee [CONTRIBUTING](CONTRIBUTING.md#security-issue-notifications) for more information.\n\n## License\n\nThis project is licensed under the Apache-2.0 License.\n\n",
    "bugtrack_url": null,
    "license": "Apache-2.0",
    "summary": "This package contains pytest fixtures that are used to test AWS Deadline Cloud Python packages.",
    "version": "0.17.0",
    "project_urls": {
        "Homepage": "https://github.com/aws-deadline/deadline-cloud-test-fixtures",
        "Source": "https://github.com/aws-deadline/deadline-cloud-test-fixtures"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "80517dfb37e5b32bd5ddc73779fe8bd7c3aa356590271779136fa9e3c9f290f8",
                "md5": "4dc6f75dc6ca89eba6b9ae39a19344b3",
                "sha256": "092a5489f46fc9b6d38b2368f9df43821f4abce4c92e743dfc32ad78e2950bcd"
            },
            "downloads": -1,
            "filename": "deadline_cloud_test_fixtures-0.17.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "4dc6f75dc6ca89eba6b9ae39a19344b3",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 53592,
            "upload_time": "2024-11-13T19:29:17",
            "upload_time_iso_8601": "2024-11-13T19:29:17.906206Z",
            "url": "https://files.pythonhosted.org/packages/80/51/7dfb37e5b32bd5ddc73779fe8bd7c3aa356590271779136fa9e3c9f290f8/deadline_cloud_test_fixtures-0.17.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "31d19dd4e8be73ed417c986c5c6d8c63406f17c8c4e5126ec94e1d741edab928",
                "md5": "a362d4a4bebdc0531827137e41834aa0",
                "sha256": "9bb6e76327423e2ccd89546559cc98b3a781ece06379f740296a2f2293a64289"
            },
            "downloads": -1,
            "filename": "deadline_cloud_test_fixtures-0.17.0.tar.gz",
            "has_sig": false,
            "md5_digest": "a362d4a4bebdc0531827137e41834aa0",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 46738,
            "upload_time": "2024-11-13T19:29:19",
            "upload_time_iso_8601": "2024-11-13T19:29:19.657702Z",
            "url": "https://files.pythonhosted.org/packages/31/d1/9dd4e8be73ed417c986c5c6d8c63406f17c8c4e5126ec94e1d741edab928/deadline_cloud_test_fixtures-0.17.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-11-13 19:29:19",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "aws-deadline",
    "github_project": "deadline-cloud-test-fixtures",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "deadline-cloud-test-fixtures"
}
        
Elapsed time: 0.48434s