Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
Is this meant to be a golfing kata? The description is extremely unclear as to what is expected here.
My friends will help me to solve those problems, but they cannot fork while in draft status, so I need to publish it.
Unpublishing until the issues reported below get fixed.
.
.
.
True 👍
unfortunately
Tests are vulnerable to input mutation.
I'll admit this is a weird one.
Just don't reuse inputs; declare a new input for every test, and this won't happen.
Frankly, it was not very effective as I wrote kata for the first time and I looked at the test logic from many places, but we can say that it was unsuccessful and yes, I will try to solve the test logic.
You'd think this is impossible. But it really happens, because of the way
chai
executes code out of order. It turns outarr.length = 0
is executed before the assertion in theit
.Testing with an example solution that depends on the input being non-empty could have prevented this.
So you published without random tests again, making other, different, rookie mistakes as well. Read more documentation, read more tests of kata you solved, and get more reviews on Discord before publishing. Support is available if only you'll take it.
One of these days you might publish a kata without it getting unpublished immediately.
Submit tests do not include fixed tests, which makes it possible to fail the example tests but pass the submit tests. That should never happen. Always copy the example tests into the submit tests as fixed tests.
Random tests generate empty input, which are out of spec.
Loading more items...