File tree Expand file tree Collapse file tree 3 files changed +81
-18
lines changed Expand file tree Collapse file tree 3 files changed +81
-18
lines changed Original file line number Diff line number Diff line change 1+ name : " Test"
2+
3+ on :
4+ push :
5+ branches :
6+ - " main"
7+ paths :
8+ # Always run when workflow configs change
9+ - " .github/workflows/**"
10+ # Run when package changes
11+ - " **"
12+ release :
13+ types : [published]
14+
15+ pull_request :
16+ branches :
17+ - " main"
18+ paths :
19+ # Always run when workflow configs change
20+ - " .github/workflows/**"
21+ # Run when package changes
22+ - " **"
23+
24+ workflow_dispatch : {}
25+
26+ jobs :
27+ test_client :
28+ runs-on : ubuntu-latest
29+
30+ permissions :
31+ contents : read
32+ id-token : write
33+
34+ strategy :
35+ matrix :
36+ python-version :
37+ - 3.9
38+
39+ steps :
40+ - uses : actions/checkout@v4
41+
42+ - uses : actions/setup-python@v4
43+ id : setup_python
44+ with :
45+ python-version : ${{ matrix.python-version }}
46+ cache : " pip"
47+ cache-dependency-path : |
48+ poetry.lock
49+
50+ - name : Install dependencies (tests)
51+ run : |
52+ pip install pytest pytest-asyncio pytest-mock requests-mock
53+
54+ - name : Install dependencies
55+ working-directory : .
56+ run : |
57+ pip install -e .
58+
59+ - name : Run tests
60+ working-directory : .
61+ run : |
62+ echo $COHERE_API_KEY
63+ pytest -sv tests/test_compass_client.py
64+ pypi-publish :
65+ if : github.event_name == 'push' && contains(github.ref, 'refs/tags/')
66+ runs-on : ubuntu-latest
67+ needs :
68+ - test_client
69+ permissions :
70+ id-token : write
71+
72+ steps :
73+ - name : Retrieve release distributions
74+ uses : actions/download-artifact@v4
75+ with :
76+ name : release-dists
77+ path : dist/
78+ - name : Publish release distributions to PyPI
79+ uses : pypa/gh-action-pypi-publish@3e4f5a6b7c8d9e0f1a2b3c4d5e6f7a8b9c0d1e2f
Original file line number Diff line number Diff line change 1- name : " Test and Publish "
1+ name : " Test"
22
33on :
44 push :
6161 run : |
6262 echo $COHERE_API_KEY
6363 pytest -sv tests/test_compass_client.py
64- pypi-publish :
65- if : github.event_name == 'push' && contains(github.ref, 'refs/tags/')
66- runs-on : ubuntu-latest
67- needs :
68- - test_client
69- permissions :
70- id-token : write
71-
72- steps :
73- - name : Retrieve release distributions
74- uses : actions/download-artifact@v4
75- with :
76- name : release-dists
77- path : dist/
78- - name : Publish release distributions to PyPI
79- uses : pypa/gh-action-pypi-publish@3e4f5a6b7c8d9e0f1a2b3c4d5e6f7a8b9c0d1e2f
Original file line number Diff line number Diff line change 11[tool .poetry ]
22name = " compass-sdk"
3- version = " release.narwhal "
3+ version = " 0.0.1 "
44authors = []
55description = " Compass SDK"
66
You can’t perform that action at this time.
0 commit comments