Closed sivasathyaseeelan closed 5 months ago
I will work on this issue. can anyone please assign me this issue?
You cannot do a unit test for this function as it requires the rpc interface.
This and many other fidelity things should be tested via integration test as described here.. https://github.com/utxo-teleport/teleport-transactions/issues/97
@wthrajat took up that issue, But Rajat if you are not currently doing it maybe @sivasathyaseeelan can take it up?
As @rajarshimaitra mentioned, the parent issue is #97, this issue should be closed; @sivasathyaseeelan, if you want to do it, you can start working on it. Make sure you keep this in mind ; )
Think adversarially about how many ways people can cheat on fidelity or attack a Maker by modifying their fidelity.
I have #80 and #116 on my plate right now so feel free to work on #97.
Issue Description: This issue highlights the need for unit tests for calculate_bond_value in src/wallet/fidelity.rs file. Currently, calculate_bond_value in this file are untested, which could lead to potential issues in the future.
Objective: Write unit tests for the calculate_bond_value function in the src/wallet/fidelity.rs file.
Details:
Cover all calculate_bond_value with appropriate test cases. Ensure tests validate functionality, handle edge cases, and check error conditions. Integrate the tests into our existing test suite.
https://app.codecov.io/github/utxo-teleport/teleport-transactions/blob/master/src%2Fwallet%2Ffidelity.rs