It's not perfect but I'm convinced it's a useful improvement for now.
tests: Randomize the context with probability 15/16 instead of 1/4 #1122
pull real-or-random wants to merge 1 commits into bitcoin-core:master from real-or-random:202207-test-randomization changing 1 files +6 −2-
real-or-random commented at 6:49 PM on July 7, 2022: contributor
-
tests: Randomize the context with probability 15/16 instead of 1/4 17065f48ae
-
in src/tests.c:7094 in 221d3aabf9 outdated
7090 | ctx = secp256k1_context_create(SECP256K1_CONTEXT_SIGN | SECP256K1_CONTEXT_VERIFY); 7091 | - if (secp256k1_testrand_bits(1)) { 7092 | + /* Randomize the context only with probability 15/16 7093 | + to make sure we test without context randomization from time to time. 7094 | + TODO Reconsider this when recalibrating the tests. */ 7095 | + if (!secp256k1_testrand_bits(4)) {
sipa commented at 1:59 PM on July 8, 2022:I think this implements randomization in 1/16 of the cases. Also, it randomizes with uninitialized memory?
real-or-random commented at 4:46 PM on July 8, 2022:Ha, this happens if you want to do a "quick" change...
Fixed.
Also, it randomizes with uninitialized memory?
Yeah, don't ask me why I removed this line.
real-or-random force-pushed on Jul 8, 2022sipa commented at 4:46 PM on July 8, 2022: contributorACK 17065f48ae261c6949dab74a7c197ac13b52eb1b
jonasnick commented at 11:16 AM on July 11, 2022: contributorACK 17065f48ae261c6949dab74a7c197ac13b52eb1b
jonasnick merged this on Jul 11, 2022jonasnick closed this on Jul 11, 2022dhruv referenced this in commit f70e7d8108 on Jul 20, 2022hebasto referenced this in commit 07695f6c2d on Jul 21, 2022dhruv referenced this in commit e5166959a4 on Jul 21, 2022dhruv referenced this in commit 726cbfe06c on Jul 21, 2022dhruv referenced this in commit c354ccd3e6 on Jul 21, 2022dhruv referenced this in commit 296cb3807d on Jul 21, 2022dhruv referenced this in commit a7efff1c21 on Jul 22, 2022dhruv referenced this in commit 5667aa958a on Aug 12, 2022dhruv referenced this in commit 06823cfe29 on Aug 24, 2022dhruv referenced this in commit 6eca30d4bd on Sep 2, 2022dhruv referenced this in commit c3ed192dda on Sep 2, 2022dhruv referenced this in commit 89ebab0601 on Oct 1, 2022dhruv referenced this in commit d6bcb105c3 on Oct 20, 2022dhruv referenced this in commit c27eb1e66a on Oct 20, 2022dhruv referenced this in commit a2e91d2816 on Oct 20, 2022dhruv referenced this in commit 0b21533c10 on Oct 21, 2022dhruv referenced this in commit 01dddb4cf6 on Oct 21, 2022dhruv referenced this in commit a0bb5b6946 on Nov 17, 2022dhruv referenced this in commit 2e4c03dd67 on Nov 17, 2022dhruv referenced this in commit 388c9b1b55 on Nov 21, 2022dhruv referenced this in commit 244eb87643 on Dec 7, 2022dhruv referenced this in commit 92cddabc43 on Dec 8, 2022sipa referenced this in commit 9d47e7b71b on Dec 13, 2022dhruv referenced this in commit 55ffd47cc6 on Dec 14, 2022dhruv referenced this in commit 967c65b158 on Dec 14, 2022dhruv referenced this in commit 78b5ddf28b on Jan 11, 2023dhruv referenced this in commit 215394a1d5 on Jan 11, 2023div72 referenced this in commit 945b094575 on Mar 14, 2023str4d referenced this in commit 0df7b459f6 on Apr 21, 2023vmta referenced this in commit e1120c94a1 on Jun 4, 2023vmta referenced this in commit 8f03457eed on Jul 1, 2023jonasnick cross-referenced this on Jul 17, 2023 from issue Upstream PRs 1056, 1104, 1105, 1084, 1114, 1115, 1116, 1120, 1122, 1121, 1128, 1131, 1144, 1150, 1146 by jonasnickContributors
github-metadata-mirror
This is a metadata mirror of the GitHub repository bitcoin-core/secp256k1. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-05-01 14:15 UTC
This is a metadata mirror of the GitHub repository bitcoin-core/secp256k1. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-05-01 14:15 UTC
This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me
More mirrored repositories can be found on mirror.b10c.me