summaryrefslogtreecommitdiff
path: root/_test/tests/inc/common_stripsourcemaps.test.php
diff options
context:
space:
mode:
authorGerrit Uitslag <klapinklapin@gmail.com>2014-09-28 15:36:21 +0200
committerGerrit Uitslag <klapinklapin@gmail.com>2014-09-28 15:36:21 +0200
commit0c1b02bead38d5a58032a1c88cf3ca53bbc4a4d9 (patch)
treeb9cb574a1964f28dda648795010a5be056b80618 /_test/tests/inc/common_stripsourcemaps.test.php
parent618191d008b98cb421694c541145c863d7b300ce (diff)
parentda9572711f54d13ce3c5506971154b0bc359723f (diff)
downloadrpg-0c1b02bead38d5a58032a1c88cf3ca53bbc4a4d9.tar.gz
rpg-0c1b02bead38d5a58032a1c88cf3ca53bbc4a4d9.tar.bz2
Merge remote-tracking branch 'origin/master' into FS#2697searchpagereadonly
Conflicts: inc/lang/hr/searchpage.txt inc/lang/ko/searchpage.txt
Diffstat (limited to '_test/tests/inc/common_stripsourcemaps.test.php')
-rw-r--r--_test/tests/inc/common_stripsourcemaps.test.php29
1 files changed, 29 insertions, 0 deletions
diff --git a/_test/tests/inc/common_stripsourcemaps.test.php b/_test/tests/inc/common_stripsourcemaps.test.php
new file mode 100644
index 000000000..c6a915dcf
--- /dev/null
+++ b/_test/tests/inc/common_stripsourcemaps.test.php
@@ -0,0 +1,29 @@
+<?php
+
+class common_stripsourcemaps_test extends DokuWikiTest {
+
+ function test_all() {
+
+ $text = <<<EOL
+//@ sourceMappingURL=/foo/bar/xxx.map
+//# sourceMappingURL=/foo/bar/xxx.map
+/*@ sourceMappingURL=/foo/bar/xxx.map */
+/*# sourceMappingURL=/foo/bar/xxx.map */
+bang
+EOL;
+
+ $expect = <<<EOL
+//
+//
+/**/
+/**/
+bang
+EOL;
+
+ stripsourcemaps($text);
+
+
+ $this->assertEquals($expect, $text);
+ }
+
+} \ No newline at end of file