======================================== Buffer Creation Tests ========================================
(t *testing.T)
| 10 | // ======================================== |
| 11 | |
| 12 | func Test_createNewBuffer(t *testing.T) { |
| 13 | tests := []struct { |
| 14 | name string |
| 15 | }{ |
| 16 | {"Create empty buffer"}, |
| 17 | } |
| 18 | for _, tt := range tests { |
| 19 | t.Run(tt.name, func(t *testing.T) { |
| 20 | buf := createNewBuffer() |
| 21 | if buf == nil { |
| 22 | t.Error("createNewBuffer() returned nil") |
| 23 | return |
| 24 | } |
| 25 | if buf.rowLen != 0 || buf.colLen != 0 { |
| 26 | t.Error("New buffer should be empty") |
| 27 | } |
| 28 | }) |
| 29 | } |
| 30 | } |
| 31 | |
| 32 | func Test_createNewBufferWithData(t *testing.T) { |
| 33 | type args struct { |
nothing calls this directly
no test coverage detected