Megatest

Check-in [3c4ef51e14]
Login
Overview
Comment:Added proper updating of parent test status when sub tests are still running
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 3c4ef51e14f521b97ccaee1825ebd77ab49d80d8
User & Date: mrwellan on 2011-07-13 10:15:55
Other Links: manifest | tags
Context
2011-07-13
10:52
Changed display of seconds for runtime to hrs, min and sec for readability check-in: f1d8ece911 user: mrwellan tags: trunk
10:15
Added proper updating of parent test status when sub tests are still running check-in: 3c4ef51e14 user: mrwellan tags: trunk
07:37
corrected broken fix on config file reader check-in: 0a8acd77a1 user: matt tags: trunk
Changes

Modified runs.scm from [6bf7e36440] to [bee21070b6].

102
103
104
105
106
107
108


109

110
111
112

113
114
115
116
117
118
119
102
103
104
105
106
107
108
109
110

111
112
113

114
115
116
117
118
119
120
121







+
+
-
+


-
+







             SET fail_count=(SELECT count(id) FROM tests WHERE run_id=? AND testname=? AND item_path != '' AND status='FAIL'),
                 pass_count=(SELECT count(id) FROM tests WHERE run_id=? AND testname=? AND item_path != '' AND (status='PASS' OR status='WARN'))
             WHERE run_id=? AND testname=? AND item_path='';"
	   run-id test-name run-id test-name run-id test-name)
	  (sqlite3:execute
	   db
	   "UPDATE tests
             SET state=CASE WHEN (SELECT count(id) FROM tests WHERE run_id=? AND testname=? AND item_path != '' AND state in ('RUNNING','NOT_STARTED')) > 0 THEN 
                          'RUNNING'
             SET state='COMPLETED',
                       ELSE 'COMPLETED' END,
                status=CASE WHEN fail_count > 0 THEN 'FAIL' WHEN pass_count > 0 AND fail_count=0 THEN 'PASS' ELSE 'UNKNOWN' END
             WHERE run_id=? AND testname=? AND item_path='';"
	   run-id test-name)))
	   run-id test-name run-id test-name)))
    (if (and (not (null? comment))
	     (car comment))
	(sqlite3:execute db "UPDATE tests SET comment=? WHERE run_id=? AND testname=? AND item_path=?;"
			 (car comment) run-id test-name item-path))))

(define (test-set-log! db run-id test-name itemdat logf) 
  (let ((item-path (item-list->path itemdat)))

Modified tests/Makefile from [6c479afb2e] to [6cb1ebea02].

1
2
3
4
5
6
7
8
9
10

11
12
13
14
15
16
17
1
2
3
4
5
6
7
8
9

10
11
12
13
14
15
16
17









-
+







# run some tests

MEGATEST=$(shell realpath ../megatest)

runall :
	cd ../;make 
	$(MEGATEST) -keepgoing -runall :sysname ubuntu :fsname nfs :datapath none :runname `date +%GWW%V.%u` -m "This is a comment specific to a run" -v

test :
	csi -I .. ../megatest.scm -- -runall :sysname ubuntu :fsname afs :datapath tmp :runname blah
	csi -b -I .. ../megatest.scm -- -runall :sysname ubuntu :fsname afs :datapath tmp :runname blah
	cd ../;make test
	make runall

dashboard :
	cd ../;make dashboard
	../dashboard &