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.
What failures are you getting? I cannot see your solution so I've no way to know what it is happening unfortunately.
This comment is hidden because it contains spoiler information about the solution
I think I have fixed this now.
OK, I am pretty sure the tests for JS are doing that already.
.
Do you have some detail on the test results you're getting? What's failing specifically?
I agree that where a random is involved that it is perfectly valid (however unlikely) for all results to be same, all uppercase and all lowercase. What I am unclear on is how this can be tested any better? That's what I am interested to hear more about. Is there something you did in your tests that I am missing or not understand this attempts to mitigate this issues?
This comment is hidden because it contains spoiler information about the solution
I am not keen on having RandomCaseTester in preloaded coded because it means that the implementer cannot see what it is doing from the Sample Test Cases.
The JavaScript tests are defined as:
which keeps it nice and simple.
Please also ensure that you've covered all the cases that the JS test cases encompass:
Phone numbers may or may not have a leading zero, contain formatting for country or area codes and additional information such as extension numbers etc.
Whereas a credit card number can be a string or when stripped of whitespace an integer.
This is also one little hurdle to throw into the kata to make it a touch more difficult/require some thought.
I cannot merge this one as the description has now diverged - please could you update your kumite with the new description from the master kata?
Also please could you add two more tests for visa? This is from the JS tests:
This prevents invalid regex (
\d{12,15}
- should be(\d{12}|\d{15})
) from matching.You're right - that was an oversight in the tests. I've now added a couple tests to all the languages to prevent this from passing.
The solution in Java was even exploiting this!
Was a real PITA as I had to republish after changing each language - if I did them all at once it kept coming back saying the server had timed out!
Anyway should be fixed now for all langs.
@GiacomoSorbi - I cannot see the difference between what you're doing in Ruby and Crystal versus the tests mentioned above - they're both going to fail @dinglemouse tossing as far as I can see. Am I missing something?
Weird I didn't get notified about the crystal one so thanks for the link. Is there some way to see all the kumite against a given kata?
@dinglemouse Meh. It's open to collaborators, so please feel free to do better than me.
Loading more items...