github的一些开源项目
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

147 lines
2.0 KiB

  1. # This set of tests is run only with the 8-bit library. It tests the POSIX
  2. # interface, which is supported only with the 8-bit library. This test should
  3. # not be run with JIT (which is not available for the POSIX interface).
  4. #forbid_utf
  5. #pattern posix
  6. # Test some invalid options
  7. /abc/auto_callout
  8. /abc/
  9. abc\=find_limits
  10. /abc/
  11. abc\=partial_hard
  12. /a(())bc/parens_nest_limit=1
  13. /abc/allow_surrogate_escapes,max_pattern_length=2
  14. # Real tests
  15. /abc/
  16. abc
  17. /^abc|def/
  18. abcdef
  19. abcdef\=notbol
  20. /.*((abc)$|(def))/
  21. defabc
  22. defabc\=noteol
  23. /the quick brown fox/
  24. the quick brown fox
  25. \= Expect no match
  26. The Quick Brown Fox
  27. /the quick brown fox/i
  28. the quick brown fox
  29. The Quick Brown Fox
  30. /(*LF)abc.def/
  31. \= Expect no match
  32. abc\ndef
  33. /(*LF)abc$/
  34. abc
  35. abc\n
  36. /(abc)\2/
  37. /(abc\1)/
  38. \= Expect no match
  39. abc
  40. /a*(b+)(z)(z)/
  41. aaaabbbbzzzz
  42. aaaabbbbzzzz\=ovector=0
  43. aaaabbbbzzzz\=ovector=1
  44. aaaabbbbzzzz\=ovector=2
  45. /(*ANY)ab.cd/
  46. ab-cd
  47. ab=cd
  48. \= Expect no match
  49. ab\ncd
  50. /ab.cd/s
  51. ab-cd
  52. ab=cd
  53. ab\ncd
  54. /a(b)c/posix_nosub
  55. abc
  56. /a(?P<name>b)c/posix_nosub
  57. abc
  58. /(a)\1/posix_nosub
  59. zaay
  60. /a?|b?/
  61. abc
  62. \= Expect no match
  63. ddd\=notempty
  64. /\w+A/
  65. CDAAAAB
  66. /\w+A/ungreedy
  67. CDAAAAB
  68. /\Biss\B/I,aftertext
  69. Mississippi
  70. /abc/\
  71. "(?(?C)"
  72. "(?(?C))"
  73. /abcd/substitute_extended
  74. /\[A]{1000000}**/expand,regerror_buffsize=31
  75. /\[A]{1000000}**/expand,regerror_buffsize=32
  76. //posix_nosub
  77. \=offset=70000
  78. /^d(e)$/posix
  79. acdef\=posix_startend=2:4
  80. acde\=posix_startend=2
  81. \= Expect no match
  82. acdef
  83. acdef\=posix_startend=2
  84. /^a\x{00}b$/posix
  85. a\x{00}b\=posix_startend=0:3
  86. /"A" 00 "B"/hex
  87. A\x{00}B\=posix_startend=0:3
  88. /ABC/use_length
  89. ABC
  90. /a\b(c/literal,posix
  91. a\\b(c
  92. /a\b(c/literal,posix,dotall
  93. /((a)(b)?(c))/posix
  94. 123ace
  95. 123ace\=posix_startend=2:6
  96. //posix
  97. \= Expect errors
  98. \=null_subject
  99. abc\=null_subject
  100. /(*LIMIT_HEAP=0)xx/posix
  101. \= Expect error
  102. xxxx
  103. # End of testdata/testinput18