Created
July 3, 2014 12:10
-
-
Save timaschew/04b98ca782edf391efee to your computer and use it in GitHub Desktop.
edge case tests for a palindrom checker, can you implement it?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe 'palindrome checker', -> | |
it 'should work for unicode characters (chinese)', (done) -> | |
expect(palindromChecka "楚人楚").to.equal true | |
done() | |
# http://apps.timwhitlock.info/emoji/tables/unicode | |
it 'should work with 3 byte unicode chars (emoji, unicode)', (done) -> | |
expect(palindromChecka "\u2764").to.equal true | |
done() | |
it 'should work with 4 byte unicode chars (emoji, raw)', (done) -> | |
expect(palindromChecka "😁").to.equal true | |
done() | |
it 'should work with 4 byte unicode chars (emoji, unicode)', (done) -> | |
expect(palindromChecka "\u1F601").to.equal true | |
done() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment