aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/bookmark/LinkUtilsTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/bookmark/LinkUtilsTest.php')
-rw-r--r--tests/bookmark/LinkUtilsTest.php22
1 files changed, 11 insertions, 11 deletions
diff --git a/tests/bookmark/LinkUtilsTest.php b/tests/bookmark/LinkUtilsTest.php
index 7d4a7b89..a7087953 100644
--- a/tests/bookmark/LinkUtilsTest.php
+++ b/tests/bookmark/LinkUtilsTest.php
@@ -2,7 +2,7 @@
2 2
3namespace Shaarli\Bookmark; 3namespace Shaarli\Bookmark;
4 4
5use PHPUnit\Framework\TestCase; 5use Shaarli\TestCase;
6 6
7require_once 'tests/utils/CurlUtils.php'; 7require_once 'tests/utils/CurlUtils.php';
8 8
@@ -437,13 +437,13 @@ class LinkUtilsTest extends TestCase
437 カタカナ #カタカナ」カタカナ\n'; 437 カタカナ #カタカナ」カタカナ\n';
438 $autolinkedDescription = hashtag_autolink($rawDescription, $index); 438 $autolinkedDescription = hashtag_autolink($rawDescription, $index);
439 439
440 $this->assertContains($this->getHashtagLink('hashtag', $index), $autolinkedDescription); 440 $this->assertContainsPolyfill($this->getHashtagLink('hashtag', $index), $autolinkedDescription);
441 $this->assertNotContains(' #hashtag', $autolinkedDescription); 441 $this->assertNotContainsPolyfill(' #hashtag', $autolinkedDescription);
442 $this->assertNotContains('>#nothashtag', $autolinkedDescription); 442 $this->assertNotContainsPolyfill('>#nothashtag', $autolinkedDescription);
443 $this->assertContains($this->getHashtagLink('ашок', $index), $autolinkedDescription); 443 $this->assertContainsPolyfill($this->getHashtagLink('ашок', $index), $autolinkedDescription);
444 $this->assertContains($this->getHashtagLink('カタカナ', $index), $autolinkedDescription); 444 $this->assertContainsPolyfill($this->getHashtagLink('カタカナ', $index), $autolinkedDescription);
445 $this->assertContains($this->getHashtagLink('hashtag_hashtag', $index), $autolinkedDescription); 445 $this->assertContainsPolyfill($this->getHashtagLink('hashtag_hashtag', $index), $autolinkedDescription);
446 $this->assertNotContains($this->getHashtagLink('hashtag-nothashtag', $index), $autolinkedDescription); 446 $this->assertNotContainsPolyfill($this->getHashtagLink('hashtag-nothashtag', $index), $autolinkedDescription);
447 } 447 }
448 448
449 /** 449 /**
@@ -454,9 +454,9 @@ class LinkUtilsTest extends TestCase
454 $rawDescription = 'blabla #hashtag x#nothashtag'; 454 $rawDescription = 'blabla #hashtag x#nothashtag';
455 $autolinkedDescription = hashtag_autolink($rawDescription); 455 $autolinkedDescription = hashtag_autolink($rawDescription);
456 456
457 $this->assertContains($this->getHashtagLink('hashtag'), $autolinkedDescription); 457 $this->assertContainsPolyfill($this->getHashtagLink('hashtag'), $autolinkedDescription);
458 $this->assertNotContains(' #hashtag', $autolinkedDescription); 458 $this->assertNotContainsPolyfill(' #hashtag', $autolinkedDescription);
459 $this->assertNotContains('>#nothashtag', $autolinkedDescription); 459 $this->assertNotContainsPolyfill('>#nothashtag', $autolinkedDescription);
460 } 460 }
461 461
462 /** 462 /**