Skip to content

Commit 15c9145

Browse files
authored
test: run tests with python 3.9 & 3.10 - DIA-48104 (#71)
1 parent 5001491 commit 15c9145

1 file changed

Lines changed: 18 additions & 6 deletions

File tree

.circleci/config.yml

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ workflows:
2727
context: gemfury-download
2828
matrix:
2929
parameters:
30+
python_version: ["3.9", "3.10"]
3031
sqlalchemy_version: ["1.3", "1.4"]
3132
asyncpg: ["asyncpg", "noasyncpg"]
3233
aws_rds_iam: ["aws_rds_iam", "noaws_rds_iam"]
@@ -57,8 +58,13 @@ jobs:
5758

5859
test:
5960
environment:
60-
CACHE_VERSION: "2021-05-02T10:18:17.640582"
61+
CACHE_VERSION: "2022-11-15T12:56:00.000000"
6162
parameters:
63+
python_version:
64+
type: enum
65+
enum: ["3.9", "3.10"]
66+
description: |
67+
Specify which version of python to run the tests against
6268
sqlalchemy_version:
6369
type: enum
6470
enum: ["1.4", "1.3"]
@@ -72,13 +78,15 @@ jobs:
7278
type: enum
7379
enum: ["aws_rds_iam", "noaws_rds_iam"]
7480
description: To run tests with and without asyncpg installed.
75-
executor: python-postgres
81+
executor:
82+
name: python-postgres
83+
python_version: <<parameters.python_version>>
7684
working_directory: ~/project/.
7785
steps:
7886
- base/setup
7987
- python/setup
8088
- utils/with_cache:
81-
key: 'sqlalchemy<<parameters.sqlalchemy_version>>-<<parameters.asyncpg>>-<<parameters.aws_rds_iam>>-{{ checksum "pyproject.toml" }}-{{ checksum "poetry.lock" }}'
89+
key: 'python<<parameters.python_version>>-sqlalchemy<<parameters.sqlalchemy_version>>-<<parameters.asyncpg>>-<<parameters.aws_rds_iam>>-{{ checksum "pyproject.toml" }}-{{ checksum "poetry.lock" }}'
8290
namespace: tox
8391
path: ~/project/.tox
8492
steps:
@@ -93,11 +101,11 @@ jobs:
93101
- store_test_results:
94102
path: test-reports
95103
- utils/send_coverage_to_codecov:
96-
codecov_flag: sqlalchemy<<parameters.sqlalchemy_version>>-<<parameters.asyncpg>>-<<parameters.aws_rds_iam>>
104+
codecov_flag: python_version<<parameters.python_version>>-sqlalchemy<<parameters.sqlalchemy_version>>-<<parameters.asyncpg>>-<<parameters.aws_rds_iam>>
97105

98106
publish:
99107
docker:
100-
- image: cimg/python:3.9
108+
- image: cimg/python:latest
101109
auth:
102110
username: $DOCKERHUB_USER
103111
password: $DOCKERHUB_ACCESS_TOKEN
@@ -116,8 +124,12 @@ executors:
116124
docker:
117125
- image: cimg/python:3.10
118126
python-postgres:
127+
parameters:
128+
python_version:
129+
type: string
130+
default: "3.10"
119131
docker:
120-
- image: cimg/python:3.10
132+
- image: cimg/python:<< parameters.python_version >>
121133
- image: postgres:14.4
122134
name: postgres
123135
environment:

0 commit comments

Comments
 (0)