Skip to content
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

refactor testing addresses #2507

Merged
merged 19 commits into from
Feb 27, 2024
Merged

refactor testing addresses #2507

merged 19 commits into from
Feb 27, 2024

Conversation

tzemanovic
Copy link
Member

@tzemanovic tzemanovic commented Feb 2, 2024

Describe your changes

Moved the hardcoded addresses used for testing under conditional compilation for tests only to prevent their use in non-test code

Indicate on which release or other PRs this topic is based on

#2506 - https://github.com/anoma/namada/pull/2507/files/224798f39fa031f82e958544e2e3bc9424488814..d44bf1e2c242e076ca96e23c1e27dfba663c12b2

Checklist before merging to draft

  • I have added a changelog
  • Git history is in acceptable state

tzemanovic added a commit that referenced this pull request Feb 2, 2024
@tzemanovic tzemanovic marked this pull request as ready for review February 2, 2024 10:37
@tzemanovic tzemanovic marked this pull request as draft February 2, 2024 10:48
@tzemanovic tzemanovic added the modularization Part of Namada's modularization effort label Feb 2, 2024
tzemanovic added a commit that referenced this pull request Feb 2, 2024
@tzemanovic tzemanovic force-pushed the tomas/refactor-testing-addrs branch from bbe9391 to 733bf79 Compare February 2, 2024 10:56
@tzemanovic tzemanovic marked this pull request as ready for review February 2, 2024 10:57
@tzemanovic tzemanovic marked this pull request as draft February 2, 2024 11:46
tzemanovic added a commit that referenced this pull request Feb 2, 2024
@tzemanovic tzemanovic force-pushed the tomas/refactor-testing-addrs branch from 733bf79 to 782f048 Compare February 2, 2024 11:47
@tzemanovic tzemanovic marked this pull request as ready for review February 2, 2024 11:48
This was referenced Feb 2, 2024
tzemanovic added a commit that referenced this pull request Feb 5, 2024
@tzemanovic tzemanovic force-pushed the tomas/refactor-testing-addrs branch from 782f048 to ced19df Compare February 5, 2024 13:44
tzemanovic added a commit that referenced this pull request Feb 6, 2024
* tomas/refactor-testing-addrs:
  changelog: add #2507
  core: prevent from using addresses for testing in non-test code
  changelog: add #2506
  gov: replace namada_state dep with namada_storage
  changelog: add #2503
  update all core types usages
  core: flatten types mod
  update replay_protection usage
  core: factor out the ledger::replay_protection mod into a new crate
  core: refactor out ledger::eth_bridge mod
  changelog: add #2493
  benches: fix the shell to update conversions on new epochs
  move shielded params from core into shielded_token
  move inflation from core to trans_token
  replace namada_state usage with namada_storage in token crates
  changelog: add #2482
  refactor finalize_block PoS updates
  refactor finalize_block governance updates
  refactor finalize_block token updates
@brentstone brentstone mentioned this pull request Feb 8, 2024
@tzemanovic tzemanovic force-pushed the tomas/refactor-testing-addrs branch from ced19df to d44bf1e Compare February 19, 2024 15:09
Copy link

codecov bot commented Feb 19, 2024

Codecov Report

Attention: Patch coverage is 77.77778% with 186 lines in your changes are missing coverage. Please review.

Project coverage is 53.37%. Comparing base (c733be2) to head (d44bf1e).
Report is 79 commits behind head on main.

Files Patch % Lines
crates/core/src/event.rs 47.87% 49 Missing ⚠️
crates/proof_of_stake/src/lib.rs 78.94% 36 Missing ⚠️
crates/storage/src/mockdb.rs 51.42% 17 Missing ⚠️
crates/shielded_token/src/lib.rs 26.31% 14 Missing ⚠️
crates/core/src/address.rs 75.00% 13 Missing ⚠️
crates/apps/src/lib/bench_utils.rs 0.00% 10 Missing ⚠️
crates/governance/src/storage/mod.rs 46.15% 7 Missing ⚠️
crates/sdk/src/masp.rs 0.00% 6 Missing ⚠️
crates/storage/src/lib.rs 87.87% 4 Missing ⚠️
crates/apps/src/lib/config/genesis/transactions.rs 70.00% 3 Missing ⚠️
... and 17 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2507      +/-   ##
==========================================
- Coverage   53.38%   53.37%   -0.01%     
==========================================
  Files         302      305       +3     
  Lines      103403   103354      -49     
==========================================
- Hits        55198    55169      -29     
+ Misses      48205    48185      -20     

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

@grarco grarco self-requested a review February 21, 2024 19:33
tzemanovic added a commit that referenced this pull request Feb 22, 2024
* tomas/refactor-testing-addrs:
  changelog: add #2507
  core: prevent from using addresses for testing in non-test code
tzemanovic added a commit that referenced this pull request Feb 23, 2024
* tomas/refactor-testing-addrs:
  changelog: add #2507
  core: prevent from using addresses for testing in non-test code
@tzemanovic tzemanovic merged commit e6086cf into main Feb 27, 2024
16 of 17 checks passed
@tzemanovic tzemanovic deleted the tomas/refactor-testing-addrs branch February 27, 2024 21:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
modularization Part of Namada's modularization effort non-breaking-change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants