Compare commits

..

2 Commits

View File

@ -34,7 +34,6 @@ func (m *mockTextUnmarshaler) UnmarshalText(text []byte) error {
return m.returnError
}
// TestTrySetByInterface_WithBindUnmarshaler tests successful binding with bindUnmarshaler
func TestTrySetByInterface_WithBindUnmarshaler(t *testing.T) {
api := bindingApi{}
mock := &mockBindUnmarshaler{}
@ -47,7 +46,6 @@ func TestTrySetByInterface_WithBindUnmarshaler(t *testing.T) {
require.Equal(t, inputVal, mock.receivedParam)
}
// TestTrySetByInterface_WithBindUnmarshalerError tests error handling from bindUnmarshaler
func TestTrySetByInterface_WithBindUnmarshalerError(t *testing.T) {
api := bindingApi{}
expectedErr := errors.New("unmarshal error")
@ -60,7 +58,6 @@ func TestTrySetByInterface_WithBindUnmarshalerError(t *testing.T) {
require.Error(t, err)
}
// TestTrySetByInterface_WithTextUnmarshaler tests encoding.TextUnmarshaler
func TestTrySetByInterface_WithTextUnmarshaler(t *testing.T) {
api := bindingApi{}
mock := &mockTextUnmarshaler{}
@ -73,7 +70,6 @@ func TestTrySetByInterface_WithTextUnmarshaler(t *testing.T) {
require.Equal(t, []byte(inputVal), mock.receivedText)
}
// TestTrySetByInterface_WithTextUnmarshalerError tests error handling from TextUnmarshaler
func TestTrySetByInterface_WithTextUnmarshalerError(t *testing.T) {
api := bindingApi{}
expectedErr := errors.New("text unmarshal error")
@ -86,7 +82,6 @@ func TestTrySetByInterface_WithTextUnmarshalerError(t *testing.T) {
require.Error(t, err)
}
// TestTrySetByInterface_WithTimeTime tests that time.Time is skipped
func TestTrySetByInterface_WithTimeTime(t *testing.T) {
api := bindingApi{}
now := time.Now()
@ -143,7 +138,6 @@ func (m *mockBothInterfaces) UnmarshalText(text []byte) error {
var _ encoding.TextUnmarshaler = (*mockBothInterfaces)(nil)
// TestTrySetByInterface_PriorityBindUnmarshaler tests bindUnmarshaler takes priority
func TestTrySetByInterface_PriorityBindUnmarshaler(t *testing.T) {
api := bindingApi{}
mock := &mockBothInterfaces{}