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.
In random tests there were still times with single digit after ":". Also, I find it a bit non logic that if current time is 22:42 and it takes me 429 minutes to get to the station the answer should be 5:00 and not 6:00 (5:51 rounded to next 30). Makes it look like I suddenly got wings or something.
Some random tests have invalid times like these for example: 2:6, 11:3
My code failed on this test case: 22:42 and 429
Expected: 'The next train is at 5:00.', instead got: 'The next train is at 6:00.'
Time after 429 minutes is 5:51 so 6:00 (or 06:00 if hours must be formatted with 2 digits) should be correct, right?
In C# tests Assert.AreEqual function parameters seem to be in wrong order (should be expected first and actual second). As a result of this failed test reports expected value as "but was" and wrong value as "expected".
Thanks for the kata! :) Maybe add some sample tests?
Some sample tests should be added. Currently sample test area has some test template not related to the Kata.
C# has tests with Assert.AreEqual called with parameters in wrong order. Correct format is: Assert.AreEqual(expected, actual)
C# code won't compile without changing namespace first. I believe that kind of thing shouldn't be necessary unless purpose of Kata is especially bug fixing.
Nice kata but the Example Tests section has the right curly brace of the TimeTest class missing.
You're welcome and thanks for the kata. I enjoyed it! :)
Yes, those errors are gone now. Thanks! There's something in the description that should be changed. It says: "The function should return an empty array if any of the following conditions are met:..." but tests (under TestInvalid) expect null instead of empty string array. Also, for me it's a bit unclear how the price currency is decided. Is it by the paidType?
There's something wrong in C# version.
My code works ok with 'Run Tests' but when I click 'Submit' the following error is thrown:
If I rename the namespace Kata -> MonetaryUnit then following errors appear:
That it was! Finally finished this great kata! :D
Ok, I'll give that a try. Thanks Steffen! :)
Have you had chance to view my code to see if the problem is by rounding or if there is other error in my code?
This comment is hidden because it contains spoiler information about the solution
Loading more items...