mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-06 17:13:24 -05:00
sage: tweak cpu threshold to decrease test flakiness
(cherry picked from commit 1acf7f6f3e)
This commit is contained in:
parent
42e86618c7
commit
e4c3e2d185
2 changed files with 35 additions and 0 deletions
|
|
@ -0,0 +1,32 @@
|
|||
diff --git a/src/sage/doctest/test.py b/src/sage/doctest/test.py
|
||||
index 812f8167c12..a4822642f0c 100644
|
||||
--- a/src/sage/doctest/test.py
|
||||
+++ b/src/sage/doctest/test.py
|
||||
@@ -49,11 +49,11 @@ Check that :issue:`2235` has been fixed::
|
||||
|
||||
Check slow doctest warnings are correctly raised::
|
||||
|
||||
- sage: subprocess.call(["python3", "-m", "sage.doctest", "--warn-long", # long time
|
||||
+ sage: subprocess.call(["python3", "-m", "sage.doctest", "--warn-long", "0.2", # long time
|
||||
....: "--random-seed=0", "--optional=sage", "sleep2.rst"], **kwds)
|
||||
Running doctests...
|
||||
Doctesting 1 file.
|
||||
- ... --warn-long --random-seed=0 sleep2.rst
|
||||
+ ... --warn-long 0.2 --random-seed=0 sleep2.rst
|
||||
**********************************************************************
|
||||
File "sleep2.rst", line 4, in sage.doctest.tests.sleep2
|
||||
Warning: slow doctest:
|
||||
@@ -66,11 +66,11 @@ Check slow doctest warnings are correctly raised::
|
||||
----------------------------------------------------------------------
|
||||
...
|
||||
0
|
||||
- sage: subprocess.call(["python3", "-m", "sage.doctest", "--format=github", "--warn-long", # long time
|
||||
+ sage: subprocess.call(["python3", "-m", "sage.doctest", "--format=github", "--warn-long", "0.2", # long time
|
||||
....: "--random-seed=0", "--optional=sage", "sleep2.rst"], **kwds)
|
||||
Running doctests...
|
||||
Doctesting 1 file.
|
||||
- ... --warn-long --random-seed=0 sleep2.rst
|
||||
+ ... --warn-long 0.2 --random-seed=0 sleep2.rst
|
||||
**********************************************************************
|
||||
::warning title=Warning: slow doctest:,file=sleep2.rst,line=4::slow doctest:: Test ran for ...s cpu, ...s wall%0ACheck ran for ...s cpu, ...s wall%0A
|
||||
while walltime(t) < 2: pass
|
||||
|
|
@ -78,6 +78,9 @@ stdenv.mkDerivation rec {
|
|||
# a more conservative version of https://github.com/sagemath/sage/pull/37951
|
||||
./patches/gap-element-crash.patch
|
||||
|
||||
# https://github.com/sagemath/sage/issues/42473
|
||||
./patches/lower-sleep2-test-threshold.patch
|
||||
|
||||
# https://github.com/sagemath/sage/pull/42009, landed in 10.10.beta0
|
||||
(fetchpatch2 {
|
||||
name = "gap-root-paths.patch";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue