A Python parser for MediaWiki wikicode https://mwparserfromhell.readthedocs.io/
25'ten fazla konu seçemezsiniz Konular bir harf veya rakamla başlamalı, kısa çizgiler ('-') içerebilir ve en fazla 35 karakter uzunluğunda olabilir.

text.mwtest 4.9 KiB

1234567891011121314151617181920212223242526272829303132
  1. name: basic
  2. label: sanity check for basic text parsing, no gimmicks
  3. input: "foobar"
  4. output: [Text(text="foobar")]
  5. ---
  6. name: newlines
  7. label: slightly more complex text parsing, with newlines
  8. input: "This is a line of text.\nThis is another line of text.\nThis is another."
  9. output: [Text(text="This is a line of text.\nThis is another line of text.\nThis is another.")]
  10. ---
  11. name: unicode
  12. label: ensure unicode data is handled properly
  13. input: "Thís ís å sëñtënce with diœcritiçs."
  14. output: [Text(text="Thís ís å sëñtënce with diœcritiçs.")]
  15. ---
  16. name: unicode2
  17. label: additional unicode check for non-BMP codepoints
  18. input: "𐌲𐌿𐍄𐌰𐍂𐌰𐌶𐌳𐌰"
  19. output: [Text(text="𐌲𐌿𐍄𐌰𐍂𐌰𐌶𐌳𐌰")]
  20. ---
  21. name: large
  22. label: a lot of text, requiring proper storage in the C tokenizer
  23. input: "ZWfsZYcZyhGbkDYJiguJuuhsNyHGFkFhnjkbLJyXIygTHqcXdhsDkEOTSIKYlBiohLIkiXxvyebUyCGvvBcYqFdtcftGmaAanKXEIyYSEKlTfEEbdGhdePVwVImOyKiHSzAEuGyEVRIKPZaNjQsYqpqARIQfvAklFtQyTJVGlLwjJIxYkiqmHBmdOvTyNqJRbMvouoqXRyOhYDwowtkcZGSOcyzVxibQdnzhDYbrgbatUrlOMRvFSzmLWHRihtXnddwYadPgFWUOxAzAgddJVDXHerawdkrRuWaEXfuwQSkQUmLEJUmrgXDVlXCpciaisfuOUjBldElygamkkXbewzLucKRnAEBimIIotXeslRRhnqQjrypnLQvvdCsKFWPVTZaHvzJMFEahDHWcCbyXgxFvknWjhVfiLSDuFhGoFxqSvhjnnRZLmCMhmWeOgSoanDEInKTWHnbpKyUlabLppITDFF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