Refactor code safely with testing
refactorskillsetup L2★121
oasm-platform/open-asm ↗What it does
Refactor code while preserving behavior strictly
Best for
Internal code quality improvements (structure, typing, naming) without touching external contracts or logic when behavior preservation is non-negotiable
Inputs
- · source code files
- · existing test suite
- · refactoring scope definition
Outputs
- · restructured code
- · passing test results
- · linting report
Requires
- · eslint
- · test runner (Jest/etc)
Preconditions
All existing tests must pass before refactoring; test files must exist for every service file
Failure modes
Modifying public APIs; deleting tests; test failures not resolved; importing unexported symbols
Trust signals
- · strict behavior-preservation principle
- · mandatory baseline verification
- · per-step safety checklist