forked from kubeflow/kubeflow
-
Notifications
You must be signed in to change notification settings - Fork 3
104 lines (89 loc) · 3.53 KB
/
centraldb_angular_frontend_test.yaml
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
96
97
98
99
100
101
102
103
104
name: CentralDashboard-angular Frontend Tests
on:
pull_request:
paths:
- components/centraldashboard-angular/frontend/**
jobs:
frontend-format-lint-check:
name: Check code format and lint
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 12
- name: Check frontend code formatting
run: |
cd components/centraldashboard-angular/frontend/
npm i
npm run format:check
- name: Check frontend code linting
run: |
cd components/centraldashboard-angular/frontend
npm i
npm run lint-check
run-frontend-unittests:
name: Unit tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 12
- name: Run unit tests
run: |
cd components/centraldashboard-angular/frontend/
npm i
npm run test:prod
run-tests-in-chrome:
name: UI tests in chrome
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup node version to 12
uses: actions/setup-node@v3
with:
node-version: 12
- name: Install KinD
run: ./components/testing/gh-actions/install_kind.sh
- name: Create KinD Cluster
run: kind create cluster --config components/testing/gh-actions/kind-1-25.yaml
- name: Install kustomize
run: ./components/testing/gh-actions/install_kustomize.sh
- name: Install Istio
run: ./components/testing/gh-actions/install_istio.sh
- name: Apply KF Controllers
run: |
cd components
kubectl create namespace kubeflow
kustomize build profile-controller/config/overlays/kubeflow | kubectl apply -f -
kustomize build notebook-controller/config/overlays/kubeflow | kubectl apply -f -
kubectl wait pods -n kubeflow -l kustomize.component=profiles --for=condition=Ready --timeout=300s
kubectl wait pods -n kubeflow -l app=notebook-controller --for=condition=Ready --timeout=300s
- name: Apply JWA manifests
run: |
cd components/crud-web-apps/jupyter/manifests
kustomize build overlays/istio | kubectl apply -f -
kubectl wait pods -n kubeflow -l app=jupyter-web-app --for=condition=Ready --timeout=300s
kubectl port-forward -n kubeflow svc/jupyter-web-app-service 8086:80 &
- name: Apply VWA manifests
run: |
cd components/crud-web-apps/volumes/manifests
kustomize build overlays/istio | kubectl apply -f -
kubectl wait pods -n kubeflow -l app=volumes-web-app --for=condition=Ready --timeout=300s
kubectl port-forward -n kubeflow svc/volumes-web-app-service 8087:80 &
- name: Apply necessary CRs
run: |
kustomize build https://github.com/kubeflow/manifests//common/kubeflow-roles/base?ref=master | kubectl apply -f -
cd components/testing/gh-actions/resources
kubectl apply -f user-profile.yaml
while ! kubectl get ns kubeflow-user; do sleep 1; done
kubectl apply -f test-notebook.yaml
kubectl wait notebooks -n kubeflow-user -l app=test-notebook --for=condition=Ready --timeout=300s
- name: Test proxied apps
run: |
curl -H "kubeflow-userid: user" localhost:8086
curl -H "kubeflow-userid: user" localhost:8087