forked from ivy-llc/ivy
-
Notifications
You must be signed in to change notification settings - Fork 0
98 lines (83 loc) · 2.79 KB
/
manual-tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
name: manual-tests
on:
workflow_dispatch:
inputs:
test:
description: 'Test:'
default: 'ivy_tests/test_ivy/test_frontends/test_torch/test_tensor.py::test_torch_instance_arctan_,tensorflow'
required: true
version:
description: 'Version Based Testing :'
default: false
required: false
gpu:
description: 'Gpu based Testing :'
default: false
required: false
permissions:
actions: read
jobs:
run_tests_gpu:
if: ${{ github.event.inputs.gpu == 'true' }}
runs-on: self-hosted
steps:
- name: Clean repository
run:
sudo rm -fr $GITHUB_WORKSPACE && mkdir $GITHUB_WORKSPACE
- name: Checkout Ivy 🛎
uses: actions/checkout@v2
with:
path: ivy
persist-credentials: false
submodules: "recursive"
set-safe-directory: false
- name: Get Job URL
uses: Tiryoh/gha-jobid-action@v0
id: jobs
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
job_name: ${{ github.job }}
- name: Run Tests
id: tests
run: |
pip3 install pymongo
cd ivy
mkdir .ivy
touch .ivy/key.pem
echo -n ${{ secrets.USER_API_KEY }} > .ivy/key.pem
python3 setup_tests.py ${{ github.event.inputs.test }}
python3 run_tests.py ${{ secrets.REDIS_CONNECTION_URL }} ${{ secrets.REDIS_PASSWORD }} ${{ secrets.MONGODB_PASSWORD }} 'false' ${{ github.event.inputs.gpu }} ${{ github.run_id }} 'false' ${{ steps.jobs.outputs.html_url }}
continue-on-error: true
- name: Check on failures
if: steps.tests.outcome != 'success'
run: exit 1
run_tests_cpu:
if: ${{ github.event.inputs.gpu == 'false' }}
runs-on: ubuntu-latest
steps:
- name: Checkout Ivy 🛎
uses: actions/checkout@v2
with:
path: ivy
persist-credentials: false
submodules: "recursive"
- name: Get Job URL
uses: Tiryoh/gha-jobid-action@v0
id: jobs
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
job_name: ${{ github.job }}
- name: Run Tests
id: tests
run: |
pip3 install pymongo
cd ivy
mkdir .ivy
touch .ivy/key.pem
echo -n ${{ secrets.USER_API_KEY }} > .ivy/key.pem
python setup_tests.py "${{ github.event.inputs.test }}"
python run_tests.py ${{ secrets.REDIS_CONNECTION_URL }} ${{ secrets.REDIS_PASSWORD }} ${{ secrets.MONGODB_PASSWORD }} ${{ github.event.inputs.version}} 'false' ${{ github.run_id }} 'false' ${{ steps.jobs.outputs.html_url }}
continue-on-error: true
- name: Check on failures
if: steps.tests.outcome != 'success'
run: exit 1