(t *testing.T)
| 1803 | } |
| 1804 | |
| 1805 | func TestInDeltaSlice(t *testing.T) { |
| 1806 | mockT := new(testing.T) |
| 1807 | |
| 1808 | True(t, InDeltaSlice(mockT, |
| 1809 | []float64{1.001, math.NaN(), 0.999}, |
| 1810 | []float64{1, math.NaN(), 1}, |
| 1811 | 0.1), "{1.001, NaN, 0.009} is element-wise close to {1, NaN, 1} in delta=0.1") |
| 1812 | |
| 1813 | True(t, InDeltaSlice(mockT, |
| 1814 | []float64{1, math.NaN(), 2}, |
| 1815 | []float64{0, math.NaN(), 3}, |
| 1816 | 1), "{1, NaN, 2} is element-wise close to {0, NaN, 3} in delta=1") |
| 1817 | |
| 1818 | False(t, InDeltaSlice(mockT, |
| 1819 | []float64{1, math.NaN(), 2}, |
| 1820 | []float64{0, math.NaN(), 3}, |
| 1821 | 0.1), "{1, NaN, 2} is not element-wise close to {0, NaN, 3} in delta=0.1") |
| 1822 | |
| 1823 | False(t, InDeltaSlice(mockT, "", nil, 1), "Expected non numeral slices to fail") |
| 1824 | } |
| 1825 | |
| 1826 | func TestInDeltaMapValues(t *testing.T) { |
| 1827 | mockT := new(testing.T) |
nothing calls this directly
no test coverage detected
searching dependent graphs…