]> git.saurik.com Git - redis.git/blame - test/test_helper.tcl
use DEBUG DIGEST in new test suite
[redis.git] / test / test_helper.tcl
CommitLineData
98578b57
PN
1# Redis test suite. Copyright (C) 2009 Salvatore Sanfilippo antirez@gmail.com
2# This softare is released under the BSD License. See the COPYING file for
3# more information.
4
5set tcl_precision 17
6source test/support/redis.tcl
7source test/support/server.tcl
8source test/support/tmpfile.tcl
9source test/support/test.tcl
10source test/support/util.tcl
11
12set ::host 127.0.0.1
13set ::port 6379
14set ::traceleaks 0
15
16proc execute_tests name {
17 set cur $::testnum
18 source "test/$name.tcl"
19}
20
21# setup a list to hold a stack of clients. the proc "r" provides easy
22# access to the client at the top of the stack
23set ::clients {}
24proc r {args} {
25 set client [lindex $::clients end]
26 $client {*}$args
27}
28
29proc main {} {
30 execute_tests "unit/auth"
31 execute_tests "unit/protocol"
32 execute_tests "unit/basic"
33 execute_tests "unit/type/list"
34 execute_tests "unit/type/set"
35 execute_tests "unit/type/zset"
36 execute_tests "unit/type/hash"
37 execute_tests "unit/sort"
38 execute_tests "unit/expire"
39 execute_tests "unit/other"
40
41 puts "\n[expr $::passed+$::failed] tests, $::passed passed, $::failed failed"
42 if {$::failed > 0} {
43 puts "\n*** WARNING!!! $::failed FAILED TESTS ***\n"
44 }
45
46 # clean up tmp
47 exec rm -rf test/tmp/*
48}
49
50main