Add math/rand[/v2] wrappers in tests/antithesis and replace the rand references with the wrappers#22017
Add math/rand[/v2] wrappers in tests/antithesis and replace the rand references with the wrappers#22017nwnt wants to merge 2 commits into
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: nwnt The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Sorry this took me some time; I actually went with a totally different route implementing a custom ast parser to change the code dynamically since antithesis's random is not a drop-in replace for `math/rand[/v2]'. Later found it way too complicated, and switched back to this approach instead. |
a020e8e to
3e0668c
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted filessee 22 files with indirect coverage changes @@ Coverage Diff @@
## main #22017 +/- ##
==========================================
- Coverage 69.76% 69.70% -0.07%
==========================================
Files 449 449
Lines 38163 38177 +14
==========================================
- Hits 26626 26610 -16
- Misses 10112 10140 +28
- Partials 1425 1427 +2 Continue to review full report in Codecov by Harness.
🚀 New features to boost your workflow:
|
|
/retest |
3e0668c to
4c78eef
Compare
Signed-off-by: Nont <9658731+nwnt@users.noreply.github.com>
4c78eef to
d34dbdc
Compare
|
Content of all go mod with replace. |
634e592 to
81b4696
Compare
|
@serathius this should be ready for another review now. Let me know if it's better to split them into a smaller PR. |
81b4696 to
28558dc
Compare
9ae3c7b to
6a8f06d
Compare
Signed-off-by: Nont <9658731+nwnt@users.noreply.github.com>
6a8f06d to
134f3e2
Compare
| require ( | ||
| github.com/anishathalye/porcupine v1.1.0 | ||
| github.com/antithesishq/antithesis-sdk-go v0.4.3 | ||
| github.com/antithesishq/antithesis-sdk-go v0.7.2 |
There was a problem hiding this comment.
Can you split the PR to update the dependency? As you pointed out during meeting there were problems with package stability. Let's test new package version first.
|
@nwnt: The following tests failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
First step for #21720
I'm adding two wrappers of antithesis's random in which they will be drop-in replacements of
math/randandmath/rand/v2. They need to be merged to main first before I can replace all of the occurrences ofmath/rand[/v2' with them as the server dockerfile clones frommain` to build it. In other words, if these don't exist in main, docker build can replace it but won't be able to build because main doesn't contain them.Once merged, I will follow up with another commit to introduce the
sedreplacements. Here is an excerpt of what the code looks like after replaced:cc @serathius @henrybear327 @ivanvc