Skip to content

Commit d577334

Browse files
committed
Add onnxruntime tests to CircleCI
1 parent 1a454f2 commit d577334

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

.circleci/config.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -345,6 +345,32 @@ jobs:
345345
- '~/.cache/pip'
346346
- run: python -m pytest -sv ./tests/ -m is_staging_test
347347

348+
run_tests_onnxruntime:
349+
working_directory: ~/transformers
350+
docker:
351+
- image: circleci/python:3.7
352+
environment:
353+
OMP_NUM_THREADS: 1
354+
TRANSFORMERS_IS_CI: yes
355+
resource_class: xlarge
356+
parallelism: 1
357+
steps:
358+
- checkout
359+
- restore_cache:
360+
keys:
361+
- v0.4-torch-{{ checksum "setup.py" }}
362+
- v0.4-{{ checksum "setup.py" }}
363+
- run: pip install --upgrade pip
364+
- run: pip install .[torch,testing,sentencepiece,onnxruntime]
365+
- save_cache:
366+
key: v0.4-onnx-{{ checksum "setup.py" }}
367+
paths:
368+
- '~/.cache/pip'
369+
- run: python -m pytest -n 1 --dist=loadfile -s --make-reports=tests_torch ./tests/* -k onnx | tee tests_output.txt
370+
- store_artifacts:
371+
path: ~/transformers/tests_output.txt
372+
- store_artifacts:
373+
path: ~/transformers/reports
348374
build_doc:
349375
working_directory: ~/transformers
350376
docker:

0 commit comments

Comments
 (0)