Overview
Comment: | Added regression suite tests for small zip files |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
de59e55104edeffcc09046067ebb85b8 |
User & Date: | rkeene on 2010-09-28 22:03:23 |
Other Links: | manifest | tags |
Context
2010-09-28
| ||
22:10 | Updated vfs::zip tests to require zip::vfs package check-in: fedad6f886 user: rkeene tags: trunk | |
22:03 | Added regression suite tests for small zip files check-in: de59e55104 user: rkeene tags: trunk | |
21:52 | Fixed issue with vfs::zip opening zip files smaller than 512b, fixes issue [0c5bcad642] check-in: c0cb33bec5 user: rkeene tags: trunk | |
Changes
Added build/test/tests/09-smallzip-nobase.sh version [6b8d43f5fd].
> > > > > > > > > > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 | #! /bin/bash TMPFILE="${TMPDIR:-/tmp}/testzip-$$${RANDOM}${RANDOM}${RANDOM}.zip" export TMPFILE cat << \__EOF__ | base64 -d > "${TMPFILE}" IyEvdXNyL2Jpbi9lbnYgdGNsa2l0CiMgVGhpcyBpcyBhIHppcC1iYXNlZCBUY2wgTW9kdWxlCnBh Y2thZ2UgcmVxdWlyZSB2ZnM6OnppcAp2ZnM6OnppcDo6TW91bnQgW2luZm8gc2NyaXB0XSBbaW5m byBzY3JpcHRdCmlmIHtbZmlsZSBleGlzdHMgW2ZpbGUgam9pbiBbaW5mbyBzY3JpcHRdIG1haW4u dGNsXV19IHsKICAgIHNvdXJjZSBbZmlsZSBqb2luIFtpbmZvIHNjcmlwdF0gbWFpbi50Y2xdCn0K GlBLAwQUAAAIAABMfzw9CG+kfTQAAAA0AAAACAAAAG1haW4udGNsIyEgL3Vzci9iaW4vZW52IHRj bHNoCgpwdXRzICJIZWxsbyBXb3JsZCEiCgpleGl0IDAgClBLAQIXAxQAAAgAAEx/PD0Ib6R9NAAA ADQAAAAIAAAAAAAAAAEAIAC2geUAAABtYWluLnRjbFBLBQYAAAAAAQABADYAAAA/AQAAAAA= __EOF__ |
Added build/test/tests/09-smallzip-nobase.tcl version [ff8c61f8fa].
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | #! /usr/bin/env tclsh # Abort if we cant read the tmpfile path from the environment if {![info exists ::env(TMPFILE)]} { exit 0 } set tmpfile $::env(TMPFILE) vfs::zip::Mount $tmpfile $tmpfile set fd [open [file join $tmpfile main.tcl]] set data [read $fd] close $fd catch { vfs::unmount $tmpfile } catch { file delete -force -- $tmpfile } if {[string match "*Hello World*" $data]} { exit 0 } puts "Got: $data" puts "Expected (match): *Hello World*" exit 1 |
Added build/test/tests/10-smallzip-withbase.sh version [dac12cd6f6].
> > > > > > > > > > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 | #! /bin/bash TMPFILE="${TMPDIR:-/tmp}/testzip-$$${RANDOM}${RANDOM}${RANDOM}.zip" export TMPFILE cat << \__EOF__ | base64 -d > "${TMPFILE}" IyEgL3Vzci9iaW4vZW52IHRjbHNoCgpwYWNrYWdlIHJlcXVpcmUgdmZzOjp6aXAKdmZzOjp6aXA6 Ok1vdW50IFtpbmZvIHNjcmlwdF0gW2luZm8gc2NyaXB0XQpzb3VyY2UgW2ZpbGUgam9pbiBbaW5m byBzY3JpcHRdIG1haW4udGNsXQoKcmV0dXJuClBLAwQKAAAAAABNfzw9CG+kfTQAAAA0AAAACAAc AG1haW4udGNsVVQJAAPxVqJM8VaiTHV4CwABBPMDAAAEZAAAACMhIC91c3IvYmluL2VudiB0Y2xz aAoKcHV0cyAiSGVsbG8gV29ybGQhIgoKZXhpdCAwIApQSwECHgMKAAAAAABNfzw9CG+kfTQAAAA0 AAAACAAYAAAAAAABAAAApIEAAAAAbWFpbi50Y2xVVAUAA/FWokx1eAsAAQTzAwAABGQAAABQSwUG AAAAAAEAAQBOAAAAdgAAAAAA __EOF__ |
Added build/test/tests/10-smallzip-withbase.tcl version [ff8c61f8fa].
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | #! /usr/bin/env tclsh # Abort if we cant read the tmpfile path from the environment if {![info exists ::env(TMPFILE)]} { exit 0 } set tmpfile $::env(TMPFILE) vfs::zip::Mount $tmpfile $tmpfile set fd [open [file join $tmpfile main.tcl]] set data [read $fd] close $fd catch { vfs::unmount $tmpfile } catch { file delete -force -- $tmpfile } if {[string match "*Hello World*" $data]} { exit 0 } puts "Got: $data" puts "Expected (match): *Hello World*" exit 1 |