Megatest

Check-in [61b6b7cdd3]
Login
Overview
Comment:static test summary now created
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | static-html
Files: files | file ages | folders
SHA1: 61b6b7cdd36940e73cb17a0a9d2cedc37d5d1eb1
User & Date: matt on 2015-02-26 00:29:16
Other Links: branch diff | manifest | tags
Context
2015-02-26
08:15
Sync up static-html branch with v1.60 check-in: 67574f93c1 user: mrwellan tags: static-html
00:29
static test summary now created check-in: 61b6b7cdd3 user: matt tags: static-html
2015-02-25
21:56
static html check-in: 9c5f4d7903 user: matt tags: static-html
Changes

Modified launch.scm from [6f46ed2d13] to [69baf337bd].

434
435
436
437
438
439
440
441


442
443
444
445
446
447
448
434
435
436
437
438
439
440

441
442
443
444
445
446
447
448
449







-
+
+







					    new-status
					    (args:get-arg "-m") #f)
		    ;; need to update the top test record if PASS or FAIL and this is a subtest
		    ;; NO NEED TO CALL roll-up-pass-fail-counts HERE, THIS IS DONE IN roll-up-pass-fail-counts called by tests:test-set-status!
		    ))
	      ;; for automated creation of the rollup html file this is a good place...
	      (if (not (equal? item-path ""))
		  (tests:summarize-items run-id test-id test-name #f))) ;; don't force - just update if no
		  (tests:summarize-items run-id test-id test-name #f))
	      (tests:summarize-test run-id test-id)) ;; don't force - just update if no
	    (mutex-unlock! m)
	    (debug:print 2 "Output from running " fullrunscript ", pid " (vector-ref exit-info 0) " in work area " 
			 work-area ":\n====\n exit code " (vector-ref exit-info 2) "\n" "====\n")
	    (if (not (vector-ref exit-info 1))
		(exit 4)))))))

;; set up the very basics needed for doing anything here.

Modified tests.scm from [bd16816b2d] to [ff12e2dd95].

390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405














406
407
408
409
410
411
412
390
391
392
393
394
395
396









397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417







-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+







		  (change-directory orig-dir)
		  ;; NB// tests:test-set-toplog! is remote internal...
		  (tests:test-set-toplog! run-id test-name outputfilename)
		  )))))))

;; summarize test
(define (tests:summarize-test run-id test-id)
  (let ((test-dat  (rmt:get-test-info-by-id run-id test-id))
	(steps-dat (rmt:get-steps-for-test run-id test-id))
	(test-name (db:test-get-testname test-dat)))
    (with-output-to-file "test-summary.html"
      (lambda ()
	(print "<html><title>Summary: " test-name
	       "</title><body><h2>Summary for " test-name "</h2>")
	(print "<table>

  (let* ((test-dat  (rmt:get-test-info-by-id run-id test-id))
	 (steps-dat (rmt:get-steps-for-test run-id test-id))
	 (test-name (db:test-get-testname test-dat))
	 (oup       (open-output-file "test-summary.html")))
    (s:output-new
     oup
     (s:html
      (s:title "Summary: " test-name)
      (s:body 
       (s:h2 "Summary for " test-name)
       )))
    (close-output-port oup)))
	  
	  
;; MUST BE CALLED local!
;;
(define (tests:test-get-paths-matching keynames target fnamepatt #!key (res '()))
  ;; BUG: Move the values derived from args to parameters and push to megatest.scm
  (let* ((testpatt   (if (args:get-arg "-testpatt")(args:get-arg "-testpatt") "%"))
	 (statepatt  (if (args:get-arg ":state")   (args:get-arg ":state")    "%"))
	 (statuspatt (if (args:get-arg ":status")  (args:get-arg ":status")   "%"))