(b *testing.B)
| 99 | } |
| 100 | |
| 101 | func BenchmarkCopyMatrix(b *testing.B) { |
| 102 | // Create a matrix for benchmarking |
| 103 | rows := 100 |
| 104 | columns := 100 |
| 105 | initialValue := 0 |
| 106 | matrix := matrix.New(rows, columns, initialValue) |
| 107 | |
| 108 | // Reset the benchmark timer |
| 109 | b.ResetTimer() |
| 110 | |
| 111 | // Run the benchmarks |
| 112 | for i := 0; i < b.N; i++ { |
| 113 | _, _ = matrix.Copy() |
| 114 | } |
| 115 | } |