circular-buffer: Test overwrite on non-full buffer#180
circular-buffer: Test overwrite on non-full buffer#180soniakeys merged 1 commit intoexercism:masterfrom petertseng:circular-buffer-test
Conversation
|
Examining other language tracks: Tracks that include this test:
Tracks that do not include this test:
So it is possible that the Ruby track was the first to actually explicitly test this behavior of Overwrite (what should it do when the buffer isn't full), and I guess now's a good a time as any to ask whether it should be spread to the other tracks with circular-buffer. E: Yeah I see, it wasn't in the original version of Ruby circular-buffer but was added later in exercism/ruby@5560b7a for exercism/ruby#123 - so a test for that behavior got added to Ruby track but not ported over to other tracks as well, interesting to see that history. |
|
Assumption: I should bump E: done so. |
This test is useful to make sure implementations don't drop items from non-full buffers when using Overwrite.
|
Yeah, I think adding the test is a good idea. @soniakeys do you see any gotchas with this? |
|
Very nice. Thank you, Peter! |
circular-buffer: Test overwrite on non-full buffer
This test is useful to make sure implementations don't drop items from
non-full buffers when using Overwrite.