added test to channel.go