net: Make "net conf" use a functable similar to functable3
[Samba.git] / testsuite / server / ipc.exp
blobae0688872a8553f6a85b398cb7fc7be5cae6b6cd
2 # Test operations on IPC$ share
5 # Initialisation
7 load_lib env-single.exp
8 load_lib smbclient.exp
10 set timeout 10
12 # Spawn a smbclient
14 if {![spawn_smbclient //$server/ipc\$ -U $user]} {
15 perror "error spawning smbclient"
16 return -1
20 # Start performing tests
23 global smb_prompt
25 do_smbclient "lcd /tmp\r" "lcd /tmp"
26 do_smbclient "!touch test.out\r" "touch test.out"
28 foreach { op } { "dir\r" "put test.out\r" "get test.out\r" \
29 "get /etc/passwd\r" "mkdir foo\r" "print test.out\r" } {
31 set action "doing $op"
32 set output [do_smbclient $op $action]
34 if {![regexp "ERR" $output]} {
35 fail $action
36 puts $output
37 } else {
38 pass $action
42 # Clean up
44 file delete test.out