Check-in [bbc27a0fd1]
Overview
Comment:Added Metakit test
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:bbc27a0fd1f694375e6458d6340b401669090949
User & Date: rkeene on 2010-10-03 21:01:14
Other Links: manifest | tags
Context
2010-10-03
21:02
Updated Mk4tcl to default to being built as a shared object if target is KitDLL check-in: eea8763689 user: rkeene tags: trunk
21:01
Added Metakit test check-in: bbc27a0fd1 user: rkeene tags: trunk
19:09
Updated KitDLL to load the vfslib, to make vfs::zip work check-in: 64818401f4 user: rkeene tags: trunk
Changes

Added build/test/tests/11-metakit.tcl version [ef16a161c4].

            1  +#! /usr/bin/env tclsh
            2  +
            3  +set buildflags [split [lindex $argv 1] -]
            4  +
            5  +# This test works implicitly on Tclkits without Metakit4
            6  +foreach flag [list nomk4 min] {
            7  +	if {[lsearch -exact $buildflags $flag] != -1} {
            8  +		exit 0
            9  +	}
           10  +}
           11  +
           12  +catch {
           13  +	file delete -force datafile.mk
           14  +}
           15  +
           16  +set testval "<Not Found>"
           17  +set errorInfo_save "<No Error>"
           18  +if {[catch {
           19  +	package require Mk4tcl
           20  +
           21  +	mk::file open db datafile.mk
           22  +	mk::view layout db.test {first second}
           23  +	mk::row append db.test first Joe second Bob
           24  +	mk::file commit db
           25  +	mk::file close db
           26  +
           27  +	mk::file open db datafile.mk
           28  +	set testval [mk::get db.test!0 first]
           29  +	mk::file close db
           30  +}]} {
           31  +	set errorInfo_save $errorInfo
           32  +}
           33  +
           34  +catch {
           35  +	file delete -force datafile.mk
           36  +}
           37  +
           38  +if {$testval == "Joe"} {
           39  +	exit 0
           40  +}
           41  +
           42  +puts "Returned: $testval"
           43  +puts "Expected: Joe"
           44  +puts "Error   : $errorInfo_save"
           45  +
           46  +exit 1