python/join: use lowercase for the dnshostname.
[Samba.git] / testsuite / nsswitch / groupmem_dom.exp
blob3ba34bb810e0a971dfe2ebd64fb9158d10a9a817
2 # @(#) Test whether members of domain groups all have domain names
5 load_lib util-defs.exp
7 set group_list [split [util_start "getent group" ""] "\n"]
8 set failed 0
10 foreach { group } $group_list {
11 set group_entry [split $group ":"]
13 set group_name [lindex $group_entry 0]
14 set group_members [split [lindex $group_entry 3] ","]
16 if { [regexp {^[^/]+/} $group_name] } {
18 verbose "group $group_name has members $group_members"
20 foreach { user } $group_members {
21 if { ![regexp {^[^/]+/} $user] } {
22 fail "group $group has non-domain user $user"
23 set failed 1
26 } else {
27 verbose "ignoring non-domain group $group_name"
31 if { !$failed } {
32 pass "domain groups contain only domain members"