591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
|
(iup:hbox
(iup:toggle "Local" #:size "40x")
(iup:toggle "Server" #:size "40x")))
(iup:textbox
#:value "megatest -xyz"
#:expand "HORIZONTAL")
(iup:button "Execute" #:size "50x"))
(iup:split
;; Target, testpatt, state and status input boxes
(iup:vbox
;; Command to run
(iup:frame
#:title "Set the action to take"
(iup:hbox
(iup:label "Command to run" #:expand "HORIZONTAL" #:size "70x")
(let ((lb (iup:listbox #:expand "HORIZONTAL"
#:dropdown "YES")))
(iuplistbox-fill-list lb '("-runtests" "-remove-runs" "-set-state-status") "-runtests")
lb)))
(iup:frame
#:title "Selectors that determine which tests will be operated on"
(iup:vbox
;; Text box for test patterns
(iup:frame
#:title "Test patterns (one per line)"
(iup:textbox #:action (lambda (val a b)
(dboard:data-set-test-patts!
*data*
(dboard:lines->test-patt b)))
#:value (dboard:test-patt->lines
(dboard:data-get-test-patts *data*))
#:expand "YES"
#:multiline "YES"))
(iup:frame
#:title "Target"
;; Target selectors
(apply iup:hbox
(let* ((dat (dashboard:update-target-selector key-listboxes action-proc: update-keyvals))
(key-lb (car dat))
(combos (cadr dat)))
(set! key-listboxes key-lb)
combos)))
(iup:hbox
;; Text box for STATES
(iup:frame
#:title "States"
(dashboard:text-list-toggle-box
'("COMPLETED" "RUNNING" "STUCK" "INCOMPLETE" "LAUNCHED" "REMOTEHOSTSTART" "KILLED")
(lambda (all)
(dboard:data-set-states! *data* (string-intersperse all ","))
(dashboard:update-run-command))))
;; Text box for STATES
(iup:frame
#:title "States"
(dashboard:text-list-toggle-box
'("PASS" "FAIL" "n/a" "CHECK" "WAIVED" "SKIP" "DELETED" "STUCK/DEAD")
(lambda (all)
(dboard:data-set-statuses! *data* (string-intersperse all ","))
(dashboard:update-run-command))))))))
(iup:split
#:orientation "HORIZONTAL"
(iup:frame
#:title "Tests and Tasks"
(iup:canvas #:action (make-canvas-action
(lambda (cnv xadj yadj)
;; (print "cnv: " cnv " x: " x " y: " y)
(dashboard:draw-tests cnv xadj yadj tests-draw-state sorted-testnames)))
#:size "150x150"
#:expand "YES"
#:scrollbar "YES"
#:posx "0.5"
#:posy "0.5"))
(iup:frame
#:title "Logs" ;; To be replaced with tabs
(let ((logs-tb (iup:textbox #:expand "YES"
#:multiline "YES")))
(dboard:data-set-logs-textbox! *data* logs-tb)
logs-tb))
)))))
;; (trace dashboard:populate-target-dropdown
;; common:list-is-sublist)
;;
;; ;; key1 key2 key3 ...
;; ;; target entry (wild cards allowed)
|
|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
>
>
>
>
>
|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
|
|
|
|
|
|
|
|
|
|
>
|
|
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
|
(iup:hbox
(iup:toggle "Local" #:size "40x")
(iup:toggle "Server" #:size "40x")))
(iup:textbox
#:value "megatest -xyz"
#:expand "HORIZONTAL")
(iup:button "Execute" #:size "50x"))
(iup:split
#:orientation "HORIZONTAL"
(iup:split
;; Target, testpatt, state and status input boxes
(iup:vbox
;; Command to run
(iup:frame
#:title "Set the action to take"
(iup:hbox
(iup:label "Command to run" #:expand "HORIZONTAL" #:size "70x")
(let ((lb (iup:listbox #:expand "HORIZONTAL"
#:dropdown "YES")))
(iuplistbox-fill-list lb '("-runtests" "-remove-runs" "-set-state-status") "-runtests")
lb)))
(iup:frame
#:title "Selectors that determine which tests will be operated on"
(iup:vbox
;; Text box for test patterns
(iup:frame
#:title "Test patterns (one per line)"
(iup:textbox #:action (lambda (val a b)
(dboard:data-set-test-patts!
*data*
(dboard:lines->test-patt b)))
#:value (dboard:test-patt->lines
(dboard:data-get-test-patts *data*))
#:expand "YES"
#:multiline "YES"))
(iup:frame
#:title "Target"
;; Target selectors
(apply iup:hbox
(let* ((dat (dashboard:update-target-selector key-listboxes action-proc: update-keyvals))
(key-lb (car dat))
(combos (cadr dat)))
(set! key-listboxes key-lb)
combos)))
(iup:hbox
;; Text box for STATES
(iup:frame
#:title "States"
(dashboard:text-list-toggle-box
'("COMPLETED" "RUNNING" "STUCK" "INCOMPLETE" "LAUNCHED" "REMOTEHOSTSTART" "KILLED")
(lambda (all)
(dboard:data-set-states! *data* (string-intersperse all ","))
(dashboard:update-run-command))))
;; Text box for STATES
(iup:frame
#:title "States"
(dashboard:text-list-toggle-box
'("PASS" "FAIL" "n/a" "CHECK" "WAIVED" "SKIP" "DELETED" "STUCK/DEAD")
(lambda (all)
(dboard:data-set-statuses! *data* (string-intersperse all ","))
(dashboard:update-run-command))))))))
(iup:frame
#:title "Tests and Tasks"
(iup:canvas #:action (make-canvas-action
(lambda (cnv xadj yadj)
;; (print "cnv: " cnv " x: " x " y: " y)
(dashboard:draw-tests cnv xadj yadj tests-draw-state sorted-testnames)))
#:size "150x150"
#:expand "YES"
#:scrollbar "YES"
#:posx "0.5"
#:posy "0.5")))
(iup:frame
#:title "Logs" ;; To be replaced with tabs
(let ((logs-tb (iup:textbox #:expand "YES"
#:multiline "YES")))
(dboard:data-set-logs-textbox! *data* logs-tb)
logs-tb))
))))
;; (trace dashboard:populate-target-dropdown
;; common:list-is-sublist)
;;
;; ;; key1 key2 key3 ...
;; ;; target entry (wild cards allowed)
|