Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for TestRTrimSlice (0.1 sec)

  1. utils/utils_test.go

    		t.Run(test.name, func(t *testing.T) {
    			if out := ToString(test.in); test.out != out {
    				t.Fatalf("ToString(%v) want: %s, got: %s", test.in, test.out, out)
    			}
    		})
    	}
    }
    
    func TestRTrimSlice(t *testing.T) {
    	tests := []struct {
    		name     string
    		input    []int
    		trimLen  int
    		expected []int
    	}{
    		{
    			name:     "Trim two elements from end",
    			input:    []int{1, 2, 3, 4, 5},
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Thu Aug 22 11:03:42 UTC 2024
    - 4.9K bytes
    - Viewed (0)
Back to top