Skip to content

Commit 893d151

Browse files
authored
Merge pull request #579 from voxel51/kacey/fix-flaky-api-log-tests
chore: update startup integration tests [AS-1463]
2 parents 43408d6 + 8278010 commit 893d151

6 files changed

Lines changed: 46 additions & 46 deletions

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -560,7 +560,7 @@ Afterwards, access the FiftyOne Enterprise app via
560560

561561
```shell
562562
$ curl http://localhost:3000/api/hello
563-
{"name":"John Doe"}
563+
{"status":"available"}
564564
```
565565

566566
#### Port Forward to the `teams-api` Service

tests/integration/compose/docker-compose-internal-auth_test.go

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -93,12 +93,12 @@ func (s *commonServicesInternalAuthDockerComposeUpTest) TestDockerComposeUp() {
9393
url: "http://127.0.0.1:8000/health",
9494
responsePayload: `{"status":{"teams":"available"}}`,
9595
httpResponseCode: 200,
96-
log: "motd.py",
96+
log: "FiftyOne Teams API starting up",
9797
},
9898
{
9999
name: "teams-app",
100100
url: "http://127.0.0.1:3000/api/hello",
101-
responsePayload: `{"name":"John Doe"}`,
101+
responsePayload: `{"status":"available"}`,
102102
httpResponseCode: 200,
103103
log: " ✓ Ready in",
104104
},
@@ -107,7 +107,7 @@ func (s *commonServicesInternalAuthDockerComposeUpTest) TestDockerComposeUp() {
107107
url: "http://127.0.0.1:3030/cas/api",
108108
responsePayload: `{"status":"available"}`,
109109
httpResponseCode: 200,
110-
log: " ✓ Ready in",
110+
log: "FiftyOne CAS starting up",
111111
},
112112
// ordering this last to avoid test flakes where testing for log before the container is running
113113
{
@@ -130,12 +130,12 @@ func (s *commonServicesInternalAuthDockerComposeUpTest) TestDockerComposeUp() {
130130
url: "http://127.0.0.1:8000/health",
131131
responsePayload: `{"status":{"teams":"available"}}`,
132132
httpResponseCode: 200,
133-
log: "motd.py",
133+
log: "FiftyOne Teams API starting up",
134134
},
135135
{
136136
name: "teams-app",
137137
url: "http://127.0.0.1:3000/api/hello",
138-
responsePayload: `{"name":"John Doe"}`,
138+
responsePayload: `{"status":"available"}`,
139139
httpResponseCode: 200,
140140
log: " ✓ Ready in",
141141
},
@@ -144,7 +144,7 @@ func (s *commonServicesInternalAuthDockerComposeUpTest) TestDockerComposeUp() {
144144
url: "http://127.0.0.1:3030/cas/api",
145145
responsePayload: `{"status":"available"}`,
146146
httpResponseCode: 200,
147-
log: " ✓ Ready in",
147+
log: "FiftyOne CAS starting up",
148148
},
149149
// ordering this last to avoid test flakes where testing for log before the container is running
150150
{
@@ -167,12 +167,12 @@ func (s *commonServicesInternalAuthDockerComposeUpTest) TestDockerComposeUp() {
167167
url: "http://127.0.0.1:8000/health",
168168
responsePayload: `{"status":{"teams":"available"}}`,
169169
httpResponseCode: 200,
170-
log: "motd.py",
170+
log: "FiftyOne Teams API starting up",
171171
},
172172
{
173173
name: "teams-app",
174174
url: "http://127.0.0.1:3000/api/hello",
175-
responsePayload: `{"name":"John Doe"}`,
175+
responsePayload: `{"status":"available"}`,
176176
httpResponseCode: 200,
177177
log: " ✓ Ready in",
178178
},
@@ -181,7 +181,7 @@ func (s *commonServicesInternalAuthDockerComposeUpTest) TestDockerComposeUp() {
181181
url: "http://127.0.0.1:3030/cas/api",
182182
responsePayload: `{"status":"available"}`,
183183
httpResponseCode: 200,
184-
log: " ✓ Ready in",
184+
log: "FiftyOne CAS starting up",
185185
},
186186
// ordering this last to avoid test flakes where testing for log before the container is running
187187
{
@@ -211,12 +211,12 @@ func (s *commonServicesInternalAuthDockerComposeUpTest) TestDockerComposeUp() {
211211
url: "http://127.0.0.1:8000/health",
212212
responsePayload: `{"status":{"teams":"available"}}`,
213213
httpResponseCode: 200,
214-
log: "motd.py",
214+
log: "FiftyOne Teams API starting up",
215215
},
216216
{
217217
name: "teams-app",
218218
url: "http://127.0.0.1:3000/api/hello",
219-
responsePayload: `{"name":"John Doe"}`,
219+
responsePayload: `{"status":"available"}`,
220220
httpResponseCode: 200,
221221
log: " ✓ Ready in",
222222
},
@@ -225,7 +225,7 @@ func (s *commonServicesInternalAuthDockerComposeUpTest) TestDockerComposeUp() {
225225
url: "http://127.0.0.1:3030/cas/api",
226226
responsePayload: `{"status":"available"}`,
227227
httpResponseCode: 200,
228-
log: " ✓ Ready in",
228+
log: "FiftyOne CAS starting up",
229229
},
230230
// ordering this last to avoid test flakes where testing for log before the container is running
231231
{

tests/integration/compose/docker-compose-legacy-auth_test.go

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -93,12 +93,12 @@ func (s *commonServicesLegacyAuthDockerComposeUpTest) TestDockerComposeUp() {
9393
url: "http://127.0.0.1:8000/health",
9494
responsePayload: `{"status":{"teams":"available"}}`,
9595
httpResponseCode: 200,
96-
log: "motd.py",
96+
log: "FiftyOne Teams API starting up",
9797
},
9898
{
9999
name: "teams-app",
100100
url: "http://127.0.0.1:3000/api/hello",
101-
responsePayload: `{"name":"John Doe"}`,
101+
responsePayload: `{"status":"available"}`,
102102
httpResponseCode: 200,
103103
log: " ✓ Ready in",
104104
},
@@ -107,7 +107,7 @@ func (s *commonServicesLegacyAuthDockerComposeUpTest) TestDockerComposeUp() {
107107
url: "http://127.0.0.1:3030/cas/api",
108108
responsePayload: `{"status":"available"}`,
109109
httpResponseCode: 200,
110-
log: " ✓ Ready in",
110+
log: "FiftyOne CAS starting up",
111111
},
112112
// ordering this last to avoid test flakes where testing for log before the container is running
113113
{
@@ -130,12 +130,12 @@ func (s *commonServicesLegacyAuthDockerComposeUpTest) TestDockerComposeUp() {
130130
url: "http://127.0.0.1:8000/health",
131131
responsePayload: `{"status":{"teams":"available"}}`,
132132
httpResponseCode: 200,
133-
log: "motd.py",
133+
log: "FiftyOne Teams API starting up",
134134
},
135135
{
136136
name: "teams-app",
137137
url: "http://127.0.0.1:3000/api/hello",
138-
responsePayload: `{"name":"John Doe"}`,
138+
responsePayload: `{"status":"available"}`,
139139
httpResponseCode: 200,
140140
log: " ✓ Ready in",
141141
},
@@ -144,7 +144,7 @@ func (s *commonServicesLegacyAuthDockerComposeUpTest) TestDockerComposeUp() {
144144
url: "http://127.0.0.1:3030/cas/api",
145145
responsePayload: `{"status":"available"}`,
146146
httpResponseCode: 200,
147-
log: " ✓ Ready in",
147+
log: "FiftyOne CAS starting up",
148148
},
149149
// ordering this last to avoid test flakes where testing for log before the container is running
150150
{
@@ -167,12 +167,12 @@ func (s *commonServicesLegacyAuthDockerComposeUpTest) TestDockerComposeUp() {
167167
url: "http://127.0.0.1:8000/health",
168168
responsePayload: `{"status":{"teams":"available"}}`,
169169
httpResponseCode: 200,
170-
log: "motd.py",
170+
log: "FiftyOne Teams API starting up",
171171
},
172172
{
173173
name: "teams-app",
174174
url: "http://127.0.0.1:3000/api/hello",
175-
responsePayload: `{"name":"John Doe"}`,
175+
responsePayload: `{"status":"available"}`,
176176
httpResponseCode: 200,
177177
log: " ✓ Ready in",
178178
},
@@ -181,7 +181,7 @@ func (s *commonServicesLegacyAuthDockerComposeUpTest) TestDockerComposeUp() {
181181
url: "http://127.0.0.1:3030/cas/api",
182182
responsePayload: `{"status":"available"}`,
183183
httpResponseCode: 200,
184-
log: " ✓ Ready in",
184+
log: "FiftyOne CAS starting up",
185185
},
186186
// ordering this last to avoid test flakes where testing for log before the container is running
187187
{
@@ -211,12 +211,12 @@ func (s *commonServicesLegacyAuthDockerComposeUpTest) TestDockerComposeUp() {
211211
url: "http://127.0.0.1:8000/health",
212212
responsePayload: `{"status":{"teams":"available"}}`,
213213
httpResponseCode: 200,
214-
log: "motd.py",
214+
log: "FiftyOne Teams API starting up",
215215
},
216216
{
217217
name: "teams-app",
218218
url: "http://127.0.0.1:3000/api/hello",
219-
responsePayload: `{"name":"John Doe"}`,
219+
responsePayload: `{"status":"available"}`,
220220
httpResponseCode: 200,
221221
log: " ✓ Ready in",
222222
},
@@ -225,7 +225,7 @@ func (s *commonServicesLegacyAuthDockerComposeUpTest) TestDockerComposeUp() {
225225
url: "http://127.0.0.1:3030/cas/api",
226226
responsePayload: `{"status":"available"}`,
227227
httpResponseCode: 200,
228-
log: " ✓ Ready in",
228+
log: "FiftyOne CAS starting up",
229229
},
230230
// ordering this last to avoid test flakes where testing for log before the container is running
231231
{

tests/integration/helm/helm-internal-auth_test.go

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -79,19 +79,19 @@ func (s *internalAuthHelmTest) TestHelmInstall() {
7979
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/cas/api", ""),
8080
responsePayload: `{"status":"available"}`,
8181
httpResponseCode: 200,
82-
log: " ✓ Ready in",
82+
log: "FiftyOne CAS starting up",
8383
},
8484
{
8585
name: "teams-api",
8686
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/health", ""),
8787
responsePayload: `{"status":{"teams":"available"}}`,
8888
httpResponseCode: 200,
89-
log: "Starting worker",
89+
log: "FiftyOne Teams API starting up",
9090
},
9191
{
9292
name: "teams-app",
9393
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/api/hello", ""),
94-
responsePayload: `{"name":"John Doe"}`,
94+
responsePayload: `{"status":"available"}`,
9595
httpResponseCode: 200,
9696
log: " ✓ Ready in",
9797
},
@@ -166,19 +166,19 @@ func (s *internalAuthHelmTest) TestHelmInstall() {
166166
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/cas/api", ""),
167167
responsePayload: `{"status":"available"}`,
168168
httpResponseCode: 200,
169-
log: " ✓ Ready in",
169+
log: "FiftyOne CAS starting up",
170170
},
171171
{
172172
name: "teams-api",
173173
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/health", ""),
174174
responsePayload: `{"status":{"teams":"available"}}`,
175175
httpResponseCode: 200,
176-
log: "Starting worker",
176+
log: "FiftyOne Teams API starting up",
177177
},
178178
{
179179
name: "teams-app",
180180
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/api/hello", ""),
181-
responsePayload: `{"name":"John Doe"}`,
181+
responsePayload: `{"status":"available"}`,
182182
httpResponseCode: 200,
183183
log: " ✓ Ready in",
184184
},
@@ -255,19 +255,19 @@ func (s *internalAuthHelmTest) TestHelmInstall() {
255255
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/cas/api", ""),
256256
responsePayload: `{"status":"available"}`,
257257
httpResponseCode: 200,
258-
log: " ✓ Ready in",
258+
log: "FiftyOne CAS starting up",
259259
},
260260
{
261261
name: "teams-api",
262262
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/health", ""),
263263
responsePayload: `{"status":{"teams":"available"}}`,
264264
httpResponseCode: 200,
265-
log: "Starting worker",
265+
log: "FiftyOne Teams API starting up",
266266
},
267267
{
268268
name: "teams-app",
269269
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/api/hello", ""),
270-
responsePayload: `{"name":"John Doe"}`,
270+
responsePayload: `{"status":"available"}`,
271271
httpResponseCode: 200,
272272
log: " ✓ Ready in",
273273
},

tests/integration/helm/helm-legacy-auth_test.go

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -85,19 +85,19 @@ func (s *legacyAuthHelmTest) TestHelmInstall() {
8585
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/cas/api", ""),
8686
responsePayload: `{"status":"available"}`,
8787
httpResponseCode: 200,
88-
log: " ✓ Ready in",
88+
log: "FiftyOne CAS starting up",
8989
},
9090
{
9191
name: "teams-api",
9292
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/health", ""),
9393
responsePayload: `{"status":{"teams":"available"}}`,
9494
httpResponseCode: 200,
95-
log: "Starting worker",
95+
log: "FiftyOne Teams API starting up",
9696
},
9797
{
9898
name: "teams-app",
9999
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/api/hello", ""),
100-
responsePayload: `{"name":"John Doe"}`,
100+
responsePayload: `{"status":"available"}`,
101101
httpResponseCode: 200,
102102
log: " ✓ Ready in",
103103
},
@@ -162,19 +162,19 @@ func (s *legacyAuthHelmTest) TestHelmInstall() {
162162
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/cas/api", ""),
163163
responsePayload: `{"status":"available"}`,
164164
httpResponseCode: 200,
165-
log: " ✓ Ready in",
165+
log: "FiftyOne CAS starting up",
166166
},
167167
{
168168
name: "teams-api",
169169
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/health", ""),
170170
responsePayload: `{"status":{"teams":"available"}}`,
171171
httpResponseCode: 200,
172-
log: "Starting worker",
172+
log: "FiftyOne Teams API starting up",
173173
},
174174
{
175175
name: "teams-app",
176176
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/api/hello", ""),
177-
responsePayload: `{"name":"John Doe"}`,
177+
responsePayload: `{"status":"available"}`,
178178
httpResponseCode: 200,
179179
log: " ✓ Ready in",
180180
},
@@ -249,19 +249,19 @@ func (s *legacyAuthHelmTest) TestHelmInstall() {
249249
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/cas/api", ""),
250250
responsePayload: `{"status":"available"}`,
251251
httpResponseCode: 200,
252-
log: " ✓ Ready in",
252+
log: "FiftyOne CAS starting up",
253253
},
254254
{
255255
name: "teams-api",
256256
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/health", ""),
257257
responsePayload: `{"status":{"teams":"available"}}`,
258258
httpResponseCode: 200,
259-
log: "Starting worker",
259+
log: "FiftyOne Teams API starting up",
260260
},
261261
{
262262
name: "teams-app",
263263
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/api/hello", ""),
264-
responsePayload: `{"name":"John Doe"}`,
264+
responsePayload: `{"status":"available"}`,
265265
httpResponseCode: 200,
266266
log: " ✓ Ready in",
267267
},

tests/integration/helm/helm-topology-spread-constraint_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,12 +96,12 @@ func (s *topologyAuthHelmTest) TestHelmInstall() {
9696
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/health", ""),
9797
responsePayload: `{"status":{"teams":"available"}}`,
9898
httpResponseCode: 200,
99-
log: "Starting worker",
99+
log: "FiftyOne Teams API starting up",
100100
},
101101
{
102102
name: "teams-app",
103103
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/api/hello", ""),
104-
responsePayload: `{"name":"John Doe"}`,
104+
responsePayload: `{"status":"available"}`,
105105
httpResponseCode: 200,
106106
log: " ✓ Ready in",
107107
},
@@ -110,7 +110,7 @@ func (s *topologyAuthHelmTest) TestHelmInstall() {
110110
url: ternary(s.context == "minikube", "https://local.fiftyone.ai/cas/api", ""),
111111
responsePayload: `{"status":"available"}`,
112112
httpResponseCode: 200,
113-
log: " ✓ Ready in",
113+
log: "FiftyOne CAS starting up",
114114
},
115115
// ordering this last to avoid test flakes where testing for log before the container is running
116116
{

0 commit comments

Comments
 (0)