The solution below shouldn't pass, add some tests to make it fail.
Good kata, but my proposal is that random string should not contain any numbers (should contain characters a-z).
Otherwise kata becomes very simple.
Title sounds interesting, idea is good, but the actual kata is very boring. Is this clickbait?
Not sure what you could do to improve it though.
oh gosh am I embarassed, left the number of iterations at 3 rather than 500 :/ also I did not think about a global being grabbed by the solution code, so I'll make that change too. Thank you!
The new tests only test tweetArray and . Then i already gets bigger than the current length. Incidentally, i implicitly is a global variable, because you don't have let or var in front of it. This is now possible.
You may want to while ( tweetArray.length ). And ramp up 3 a bit again, and let i. ( let has less subtleties than var. )
while ( tweetArray.length )
added messages to all failures, though I didn't know a great way to have the duplicate test give useful output without several more lines of code.
Side note: hope you don't talk to your team this way!
if you find a duplicate, please let me know! I really thought 'unique strings' would exist in this format, though while I found the opposite (detect IF strings are unique) I couldn't find this one.
length is resolved
"no because it won't pass the leng-"
good note, fixed
assertEquals takes its arguments in the order (actual,expected). When directly comparing user solution generated values to reference ( correct, expected ) values, having them switched around leads to major confusion.
This comment is hidden because it contains spoiler information about the solution
Your test failure messages are useless for debugging. Tell us what you tested!
I've done this before.
Also, you're not testing for "cannot be more than 180 characters" - you're testing for <180 instead of <=180.
This is just Vigenere cipher, which means it's a duplicate to at least http://www.codewars.com/kata/vigenere-cipher-helper.