(t *testing.T)
| 102 | } |
| 103 | |
| 104 | func TestQueuePeekOutOfRangePanics(t *testing.T) { |
| 105 | q := New() |
| 106 | |
| 107 | assertPanics(t, "should panic when peeking empty queue", func() { |
| 108 | q.Peek() |
| 109 | }) |
| 110 | |
| 111 | q.Add(1) |
| 112 | q.Remove() |
| 113 | |
| 114 | assertPanics(t, "should panic when peeking emptied queue", func() { |
| 115 | q.Peek() |
| 116 | }) |
| 117 | } |
| 118 | |
| 119 | func TestQueueRemoveOutOfRangePanics(t *testing.T) { |
| 120 | q := New() |
nothing calls this directly
no test coverage detected
searching dependent graphs…