8
8
9
9
jobs :
10
10
e2e :
11
- name : E2E Tests
12
- runs-on : depot-ubuntu-latest-8
11
+ name : ${{ matrix.suite }}
12
+ runs-on : depot-ubuntu-24.04
13
+ strategy :
14
+ fail-fast : false
15
+ matrix :
16
+ include :
17
+ - suite : agno
18
+ test_path : tests/agnoTests
19
+ services : ["dojo","agno"]
20
+ wait_on : http://localhost:9999,tcp:localhost:8002
21
+ - suite : crew-ai
22
+ test_path : tests/crewAITests
23
+ services : ["dojo","crew-ai"]
24
+ wait_on : http://localhost:9999,tcp:localhost:8003
25
+ - suite : langgraph
26
+ test_path : tests/langgraphTests
27
+ services : ["dojo","langgraph-platform-python","langgraph-platform-typescript"]
28
+ wait_on : http://localhost:9999,tcp:localhost:8005,tcp:localhost:8006
29
+ - suite : langgraph-fastapi
30
+ test_path : tests/langgraphFastAPITests
31
+ services : ["dojo","langgraph-fastapi"]
32
+ wait_on : http://localhost:9999,tcp:localhost:8004
33
+ - suite : llama-index
34
+ test_path : tests/llamaIndexTests
35
+ services : ["dojo","llama-index"]
36
+ wait_on : http://localhost:9999,tcp:localhost:8007
37
+ - suite : mastra
38
+ test_path : tests/mastraTests
39
+ services : ["dojo","mastra"]
40
+ wait_on : http://localhost:9999,tcp:localhost:8008
41
+ - suite : mastra-agent-local
42
+ test_path : tests/mastraAgentLocalTests
43
+ services : ["dojo"]
44
+ wait_on : http://localhost:9999
45
+ - suite : middleware-starter
46
+ test_path : tests/middlewareStarterTests
47
+ services : ["dojo"]
48
+ wait_on : http://localhost:9999
49
+ - suite : pydantic-ai
50
+ test_path : tests/pydanticAITests
51
+ services : ["dojo","pydantic-ai"]
52
+ wait_on : http://localhost:9999,tcp:localhost:8009
53
+ - suite : server-starter
54
+ test_path : tests/serverStarterTests
55
+ services : ["dojo","server-starter"]
56
+ wait_on : http://localhost:9999,tcp:localhost:8000
57
+ - suite : server-starter-all
58
+ test_path : tests/serverStarterAllFeaturesTests
59
+ services : ["dojo","server-starter-all"]
60
+ wait_on : http://localhost:9999,tcp:localhost:8001
61
+ - suite : vercel-ai-sdk
62
+ test_path : tests/vercelAISdkTests
63
+ services : ["dojo"]
64
+ wait_on : http://localhost:9999
13
65
14
66
steps :
15
67
- name : Checkout code
25
77
with :
26
78
version : 10.13.1
27
79
80
+ # Now that pnpm is available, cache its store to speed installs
81
+ - name : Resolve pnpm store path
82
+ id : pnpm-store
83
+ run : echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
84
+
85
+ - name : Cache pnpm store
86
+ uses : actions/cache@v4
87
+ with :
88
+ path : ${{ env.STORE_PATH }}
89
+ key : ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
90
+ restore-keys : |
91
+ ${{ runner.os }}-pnpm-store-
92
+
93
+ # Cache Python tool caches and virtualenvs; restore only to avoid long saves
94
+ - name : Cache Python dependencies (restore-only)
95
+ id : cache-python
96
+ uses : actions/cache/restore@v4
97
+ with :
98
+ path : |
99
+ ~/.cache/pip
100
+ ~/.cache/pypoetry
101
+ ~/.cache/uv
102
+ **/.venv
103
+ key : ${{ runner.os }}-pydeps-${{ hashFiles('**/poetry.lock', '**/pyproject.toml') }}
104
+ restore-keys : |
105
+ ${{ runner.os }}-pydeps-
106
+
28
107
- name : Install Poetry
29
108
uses : snok/install-poetry@v1
30
109
with :
@@ -35,21 +114,14 @@ jobs:
35
114
- name : Install uv
36
115
uses : astral-sh/setup-uv@v6
37
116
38
- - name : Setup pnpm cache
39
- uses : actions/cache@v4
40
- with :
41
- path : ~/.local/share/pnpm/store
42
- key : ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
43
- restore-keys : |
44
- ${{ runner.os }}-pnpm-store-
45
-
46
117
- name : Install dependencies
47
118
working-directory : typescript-sdk
48
119
run : pnpm install --frozen-lockfile
49
120
50
121
- name : Prepare dojo for e2e
51
122
working-directory : typescript-sdk/apps/dojo
52
- run : node ./scripts/prep-dojo-everything.js -e2e
123
+ if : ${{ join(matrix.services, ',') != '' }}
124
+ run : node ./scripts/prep-dojo-everything.js --only ${{ join(matrix.services, ',') }}
53
125
54
126
- name : Install e2e dependencies
55
127
working-directory : typescript-sdk/apps/dojo/e2e
61
133
env :
62
134
OPENAI_API_KEY : ${{ secrets.OPENAI_API_KEY }}
63
135
LANGSMITH_API_KEY : ${{ secrets.LANGSMITH_API_KEY }}
136
+ if : ${{ contains(join(matrix.services, ','), 'langgraph-fastapi') || contains(join(matrix.services, ','), 'langgraph-platform-python') || contains(join(matrix.services, ','), 'langgraph-platform-typescript') }}
64
137
run : |
65
138
echo "OPENAI_API_KEY=${OPENAI_API_KEY}" > examples/python/.env
66
139
echo "LANGSMITH_API_KEY=${LANGSMITH_API_KEY}" >> examples/python/.env
@@ -74,33 +147,28 @@ jobs:
74
147
env :
75
148
OPENAI_API_KEY : ${{ secrets.OPENAI_API_KEY }}
76
149
LANGSMITH_API_KEY : ${{ secrets.LANGSMITH_API_KEY }}
150
+ if : ${{ join(matrix.services, ',') != '' && contains(join(matrix.services, ','), 'dojo') }}
77
151
with :
78
152
run : |
79
- node ../scripts/run-dojo-everything.js
153
+ node ../scripts/run-dojo-everything.js --only ${{ join(matrix.services, ',') }}
80
154
working-directory : typescript-sdk/apps/dojo/e2e
81
- wait-on : |
82
- http://localhost:9999
83
- tcp:localhost:8000
84
- tcp:localhost:8001
85
- tcp:localhost:8002
86
- tcp:localhost:8003
87
- tcp:localhost:8004
88
- tcp:localhost:8005
89
- tcp:localhost:8006
90
- tcp:localhost:8007
91
- tcp:localhost:8008
92
- tcp:localhost:8009
93
-
94
- - name : Run tests
155
+ wait-on : ${{ matrix.wait_on }}
156
+ wait-for : 300000
157
+
158
+ - name : Run tests – ${{ matrix.suite }}
95
159
working-directory : typescript-sdk/apps/dojo/e2e
96
160
env :
97
161
BASE_URL : http://localhost:9999
98
- run : pnpm test
162
+ PLAYWRIGHT_SUITE : ${{ matrix.suite }}
163
+ run : |
164
+ pnpm test -- ${{ matrix.test_path }}
99
165
100
- - name : Upload traces
166
+ - name : Upload traces – ${{ matrix.suite }}
101
167
if : always() # Uploads artifacts even if tests fail
102
168
uses : actions/upload-artifact@v4
103
169
with :
104
- name : playwright-traces
105
- path : typescript-sdk/apps/dojo/e2e/test-results/
170
+ name : ${{ matrix.suite }}-playwright-traces
171
+ path : |
172
+ typescript-sdk/apps/dojo/e2e/test-results/${{ matrix.suite }}/**/*
173
+ typescript-sdk/apps/dojo/e2e/playwright-report/**/*
106
174
retention-days : 7
0 commit comments