Skip to content

Commit f1155b8

Browse files
Add .circleci/config.yml
1 parent bb011f2 commit f1155b8

1 file changed

Lines changed: 45 additions & 0 deletions

File tree

.circleci/config.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Use the latest 2.1 version of CircleCI pipeline process engine.
2+
# See: https://circleci.com/docs/configuration-reference
3+
4+
# For a detailed guide to building and testing with Python, read the docs:
5+
# https://circleci.com/docs/language-python/ for more details
6+
version: 2.1
7+
8+
# Orbs are reusable packages of CircleCI configuration that you may share across projects, enabling you to create encapsulated, parameterized commands, jobs, and executors that can be used across multiple projects.
9+
# See: https://circleci.com/docs/orb-intro/
10+
orbs:
11+
# See the Python orb documentation here: https://circleci.com/developer/orbs/orb/circleci/python
12+
python: circleci/python@2.1.1
13+
14+
# Define a job to be invoked later in a workflow.
15+
# See: https://circleci.com/docs/jobs-steps/#jobs-overview & https://circleci.com/docs/configuration-reference/#jobs
16+
jobs:
17+
build-and-test:
18+
# Specify the execution environment. You can specify an image from Docker Hub or use one of our convenience images from CircleCI's Developer Hub.
19+
# See: https://circleci.com/docs/executor-intro/ & https://circleci.com/docs/configuration-reference/#executor-job
20+
docker:
21+
# Specify the version you desire here
22+
# See:https://circleci.com/developer/images/image/cimg/python
23+
- image: cimg/python:3.12
24+
25+
# Add steps to the job
26+
# See: https://circleci.com/docs/jobs-steps/#steps-overview & https://circleci.com/docs/configuration-reference/#steps
27+
steps:
28+
# Checkout the code as the first step.
29+
- checkout
30+
- python/install-packages:
31+
pkg-manager: pip
32+
# app-dir: ~/project/package-directory/ # If your requirements.txt isn't in the root directory.
33+
# pip-dependency-file: test-requirements.txt # if you have a different name for your requirements file, maybe one that combines your runtime and test requirements.
34+
- run:
35+
name: Run tests
36+
# This assumes pytest is installed via the install-package step above
37+
command: pytest
38+
39+
# Orchestrate jobs using workflows
40+
# See: https://circleci.com/docs/workflows/ & https://circleci.com/docs/configuration-reference/#workflows
41+
workflows:
42+
sample: # This is the name of the workflow, feel free to change it to better match your workflow.
43+
# Inside the workflow, you define the jobs you want to run.
44+
jobs:
45+
- build-and-test

0 commit comments

Comments
 (0)