Skip to content

Commit ecd99f1

Browse files
committed
separate out github action main vs ci to prevent exfiltration
1 parent 304b1af commit ecd99f1

File tree

2 files changed

+50
-6
lines changed

2 files changed

+50
-6
lines changed

.github/workflows/ci-main.yml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: CI Main Branch With Integration
2+
3+
on:
4+
push:
5+
branches: [main]
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
11+
strategy:
12+
matrix:
13+
python-version: [3.9, "3.10", 3.11, 3.12, 3.13]
14+
15+
steps:
16+
- uses: actions/checkout@v3
17+
18+
- name: Set up Python ${{ matrix.python-version }}
19+
uses: actions/setup-python@v4
20+
with:
21+
python-version: ${{ matrix.python-version }}
22+
23+
- name: Install Poetry
24+
run: curl -sSL https://install.python-poetry.org | python3 -
25+
26+
- name: Configure Poetry to create virtualenvs in project root
27+
run: poetry config virtualenvs.in-project true
28+
29+
- name: Install dependencies
30+
run: poetry install --no-root
31+
32+
- name: Type check with mypy
33+
run: poetry run mypy proxyproviders
34+
35+
- name: Run unit tests with coverage
36+
env:
37+
RUN_INTEGRATION_TESTS: 1
38+
WEBSHARE_API_KEY: ${{ secrets.WEBSHARE_API_KEY }}
39+
run: |
40+
poetry run coverage run -m pytest
41+
poetry run coverage report --fail-under=95
42+
poetry run coverage xml
43+
44+
- name: Upload coverage reports to Codecov
45+
uses: codecov/codecov-action@v5
46+
with:
47+
token: ${{ secrets.CODECOV_TOKEN }}
48+
slug: davidteather/proxyproviders
49+
files: ./coverage.xml

.github/workflows/ci.yml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
name: CI
22

33
on:
4-
push:
5-
branches: [main]
64
pull_request:
75
branches: [main]
86

@@ -34,10 +32,7 @@ jobs:
3432
- name: Type check with mypy
3533
run: poetry run mypy proxyproviders
3634

37-
- name: Run tests with coverage
38-
env:
39-
RUN_INTEGRATION_TESTS: 1
40-
WEBSHARE_API_KEY: ${{ secrets.WEBSHARE_API_KEY }}
35+
- name: Run unit tests with coverage
4136
run: |
4237
poetry run coverage run -m pytest
4338
poetry run coverage report --fail-under=95

0 commit comments

Comments
 (0)