Skip to content

Conversation

@lumoswiz
Copy link
Collaborator

@lumoswiz lumoswiz commented Jan 6, 2026

Summary

Align ERC-20 module/facet behavior with ERC-20 returns and finish ERC20TransferFacet fuzz coverage per the shared ERC-20 tree.

Changes Made

  • Updated ERC20Mod approve/transfer/transferFrom to return bool.
  • Propagated return values through ERC20Harness.
  • Added ERC20TransferFacet base test and scaffolds for facet transfer/transferFrom tests.
  • Implemented ERC20TransferFacet fuzz tests covering all tree branches, including zero-amount paths.

Checklist

Before submitting this PR, please ensure:

  • Code follows the Solidity feature ban - No inheritance, constructors, modifiers, public/private variables, external library functions, using for directives, or selfdestruct

  • Code follows Design Principles - Readable, uses diamond storage, favors composition over inheritance

  • Code matches the codebase style - Consistent formatting, documentation, and patterns (e.g. ERC20Facet.sol)

  • Code is formatted with forge fmt

  • Existing tests pass - Run tests to be sure existing tests pass.

  • New tests are optional - If you don't provide tests for new functionality or changes then please create a new issue so this can be assigned to someone.

  • All tests pass - Run forge test and ensure everything works

  • Documentation updated - If applicable, update relevant documentation

@netlify
Copy link

netlify bot commented Jan 6, 2026

👷 Deploy request for compose-diamonds pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 78df956

@github-actions
Copy link

github-actions bot commented Jan 6, 2026

Coverage Report

Coverage

Metric Coverage Details
Lines 74% 1183/1605 lines
Functions 85% 295/349 functions
Branches 54% 122/224 branches

Last updated: Tue, 06 Jan 2026 20:42:05 GMT for commit 78df956

@github-actions
Copy link

github-actions bot commented Jan 6, 2026

Gas Report

No gas usage changes detected between main and test/erc20-transfer-facet.

All functions maintain the same gas costs. ✅

Last updated: Tue, 06 Jan 2026 20:42:29 GMT for commit 78df956

@lumoswiz lumoswiz merged commit c7c64b7 into Perfect-Abstractions:main Jan 6, 2026
5 checks passed
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