File tree Expand file tree Collapse file tree 1 file changed +2
-5
lines changed
enterprise/coderd/prebuilds Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -216,14 +216,11 @@ func TestClaimPrebuild(t *testing.T) {
216
216
// Then: the number of running prebuilds has changed since one was claimed.
217
217
currentPrebuilds , err := spy .GetRunningPrebuiltWorkspaces (ctx )
218
218
require .NoError (t , err )
219
- require .NotEqual (t , len ( currentPrebuilds ) , len (runningPrebuilds ))
219
+ require .Equal (t , expectedPrebuildsCount - 1 , len (currentPrebuilds ))
220
220
221
221
// Then: the claimed prebuild is now missing from the running prebuilds set.
222
- current , err := spy .GetRunningPrebuiltWorkspaces (ctx )
223
- require .NoError (t , err )
224
-
225
222
var found bool
226
- for _ , prebuild := range current {
223
+ for _ , prebuild := range currentPrebuilds {
227
224
if prebuild .ID == claimed .ID {
228
225
found = true
229
226
break
You can’t perform that action at this time.
0 commit comments