Skip to content

Commit

Permalink
fix: requirements
Browse files Browse the repository at this point in the history
  • Loading branch information
koushik-kiran-kumar committed Jun 25, 2024
1 parent 12d99b1 commit 5cace02
Show file tree
Hide file tree
Showing 23 changed files with 34 additions and 35 deletions.
21 changes: 11 additions & 10 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -63,27 +63,28 @@ Install the required PIP packages with the command
## Executing

The test suite allows for overriding the target server and user parameters via the following arguments:

--url default="https://localhost"
--user default="admin"
--pass This is the password for the user defined above.
--skipverify This is for allowing the version of PyDriver to not match the version of Swimlane.
::
pytest
--url default="https://localhost"
--user default="admin"
--pass This is the password for the user defined above.
--skipverify This is for allowing the version of PyDriver to not match the version of Swimlane.

To run a specific test and skip the version verification:

pytest driver_tests/test_app_adaptor.py --skipverify
::
pytest driver_tests/test_app_adaptor.py --skipverify

To run all the tests against 10.20.30.40:

pytest --url "https://10.20.30.40"

::
pytest --url "https://10.20.30.40"

.. NOTE::
All of the data created for testing purposes is cleaned up.

No preset data is needed beyond the base user.

These tests are Python 2 and 3 compatible.
These tests are Python 3.6+ compatible.

Issues
------
Expand Down
5 changes: 2 additions & 3 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
cachetools==4.2.4; python_version == '3.6'
cachetools==5.3.3; python_version >= '3.7'
certifi>=2017
cachetools>=4.2.4
certifi>=20i7
pendulum>=2.1.2
pyjwt>=2.4.0
pyuri>=0.3,<0.4
Expand Down
3 changes: 1 addition & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ def parse_requirements(requirement_file):
author="Swimlane",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
python_requires=">=3.6",
packages=find_packages(exclude=('tests', 'tests.*')),
description="Python driver for the Swimlane API",
long_description=long_description,
Expand All @@ -29,8 +30,6 @@ def parse_requirements(requirement_file):
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 5 - Production/Stable",
"Programming Language :: Python",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
Expand Down
2 changes: 1 addition & 1 deletion tests/adapters/test_app_adapter.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import mock
import unittest.mock as mock
import pytest


Expand Down
2 changes: 1 addition & 1 deletion tests/adapters/test_app_revision_adapter.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import math

import mock
import unittest.mock as mock

from swimlane.core.resources.app_revision import AppRevision

Expand Down
2 changes: 1 addition & 1 deletion tests/adapters/test_helper_adapter.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import mock
import unittest.mock as mock

app_id = '123'
record_id = '456'
Expand Down
2 changes: 1 addition & 1 deletion tests/adapters/test_record_adapter.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import numbers

import mock
import unittest.mock as mock
import pytest
import six

Expand Down
2 changes: 1 addition & 1 deletion tests/adapters/test_record_revision_adapter.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import mock
import unittest.mock as mock

from swimlane.core.resources.record_revision import RecordRevision

Expand Down
2 changes: 1 addition & 1 deletion tests/adapters/test_report_adapter.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import mock
import unittest.mock as mock

from swimlane.core.resources.report import Report

Expand Down
2 changes: 1 addition & 1 deletion tests/adapters/test_task_adapter.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import json
import pytest
import mock
import unittest.mock as mock
from requests.models import Response
from swimlane.core.adapters import TaskAdapter
from swimlane.core.resources.task import Task
Expand Down
2 changes: 1 addition & 1 deletion tests/adapters/test_usergroup_adapters.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import mock
import unittest.mock as mock
import pytest

from swimlane.core.resources.usergroup import Group, User
Expand Down
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import json
from pathlib import Path
from shutil import copy as cp
import mock
import unittest.mock as mock
import pytest
from swimlane.core.client import SwimlaneJwtAuth, Swimlane
from swimlane.core.resources.app import App
Expand Down
2 changes: 1 addition & 1 deletion tests/fields/test_attachment.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from datetime import datetime
from io import BytesIO

import mock
import unittest.mock as mock
import pytest
from swimlane.core.fields.attachment import AttachmentCursor
from swimlane.core.resources.attachment import Attachment
Expand Down
2 changes: 1 addition & 1 deletion tests/fields/test_comment.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from datetime import datetime

import mock
import unittest.mock as mock

from swimlane.core.fields.comment import CommentCursor
from swimlane.core.resources.comment import Comment
Expand Down
2 changes: 1 addition & 1 deletion tests/fields/test_history.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import mock
import unittest.mock as mock
import pytest
import pendulum

Expand Down
2 changes: 1 addition & 1 deletion tests/fields/test_reference.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import mock
import unittest.mock as mock
import pytest

from swimlane.core.fields.reference import ReferenceCursor
Expand Down
2 changes: 1 addition & 1 deletion tests/resources/test_record.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import json
import pendulum
import mock
import unittest.mock as mock
import pytest
from requests import Response
from swimlane.core.fields.reference import ReferenceCursor
Expand Down
2 changes: 1 addition & 1 deletion tests/resources/test_record_revision.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import mock
import unittest.mock as mock
import pendulum
import pytest

Expand Down
2 changes: 1 addition & 1 deletion tests/resources/test_report.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import mock
import unittest.mock as mock
import pytest

from swimlane.core.resources.report import report_factory
Expand Down
2 changes: 1 addition & 1 deletion tests/resources/test_usergroups.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import pytest
from mock import patch
import mock
import unittest.mock as mock
import copy

from swimlane.core.cache import ResourcesCache
Expand Down
2 changes: 1 addition & 1 deletion tests/test_cache.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import copy

import mock
import unittest.mock as mock
import pytest

from swimlane.core.cache import ResourcesCache, check_cache
Expand Down
2 changes: 1 addition & 1 deletion tests/test_client.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
"""Tests for custom Swimlane errors"""
import mock
import unittest.mock as mock
import pytest
from requests import HTTPError

Expand Down
2 changes: 1 addition & 1 deletion tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import string
import sys

import mock
import unittest.mock as mock
import pytest
from pkg_resources import DistributionNotFound

Expand Down

0 comments on commit 5cace02

Please sign in to comment.