Overview
Comment: | Snapshot - still problematic in the test queue |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | test-specific-db |
Files: | files | file ages | folders |
SHA1: |
b3fb6e132e457fcfa1df3719dc39ef1f |
User & Date: | mrwellan on 2012-09-25 18:03:22 |
Other Links: | branch diff | manifest | tags |
Context
2012-09-26
| ||
14:10 | Fixed typo, yeah, right, it was a typo check-in: 3ec351303e user: matt tags: test-specific-db | |
2012-09-25
| ||
18:03 | Snapshot - still problematic in the test queue check-in: b3fb6e132e user: mrwellan tags: test-specific-db | |
12:06 | This one looks good. check-in: 91504daf87 user: mrwellan tags: test-specific-db | |
Changes
Modified db.scm from [589b14ba9e] to [2d53e6151a].
︙ | |||
672 673 674 675 676 677 678 | 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 | - + + + + + + + + + + + + + | (lambda (count) (set! res count)) db ;; NB// KILLREQ means the jobs is still probably running "SELECT count(id) FROM tests WHERE state in ('LAUNCHED','NOT_STARTED','REMOTEHOSTSTART','RUNNING','KILLREQ') AND run_id=?;" run-id) res)) ;; map run-id, testname item-path to test-id |
︙ | |||
722 723 724 725 726 727 728 | 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 | - + + + + + + + + + + + + + + + + + | ;; 1. set state to DELETED ;; 2. set status to n/a (begin (db:test-set-state! res "NOT_STARTED") (db:test-set-status! res "n/a"))))) ;; Get test data using test_id |
︙ |
Modified runs.scm from [5395094d8f] to [c904e6b94c].
︙ | |||
211 212 213 214 215 216 217 218 219 220 221 222 223 224 | 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 | + | ;; from here on out the db will be opened and closed on every call runs:run-tests-queue (sqlite3:finalize! db) ;; now add non-directly referenced dependencies (i.e. waiton) (if (not (null? test-names)) (let loop ((hed (car test-names)) (tal (cdr test-names))) ;; 'return-procs tells the config reader to prep running system but return a proc (debug:print 4 "INFO: hed=" hed " at top of loop") (let* ((config (tests:get-testconfig hed 'return-procs)) (waitons (if config (string-split (let ((w (config-lookup config "requirements" "waiton"))) (if w w ""))) (begin (debug:print 0 "ERROR: non-existent required test \"" hed "\"") (sqlite3:finalize! db) (exit 1))))) |
︙ | |||
273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 | 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 | + - + + - + | (let ((remtests (delete-duplicates (append waitons tal)))) (if (not (null? remtests)) (loop (car remtests)(cdr remtests))))))) (if (not (null? required-tests)) (debug:print 1 "INFO: Adding " required-tests " to the run queue")) ;; NOTE: these are all parent tests, items are not expanded yet. (debug:print 4 "INFO: test-records=" (hash-table->alist test-records)) (runs:run-tests-queue run-id runname test-records keyvallst flags) (debug:print 4 "INFO: All done by here"))) ;; test-records is a hash table testname:item_path => vector < testname testconfig waitons priority items-info ... > (define (runs:run-tests-queue run-id runname test-records keyvallst flags) ;; At this point the list of parent tests is expanded ;; NB// Should expand items here and then insert into the run queue. (debug:print 5 "test-records: " test-records ", keyvallst: " keyvallst " flags: " (hash-table->alist flags)) (let ((sorted-test-names (tests:sort-by-priority-and-waiton test-records)) |
︙ | |||
317 318 319 320 321 322 323 324 | 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 | + + + - + - + - + + - - - - - - + - - - + + + + + + + + + + + + + | prereqs-not-met))) (pretty-string (lambda (lst) (map (lambda (t) (if (not (vector? t)) (conc t) (conc (db:test-get-testname t) ":" (db:test-get-state t) "/" (db:test-get-status t)))) lst)))) (debug:print 6 "test-name: " test-name "\n hed: " hed |
︙ | |||
496 497 498 499 500 501 502 | 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 | - + - + | (itemdat (tests:testqueue-get-itemdat test-record)) (test-path (conc *toppath* "/tests/" test-name)) ;; could use tests:get-testconfig here ... (force (hash-table-ref/default flags "-force" #f)) (rerun (hash-table-ref/default flags "-rerun" #f)) (keepgoing (hash-table-ref/default flags "-keepgoing" #f)) (item-path "") (db #f)) |
︙ | |||
526 527 528 529 530 531 532 | 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 | + - + + + + + | (test-id (open-run-close db:get-test-id db run-id test-name item-path)) (testdat (open-run-close db:get-test-info-by-id db test-id))) (if (not testdat) (begin ;; ensure that the path exists before registering the test ;; NOPE: Cannot! Don't know yet which disk area will be assigned.... ;; (system (conc "mkdir -p " new-test-path)) ;; |
︙ |
Modified tests.scm from [ca0ab90b21] to [acf4551441].
︙ | |||
26 27 28 29 30 31 32 | 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 | + - - - - - - - - - - + + + + + + + + + + | (include "common_records.scm") (include "key_records.scm") (include "db_records.scm") (include "run_records.scm") (include "test_records.scm") (define (tests:register-test db run-id test-name item-path) (debug:print 4 "INFO: tests:register-test db=" db ", run-id=" run-id ", test-name=" test-name ", item-path=" item-path) |
︙ |
Modified tests/Makefile from [50fd483166] to [db2cf6a2e6].
︙ | |||
18 19 20 21 22 23 24 | 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | - + | test2 : fullprep cd fullrun;$(MEGATEST) -runtests ez_pass -reqtarg ubuntu/nfs/none :runname $(RUNNAME)_a $(SERVER) test3 : fullprep cd fullrun;$(MEGATEST) -runtests runfirst -reqtarg ubuntu/nfs/none :runname $(RUNNAME)_b $(SERVER) -debug 10 test4 : fullprep |
︙ |