add Javascript and Ruby specs for unique substrings