Skip to content

Remove usage of srand() and rand() functions #304

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

corentin-prigent
Copy link
Contributor

@corentin-prigent corentin-prigent commented May 28, 2025

2D mesh generation is comprised of two steps:

  1. Insertion of all points given by the user, using Delaunay method, regardless of any user-provided edges.
  2. Verification that all user-provided edges are in the mesh. If some edges are missing, enforce their presence by performing swaps.

The second step uses srand() and rand() functions in order to travel missing edges (that are being enforced) in a random order. This could lead some outputs to be non-deterministic if some edges were not possible to enforce.

Copy link

codecov bot commented May 28, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 50.25%. Comparing base (4e2f535) to head (9464990).

Additional details and impacted files
@@             Coverage Diff             @@
##           develop     #304      +/-   ##
===========================================
- Coverage    50.31%   50.25%   -0.07%     
===========================================
  Files          177      177              
  Lines        47881    47895      +14     
  Branches     10362    10361       -1     
===========================================
- Hits         24093    24070      -23     
- Misses       16047    16087      +40     
+ Partials      7741     7738       -3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant