implementation-workflow
스타15
포크5
업데이트2026년 2월 11일 21:16
TDD workflow for implementing features
설치
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
파일 탐색기
3 개 파일SKILL.md
readonly메뉴
TDD workflow for implementing features
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
| name | Implementation Workflow |
| description | TDD workflow for implementing features |
| Template | Usage |
|---|---|
templates/test_module.md | Test module structure |
templates/module_structure.md | DDD structure for new module |
Read existing documentation
GLOBAL_APP_DESCRIPTION.md for global contextdocs/STRATEGIES.md if related to tradingIdentify affected modules
Verify architecture
domain/ → Pure business logic, no I/O
application/ → Orchestration, services, use cases
infrastructure/ → I/O, external APIs, persistence
Fundamental rule: Tests are written BEFORE implementation code.
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn test_new_feature_basic_case() {
// Arrange
let input = ...;
// Act
let result = new_feature(input);
// Assert
assert_eq!(result, expected);
}
#[test]
fn test_new_feature_edge_case() {
// Test edge cases
}
#[test]
fn test_new_feature_error_case() {
// Test error cases
}
}
Tests MUST fail at this stage (red phase).
.unwrap() in production codeDecimal for amounts// ❌ Avoid
fn process(value: f64) -> f64 {
some_operation(value).unwrap()
}
// ✅ Prefer
fn process(value: Decimal) -> Result<Decimal, ProcessError> {
some_operation(value).map_err(ProcessError::from)
}
Clean the code
Add documentation
Verify with clippy
cargo clippy --all-targets -- -D warnings
Invoke the testing skill
Invoke the documentation skill
// 1. First the test
#[test]
fn test_calculate_position_size() {
let capital = Decimal::from(10000);
let risk_pct = Decimal::from_str("0.02").unwrap();
let stop_loss = Decimal::from_str("0.05").unwrap();
let size = calculate_position_size(capital, risk_pct, stop_loss);
assert_eq!(size, Decimal::from(4000)); // 2% risk, 5% stop = 40% position
}
// 2. Then the implementation
pub fn calculate_position_size(
capital: Decimal,
risk_percentage: Decimal,
stop_loss_percentage: Decimal,
) -> Decimal {
let risk_amount = capital * risk_percentage;
risk_amount / stop_loss_percentage
}
| Anti-pattern | Problem | Solution |
|---|---|---|
| Tests after code | Confirmation bias | Strict TDD |
.unwrap() everywhere | Panics in production | Error handling |
f64 for money | Rounding errors | Decimal |
| Tests without assertions | False positives | At least one assertion per test |
| Modify tests to pass | Hides bugs | Fix the code |
| Commented-out code | Clutters codebase | Remove it (use git history) |
Test and validation workflow before commit
Keep project documentation up to date
Manage and enforce project specifications for consistency
Designing premium user interfaces with egui
Critical analysis of trading techniques and financial innovation
Trading performance evaluation via backtesting and metrics