This document provides top-level information to agents (Claude Code etc.). It is loaded into context automatically for all sessions in this repo, so keep it concise!
All Cadence test files are located in:
cadence/tests/*_test.cdc
make testTo run a specific test file:
flow test <path/to/test_file.cdc>Example:
flow test cadence/tests/random_test.cdcIMPORTANT: To run a specific test function by name, you must specify the file path:
flow test <path/to/test_file.cdc> --name <test_function_name>Example:
flow test cadence/tests/random_test.cdc --name testSomeFunctiongrep "fun test" cadence/tests/random_test.cdcmake lintRun both lint and tests:
make ci- Use red-green TDD for bug fixes and extensions to functionality. Tests must use assertions (eg.
Test.assert) to verify expected behaviour, not logs. - Use string templating, not concatenation:
"Hello \(name)"not"Hello ".concat(name)