github.com/xmidt-org/webpa-common@v1.11.9/xhttp/nilConstructor_test.go (about)

     1  package xhttp
     2  
     3  import (
     4  	"testing"
     5  
     6  	"github.com/stretchr/testify/assert"
     7  )
     8  
     9  func TestNilConstructor(t *testing.T) {
    10  	var (
    11  		assert = assert.New(t)
    12  		next   = Constant{}
    13  	)
    14  
    15  	assert.Nil(NilConstructor(nil))
    16  	assert.Equal(next, NilConstructor(next))
    17  }