How to test String.prototype.includes in PhantomJS?

Posted by Andre Scott | Updated on

If you want to test String.prototype.includes in PhantomJS? Apparently PhantomJS doesn’t implement ES6 features properly. Luckily String.prototype.includes is quite easy to polyfill. You can choose if you want to do that in the test suite or the controller.


If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.

Related Questions & Answers