T145 commited on
Commit
dc134b9
Β·
1 Parent(s): 9087bbc

Added testing

Browse files
Files changed (3) hide show
  1. pixi.lock +38 -0
  2. pixi.toml +1 -0
  3. test_scoring.py +11 -0
pixi.lock CHANGED
@@ -74,6 +74,7 @@ environments:
74
  - pypi: https://files.pythonhosted.org/packages/95/04/ff642e65ad6b90db43e668d70ffb6736436c7ce41fcc549f4e9472234127/h11-0.14.0-py3-none-any.whl
75
  - pypi: https://files.pythonhosted.org/packages/87/f5/72347bc88306acb359581ac4d52f23c0ef445b57157adedb9aee0cd689d2/httpcore-1.0.7-py3-none-any.whl
76
  - pypi: https://files.pythonhosted.org/packages/8f/fb/a19866137577ba60c6d8b69498dc36be479b13ba454f691348ddf428f185/httpx-0.28.0-py3-none-any.whl
 
77
  - pypi: https://files.pythonhosted.org/packages/04/96/92447566d16df59b2a776c0fb82dbc4d9e07cd95062562af01e408583fc4/itsdangerous-2.2.0-py3-none-any.whl
78
  - pypi: https://files.pythonhosted.org/packages/31/80/3a54838c3fb461f6fec263ebf3a3a41771bd05190238de3486aae8540c36/jinja2-3.1.4-py3-none-any.whl
79
  - pypi: https://files.pythonhosted.org/packages/42/d7/1ec15b46af6af88f19b8e5ffea08fa375d433c998b8a7639e76935c14f1f/markdown_it_py-3.0.0-py3-none-any.whl
@@ -87,6 +88,7 @@ environments:
87
  - pypi: https://files.pythonhosted.org/packages/29/d4/1244ab8edf173a10fd601f7e13b9566c1b525c4f365d6bee918e68381889/pandas-2.2.3-cp312-cp312-win_amd64.whl
88
  - pypi: https://files.pythonhosted.org/packages/d3/5e/76a9d08b4b4e4583f269cb9f64de267f9aeae0dacef23307f53a14211716/pathvalidate-3.2.1-py3-none-any.whl
89
  - pypi: https://files.pythonhosted.org/packages/57/97/73f756c338c1d86bb802ee88c3cab015ad7ce4b838f8a24f16b676b1ac7c/pillow-11.0.0-cp312-cp312-win_amd64.whl
 
90
  - pypi: https://files.pythonhosted.org/packages/3b/77/a92c3ef994e47180862b9d7d11e37624fb1c00a16d61faf55115d970628b/propcache-0.2.1-cp312-cp312-win_amd64.whl
91
  - pypi: https://files.pythonhosted.org/packages/76/52/f8da04195000099d394012b8d42c503d7041b79f778d854f410e5f05049a/pyarrow-18.1.0-cp312-cp312-win_amd64.whl
92
  - pypi: https://files.pythonhosted.org/packages/d5/74/da832196702d0c56eb86b75bfa346db9238617e29b0b7ee3b8b4eccfe654/pydantic-2.10.2-py3-none-any.whl
@@ -94,6 +96,7 @@ environments:
94
  - pypi: https://files.pythonhosted.org/packages/a6/53/d78dc063216e62fc55f6b2eebb447f6a4b0a59f55c8406376f76bf959b08/pydub-0.25.1-py2.py3-none-any.whl
95
  - pypi: https://files.pythonhosted.org/packages/f7/3f/01c8b82017c199075f8f788d0d906b9ffbbc5a47dc9918a945e13d5a2bda/pygments-2.18.0-py3-none-any.whl
96
  - pypi: https://files.pythonhosted.org/packages/06/74/b39b823ee7dba155b117634e62733a0dfdfe5aa100a553b435062cee2062/pytablewriter-1.2.0-py3-none-any.whl
 
97
  - pypi: https://files.pythonhosted.org/packages/ec/57/56b9bcc3c9c6a792fcbaf139543cee77261f3651ca9da0c93f5c1221264b/python_dateutil-2.9.0.post0-py2.py3-none-any.whl
98
  - pypi: https://files.pythonhosted.org/packages/f5/0b/c316262244abea7481f95f1e91d7575f3dfcf6455d56d1ffe9839c582eb1/python_multipart-0.0.12-py3-none-any.whl
99
  - pypi: https://files.pythonhosted.org/packages/11/c3/005fcca25ce078d2cc29fd559379817424e94885510568bc1bc53d7d5846/pytz-2024.2-py2.py3-none-any.whl
@@ -748,6 +751,11 @@ packages:
748
  - pkg:pypi/idna?source=hash-mapping
749
  size: 49837
750
  timestamp: 1726459583613
 
 
 
 
 
751
  - pypi: https://files.pythonhosted.org/packages/04/96/92447566d16df59b2a776c0fb82dbc4d9e07cd95062562af01e408583fc4/itsdangerous-2.2.0-py3-none-any.whl
752
  name: itsdangerous
753
  version: 2.2.0
@@ -1043,6 +1051,16 @@ packages:
1043
  - typing-extensions ; python_full_version < '3.10' and extra == 'typing'
1044
  - defusedxml ; extra == 'xmp'
1045
  requires_python: '>=3.9'
 
 
 
 
 
 
 
 
 
 
1046
  - pypi: https://files.pythonhosted.org/packages/3b/77/a92c3ef994e47180862b9d7d11e37624fb1c00a16d61faf55115d970628b/propcache-0.2.1-cp312-cp312-win_amd64.whl
1047
  name: propcache
1048
  version: 0.2.1
@@ -1185,6 +1203,26 @@ packages:
1185
  - toml>=0.9.3,<1 ; extra == 'toml'
1186
  - pyyaml>=3.11,<7 ; extra == 'yaml'
1187
  requires_python: '>=3.7'
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1188
  - conda: https://conda.anaconda.org/conda-forge/win-64/python-3.12.7-hce54a09_0_cpython.conda
1189
  sha256: 2308cfa9ec563360d29ced7fd13a6b60b9a7b3cf8961a95c78c69f486211d018
1190
  md5: 21f1f7c6ccf6b747c5086d2422c230e1
 
74
  - pypi: https://files.pythonhosted.org/packages/95/04/ff642e65ad6b90db43e668d70ffb6736436c7ce41fcc549f4e9472234127/h11-0.14.0-py3-none-any.whl
75
  - pypi: https://files.pythonhosted.org/packages/87/f5/72347bc88306acb359581ac4d52f23c0ef445b57157adedb9aee0cd689d2/httpcore-1.0.7-py3-none-any.whl
76
  - pypi: https://files.pythonhosted.org/packages/8f/fb/a19866137577ba60c6d8b69498dc36be479b13ba454f691348ddf428f185/httpx-0.28.0-py3-none-any.whl
77
+ - pypi: https://files.pythonhosted.org/packages/ef/a6/62565a6e1cf69e10f5727360368e451d4b7f58beeac6173dc9db836a5b46/iniconfig-2.0.0-py3-none-any.whl
78
  - pypi: https://files.pythonhosted.org/packages/04/96/92447566d16df59b2a776c0fb82dbc4d9e07cd95062562af01e408583fc4/itsdangerous-2.2.0-py3-none-any.whl
79
  - pypi: https://files.pythonhosted.org/packages/31/80/3a54838c3fb461f6fec263ebf3a3a41771bd05190238de3486aae8540c36/jinja2-3.1.4-py3-none-any.whl
80
  - pypi: https://files.pythonhosted.org/packages/42/d7/1ec15b46af6af88f19b8e5ffea08fa375d433c998b8a7639e76935c14f1f/markdown_it_py-3.0.0-py3-none-any.whl
 
88
  - pypi: https://files.pythonhosted.org/packages/29/d4/1244ab8edf173a10fd601f7e13b9566c1b525c4f365d6bee918e68381889/pandas-2.2.3-cp312-cp312-win_amd64.whl
89
  - pypi: https://files.pythonhosted.org/packages/d3/5e/76a9d08b4b4e4583f269cb9f64de267f9aeae0dacef23307f53a14211716/pathvalidate-3.2.1-py3-none-any.whl
90
  - pypi: https://files.pythonhosted.org/packages/57/97/73f756c338c1d86bb802ee88c3cab015ad7ce4b838f8a24f16b676b1ac7c/pillow-11.0.0-cp312-cp312-win_amd64.whl
91
+ - pypi: https://files.pythonhosted.org/packages/88/5f/e351af9a41f866ac3f1fac4ca0613908d9a41741cfcf2228f4ad853b697d/pluggy-1.5.0-py3-none-any.whl
92
  - pypi: https://files.pythonhosted.org/packages/3b/77/a92c3ef994e47180862b9d7d11e37624fb1c00a16d61faf55115d970628b/propcache-0.2.1-cp312-cp312-win_amd64.whl
93
  - pypi: https://files.pythonhosted.org/packages/76/52/f8da04195000099d394012b8d42c503d7041b79f778d854f410e5f05049a/pyarrow-18.1.0-cp312-cp312-win_amd64.whl
94
  - pypi: https://files.pythonhosted.org/packages/d5/74/da832196702d0c56eb86b75bfa346db9238617e29b0b7ee3b8b4eccfe654/pydantic-2.10.2-py3-none-any.whl
 
96
  - pypi: https://files.pythonhosted.org/packages/a6/53/d78dc063216e62fc55f6b2eebb447f6a4b0a59f55c8406376f76bf959b08/pydub-0.25.1-py2.py3-none-any.whl
97
  - pypi: https://files.pythonhosted.org/packages/f7/3f/01c8b82017c199075f8f788d0d906b9ffbbc5a47dc9918a945e13d5a2bda/pygments-2.18.0-py3-none-any.whl
98
  - pypi: https://files.pythonhosted.org/packages/06/74/b39b823ee7dba155b117634e62733a0dfdfe5aa100a553b435062cee2062/pytablewriter-1.2.0-py3-none-any.whl
99
+ - pypi: https://files.pythonhosted.org/packages/11/92/76a1c94d3afee238333bc0a42b82935dd8f9cf8ce9e336ff87ee14d9e1cf/pytest-8.3.4-py3-none-any.whl
100
  - pypi: https://files.pythonhosted.org/packages/ec/57/56b9bcc3c9c6a792fcbaf139543cee77261f3651ca9da0c93f5c1221264b/python_dateutil-2.9.0.post0-py2.py3-none-any.whl
101
  - pypi: https://files.pythonhosted.org/packages/f5/0b/c316262244abea7481f95f1e91d7575f3dfcf6455d56d1ffe9839c582eb1/python_multipart-0.0.12-py3-none-any.whl
102
  - pypi: https://files.pythonhosted.org/packages/11/c3/005fcca25ce078d2cc29fd559379817424e94885510568bc1bc53d7d5846/pytz-2024.2-py2.py3-none-any.whl
 
751
  - pkg:pypi/idna?source=hash-mapping
752
  size: 49837
753
  timestamp: 1726459583613
754
+ - pypi: https://files.pythonhosted.org/packages/ef/a6/62565a6e1cf69e10f5727360368e451d4b7f58beeac6173dc9db836a5b46/iniconfig-2.0.0-py3-none-any.whl
755
+ name: iniconfig
756
+ version: 2.0.0
757
+ sha256: b6a85871a79d2e3b22d2d1b94ac2824226a63c6b741c88f7ae975f18b6778374
758
+ requires_python: '>=3.7'
759
  - pypi: https://files.pythonhosted.org/packages/04/96/92447566d16df59b2a776c0fb82dbc4d9e07cd95062562af01e408583fc4/itsdangerous-2.2.0-py3-none-any.whl
760
  name: itsdangerous
761
  version: 2.2.0
 
1051
  - typing-extensions ; python_full_version < '3.10' and extra == 'typing'
1052
  - defusedxml ; extra == 'xmp'
1053
  requires_python: '>=3.9'
1054
+ - pypi: https://files.pythonhosted.org/packages/88/5f/e351af9a41f866ac3f1fac4ca0613908d9a41741cfcf2228f4ad853b697d/pluggy-1.5.0-py3-none-any.whl
1055
+ name: pluggy
1056
+ version: 1.5.0
1057
+ sha256: 44e1ad92c8ca002de6377e165f3e0f1be63266ab4d554740532335b9d75ea669
1058
+ requires_dist:
1059
+ - pre-commit ; extra == 'dev'
1060
+ - tox ; extra == 'dev'
1061
+ - pytest ; extra == 'testing'
1062
+ - pytest-benchmark ; extra == 'testing'
1063
+ requires_python: '>=3.8'
1064
  - pypi: https://files.pythonhosted.org/packages/3b/77/a92c3ef994e47180862b9d7d11e37624fb1c00a16d61faf55115d970628b/propcache-0.2.1-cp312-cp312-win_amd64.whl
1065
  name: propcache
1066
  version: 0.2.1
 
1203
  - toml>=0.9.3,<1 ; extra == 'toml'
1204
  - pyyaml>=3.11,<7 ; extra == 'yaml'
1205
  requires_python: '>=3.7'
1206
+ - pypi: https://files.pythonhosted.org/packages/11/92/76a1c94d3afee238333bc0a42b82935dd8f9cf8ce9e336ff87ee14d9e1cf/pytest-8.3.4-py3-none-any.whl
1207
+ name: pytest
1208
+ version: 8.3.4
1209
+ sha256: 50e16d954148559c9a74109af1eaf0c945ba2d8f30f0a3d3335edde19788b6f6
1210
+ requires_dist:
1211
+ - colorama ; sys_platform == 'win32'
1212
+ - exceptiongroup>=1.0.0rc8 ; python_full_version < '3.11'
1213
+ - iniconfig
1214
+ - packaging
1215
+ - pluggy>=1.5,<2
1216
+ - tomli>=1 ; python_full_version < '3.11'
1217
+ - argcomplete ; extra == 'dev'
1218
+ - attrs>=19.2 ; extra == 'dev'
1219
+ - hypothesis>=3.56 ; extra == 'dev'
1220
+ - mock ; extra == 'dev'
1221
+ - pygments>=2.7.2 ; extra == 'dev'
1222
+ - requests ; extra == 'dev'
1223
+ - setuptools ; extra == 'dev'
1224
+ - xmlschema ; extra == 'dev'
1225
+ requires_python: '>=3.8'
1226
  - conda: https://conda.anaconda.org/conda-forge/win-64/python-3.12.7-hce54a09_0_cpython.conda
1227
  sha256: 2308cfa9ec563360d29ced7fd13a6b60b9a7b3cf8961a95c78c69f486211d018
1228
  md5: 21f1f7c6ccf6b747c5086d2422c230e1
pixi.toml CHANGED
@@ -18,3 +18,4 @@ pytablewriter = ">=1.2.0, <2"
18
  gradio-space-ci = { git = "https://huggingface.co/spaces/Wauplin/gradio-space-ci", rev = "0.2.3" }
19
  beautifulsoup4 = ">=4.12.3, <5"
20
  datasets = ">=3.1.0, <4"
 
 
18
  gradio-space-ci = { git = "https://huggingface.co/spaces/Wauplin/gradio-space-ci", rev = "0.2.3" }
19
  beautifulsoup4 = ">=4.12.3, <5"
20
  datasets = ">=3.1.0, <4"
21
+ pytest = ">=8.3.4, <9"
test_scoring.py ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import urllib3
2
+
3
+ from functions import calculate_results
4
+
5
+
6
+ def test_scores():
7
+ with urllib3.PoolManager() as pool:
8
+ results = calculate_results("T145/ZEUS-8B-V2", pool)
9
+
10
+ # If any calculation is off, this should be wrong
11
+ assert(results["Average"] == 30.07)