(t *testing.T)
| 822 | } |
| 823 | |
| 824 | func TestFormatUnequalValues(t *testing.T) { |
| 825 | t.Parallel() |
| 826 | |
| 827 | expected, actual := formatUnequalValues("foo", "bar") |
| 828 | Equal(t, `"foo"`, expected, "value should not include type") |
| 829 | Equal(t, `"bar"`, actual, "value should not include type") |
| 830 | |
| 831 | expected, actual = formatUnequalValues(123, 123) |
| 832 | Equal(t, `123`, expected, "value should not include type") |
| 833 | Equal(t, `123`, actual, "value should not include type") |
| 834 | |
| 835 | expected, actual = formatUnequalValues(int64(123), int32(123)) |
| 836 | Equal(t, `int64(123)`, expected, "value should include type") |
| 837 | Equal(t, `int32(123)`, actual, "value should include type") |
| 838 | |
| 839 | expected, actual = formatUnequalValues(int64(123), nil) |
| 840 | Equal(t, `int64(123)`, expected, "value should include type") |
| 841 | Equal(t, `<nil>(<nil>)`, actual, "value should include type") |
| 842 | |
| 843 | type testStructType struct { |
| 844 | Val string |
| 845 | } |
| 846 | |
| 847 | expected, actual = formatUnequalValues(&testStructType{Val: "test"}, &testStructType{Val: "test"}) |
| 848 | Equal(t, `&assert.testStructType{Val:"test"}`, expected, "value should not include type annotation") |
| 849 | Equal(t, `&assert.testStructType{Val:"test"}`, actual, "value should not include type annotation") |
| 850 | } |
| 851 | |
| 852 | func TestNotNil(t *testing.T) { |
| 853 | t.Parallel() |
nothing calls this directly
no test coverage detected