Skip to content

Conversation

divinity76
Copy link
Contributor

@divinity76 divinity76 commented Jun 19, 2023

a bug in the regex would break getNice() if the current niceness was negative, which would make the whole test fail.

Previously:
this would fail:
time sudo nice --adjustment=-19 ./php run-tests.php -j$(nproc) -x --offline ext/standard/tests/general_functions/proc_nice_basic.phpt --color --show-all

and this would work:
time sudo ./php run-tests.php -j$(nproc) -x --offline ext/standard/tests/general_functions/proc_nice_basic.phpt --color --show-all

now they both work.

a bug in the regex would break getNice() if the current niceness was negative, which would make the whole test fail.

Previously:
this would fail:
time sudo nice --adjustment=-19 ./php run-tests.php -j$(nproc) -x --offline ext/standard/tests/general_functions/proc_nice_basic.phpt --color --show-all

and this would work: 
time sudo ./php run-tests.php -j$(nproc) -x --offline ext/standard/tests/general_functions/proc_nice_basic.phpt --color --show-all
Co-authored-by: Michael Voříšek <mvorisek@mvorisek.cz>
@iluuu1994 iluuu1994 merged commit 4960070 into php:master Jun 21, 2023
@iluuu1994
Copy link
Member

Thank you @divinity76!

iluuu1994 pushed a commit that referenced this pull request Sep 22, 2023
* support running testsuite with negative niceness

a bug in the regex would break getNice() if the current niceness was negative, which would make the whole test fail.

Previously:
this would fail:
time sudo nice --adjustment=-19 ./php run-tests.php -j$(nproc) -x --offline ext/standard/tests/general_functions/proc_nice_basic.phpt --color --show-all

and this would work: 
time sudo ./php run-tests.php -j$(nproc) -x --offline ext/standard/tests/general_functions/proc_nice_basic.phpt --color --show-all

* Update ext/standard/tests/general_functions/proc_nice_basic.phpt

Co-authored-by: Michael Voříšek <mvorisek@mvorisek.cz>

---------

Co-authored-by: Michael Voříšek <mvorisek@mvorisek.cz>
iluuu1994 added a commit that referenced this pull request Sep 22, 2023
* PHP-8.1:
  support running testsuite with negative niceness (#11481)
iluuu1994 added a commit that referenced this pull request Sep 22, 2023
* PHP-8.2:
  support running testsuite with negative niceness (#11481)
iluuu1994 added a commit that referenced this pull request Sep 22, 2023
* PHP-8.3:
  support running testsuite with negative niceness (#11481)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants