Check-in [c991aa8ae7]

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Adjust Datalog tests to cover EQUALITY
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:c991aa8ae75a6807b35d5800981cd43e46e83b48
User & Date: kbk 2014-10-26 04:09:25
Context
2014-11-23
21:54
Made a 'datalog::database' class that instantiates a FDDD database integrated with the Datalog compiler, and a 'datalogMethod' command to introduce an instance method (representing a Datalog program) on such a database. check-in: d33f642607 user: kbk tags: trunk
2014-10-26
04:09
Adjust Datalog tests to cover EQUALITY check-in: c991aa8ae7 user: kbk tags: trunk
04:02
Add more Datalog tests, and adjust loadscript.tcl.in to allow for running Nagelfar instrumented code while testing. check-in: db5c306a7f user: kbk tags: trunk
Changes

Changes to tests/datalog.test.

260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
    -body {
	proc t {who} [bdd::datalog::compileProgram db {
	    variable p
	    variable people
	    set results {}
	    set p2 $p($who)
	} {
	    isAncestorOf(p1,p2) :- isParentOf(p1,p2).
	    isAncestorOf(p1,p2) :- isParentOf(p1,p3), isAncestorOf(p3,p2).
	    isAncestorOf(p1, $p2) ?
	} d {
	    set p1 [dict get $d p1]
	    if {$p1 < [llength $people]} {
		lappend result [lindex $people $p1]
	    }
	} {
	    lsort $result
	}]
	t George
    }
    -cleanup fini1
    -result {Charles Elizabeth William}
}

cleanupTests
return

# Local Variables:
# mode: tcl
# c-basic-offset: 4
# indent-tabs-mode: nil
# End:







|













|










260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
    -body {
	proc t {who} [bdd::datalog::compileProgram db {
	    variable p
	    variable people
	    set results {}
	    set p2 $p($who)
	} {
	    isAncestorOf(p1,p2) :- p1 = p2.
	    isAncestorOf(p1,p2) :- isParentOf(p1,p3), isAncestorOf(p3,p2).
	    isAncestorOf(p1, $p2) ?
	} d {
	    set p1 [dict get $d p1]
	    if {$p1 < [llength $people]} {
		lappend result [lindex $people $p1]
	    }
	} {
	    lsort $result
	}]
	t George
    }
    -cleanup fini1
    -result {Charles Elizabeth George William}
}

cleanupTests
return

# Local Variables:
# mode: tcl
# c-basic-offset: 4
# indent-tabs-mode: nil
# End: