all repos

x @ 20e7404

go extra()
1 files changed, 9 insertions(+), 0 deletions(-)
is: add NotEqual
Author: Oleksandr Smirnov olexsmir@gmail.com
Committed at: 2026-02-18 22:33:09 +0200
Authored at: 2026-02-18 22:32:08 +0200
Change ID: muksutoqousruszlwwxqqwkpqspurxvu
Parent: 9f2c321
M is/is.go
ยทยทยท
        17
        17
         	}

      
        18
        18
         }

      
        19
        19
         

      
        
        20
        +// NotEqual asserts that two values are not equal.

      
        
        21
        +func NotEqual[T any](tb testing.TB, expected, got T) {

      
        
        22
        +	tb.Helper()

      
        
        23
        +

      
        
        24
        +	if areEqual(expected, got) {

      
        
        25
        +		tb.Errorf("expected values to be different, but both are: %#v", got)

      
        
        26
        +	}

      
        
        27
        +}

      
        
        28
        +

      
        20
        29
         // Err asserts error conditions with flexible expected values:

      
        21
        30
         //   - nil: asserts no error occurred

      
        22
        31
         //   - string: asserts error message contains the string