コード例 #1
0
ファイル: chan_test.go プロジェクト: meidoworks/nekoq-common
func funcWithDeferNop() (resultError error) {
	ch := make(chan bool, 1)
	defer channel.JudgeSendToClosedChannel(channel.OMIT_SEND_TO_CLOSED_CHANNEL_ERROR())
	ch <- true
	return
}
コード例 #2
0
ファイル: chan_test.go プロジェクト: meidoworks/nekoq-common
func TestJudgeSendToClosedChannel(t *testing.T) {
	defer channel.JudgeSendToClosedChannel(channel.OMIT_SEND_TO_CLOSED_CHANNEL_ERROR())
	err := funcToTest()
	t.Log(err)
}