spoofchecker_002.phpt 517 B

12345678910111213141516171819202122
  1. --TEST--
  2. spoofchecker confusable tests
  3. --EXTENSIONS--
  4. intl
  5. --SKIPIF--
  6. <?php if(!class_exists("Spoofchecker")) print 'skip'; ?>
  7. --FILE--
  8. <?php
  9. $url = "http://www.payp\xD0\xB0l.com";
  10. $x = new Spoofchecker();
  11. echo "Checking if words are confusable\n";
  12. var_dump($x->areConfusable("hello, world", "goodbye, world"));
  13. var_dump($x->areConfusable("hello, world", "hello, world"));
  14. var_dump($x->areConfusable("hello, world", "he11o, wor1d"));
  15. ?>
  16. --EXPECT--
  17. Checking if words are confusable
  18. bool(false)
  19. bool(true)
  20. bool(true)