239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
|
(define (runs:run-tests-queue test-records keyvallist)
;; At this point the list of parent tests is expanded
;; NB// Should expand items here and then insert into the run queue.
(let ((sorted-testnames (tests:sort-by-priority-and-waiton test-records)))
(let loop (; (numtimes 0) ;; shouldn't need this
(hed (car sorted-test-names))
(tal (cdr sorted-test-names)))
(let* ((test-record (hash-table-ref test-records hed)) WHERE TO DO: (items:get-items-from-config config)
(tconfig (tests:testqueue-get-testconfig test-record))
(waitons (tests:testqueue-get-waitons test-record))
(priority (tests:testqueue-get-priority test-record))
(itemdat (tests:testqueue-get-itemdat test-record))
(items (tests:testqueue-get-items test-record))
(item-path (item-list->path itemdat)))
(cond
((not items) ;; when false the test is ok to be handed off to launch
(let ((have-resources (runs:can-run-more-tests db test-record)) ;; look at the test jobgroup and tot jobs running
(prereqs-not-met (db:get-prereqs-not-met db run-id waiton item-path)))
(if (and have-resources
(null? prereqs-not-met))
;; no loop - drop though and use the loop at the bottom
|
|
>
|
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
|
(define (runs:run-tests-queue test-records keyvallist)
;; At this point the list of parent tests is expanded
;; NB// Should expand items here and then insert into the run queue.
(let ((sorted-testnames (tests:sort-by-priority-and-waiton test-records)))
(let loop (; (numtimes 0) ;; shouldn't need this
(hed (car sorted-test-names))
(tal (cdr sorted-test-names)))
(let* ((test-record (hash-table-ref test-records hed))
(tconfig (tests:testqueue-get-testconfig test-record))
(waitons (tests:testqueue-get-waitons test-record))
(priority (tests:testqueue-get-priority test-record))
(itemdat (tests:testqueue-get-itemdat test-record))
(items (tests:testqueue-get-items test-record))
(item-path (item-list->path itemdat)))
(debug:print 0 "WHERE TO DO: (items:get-items-from-config config)")
(cond
((not items) ;; when false the test is ok to be handed off to launch
(let ((have-resources (runs:can-run-more-tests db test-record)) ;; look at the test jobgroup and tot jobs running
(prereqs-not-met (db:get-prereqs-not-met db run-id waiton item-path)))
(if (and have-resources
(null? prereqs-not-met))
;; no loop - drop though and use the loop at the bottom
|