���ѧۧݧ�ӧ�� �ާ֧ߧ֧էا֧� - ���֧էѧܧ�ڧ��ӧѧ�� - /home/rickpfrv/wiki.craftaro.com/tests/phpunit/unit/includes/libs/JsMinPlusTest.php
���ѧ٧ѧ�
<?php /** * @covers JsMinPlus */ class JsMinPlusTest extends PHPUnit\Framework\TestCase { public static function provideValidInputs() { // If an implementation matches inputs using a regex with runaway backtracking, // then inputs with more than ~3072 repetitions are likely to fail (T299537). $input = '"' . str_repeat( 'x', 10000 ) . '";'; yield 'double quote string 10K' => [ $input ]; $input = '\'' . str_repeat( 'x', 10000 ) . '\';'; yield 'single quote string 10K' => [ $input ]; $input = '"' . str_repeat( '\u0021', 100 ) . '";'; yield 'escaping string 100' => [ $input ]; $input = '"' . str_repeat( '\u0021', 10000 ) . '";'; yield 'escaping string 10K' => [ $input ]; $input = '/' . str_repeat( 'x', 1000 ) . '/;'; yield 'regex 1K' => [ $input ]; $input = '/' . str_repeat( 'x', 10000 ) . '/;'; yield 'regex 10K' => [ $input ]; $input = '/' . str_repeat( '\u0021', 100 ) . '/;'; yield 'escaping regex 100' => [ $input ]; $input = '/' . str_repeat( '\u0021', 10000 ) . '/;'; yield 'escaping regex 10K' => [ $input ]; } /** * @dataProvider provideValidInputs * @doesNotPerformAssertions */ public function testLongStrings( string $input ) { // Ensure no parse error thrown JSMinPlus::minify( $input ); } }
| ver. 1.4 |
Github
|
.
| PHP 7.4.33 | ���֧ߧ֧�ѧ�ڧ� ����ѧߧڧ��: 0 |
proxy
|
phpinfo
|
���ѧ����ۧܧ�