docs: API 통합 프로젝트 계획 및 Flow Test 스펙 추가
- INDEX.md: TODO.md 링크 추가 - TODO.md: 프로젝트 할일 목록 신규 생성 - plans/flow-tests/: Flow Tester 테스트 시나리오 JSON 추가 - auth-api-flow.json: 인증 API 플로우 테스트 - pricing-validation-test.json: 가격 검증 테스트 - projects/api-integration/: 마이그레이션 계획 문서 - MASTER_PLAN.md: 전체 마이그레이션 전략 - PROGRESS.md: 진행 상황 추적 - WORKFLOW.md: 작업 워크플로우 - phase-1 ~ phase-4: 단계별 상세 계획 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
124
plans/flow-tests/auth-api-flow.json
Normal file
124
plans/flow-tests/auth-api-flow.json
Normal file
@@ -0,0 +1,124 @@
|
||||
{
|
||||
"name": "Auth API Flow Test",
|
||||
"description": "인증 API 전체 플로우 테스트 - 로그인, 프로필 조회, 토큰 갱신, 로그아웃",
|
||||
"version": "1.0",
|
||||
"config": {
|
||||
"baseUrl": "",
|
||||
"timeout": 30000,
|
||||
"stopOnFailure": true
|
||||
},
|
||||
"variables": {
|
||||
"user_id": "{{$env.FLOW_TESTER_USER_ID}}",
|
||||
"user_pwd": "{{$env.FLOW_TESTER_USER_PWD}}"
|
||||
},
|
||||
"steps": [
|
||||
{
|
||||
"id": "login",
|
||||
"name": "1. 로그인",
|
||||
"description": "access_token, refresh_token 획득",
|
||||
"method": "POST",
|
||||
"endpoint": "/login",
|
||||
"body": {
|
||||
"user_id": "{{user_id}}",
|
||||
"user_pwd": "{{user_pwd}}"
|
||||
},
|
||||
"expect": {
|
||||
"status": [200],
|
||||
"jsonPath": {
|
||||
"$.access_token": "@isString",
|
||||
"$.refresh_token": "@isString"
|
||||
}
|
||||
},
|
||||
"extract": {
|
||||
"access_token": "$.access_token",
|
||||
"refresh_token": "$.refresh_token"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "get_profile",
|
||||
"name": "2. 프로필 조회",
|
||||
"description": "access_token으로 현재 사용자 정보 조회",
|
||||
"method": "GET",
|
||||
"endpoint": "/users/me",
|
||||
"headers": {
|
||||
"Authorization": "Bearer {{login.access_token}}"
|
||||
},
|
||||
"expect": {
|
||||
"status": [200],
|
||||
"jsonPath": {
|
||||
"$.success": true,
|
||||
"$.data.id": "@isNumber"
|
||||
}
|
||||
},
|
||||
"extract": {
|
||||
"user_id": "$.data.id",
|
||||
"user_name": "$.data.name"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "refresh_token",
|
||||
"name": "3. 토큰 갱신",
|
||||
"description": "refresh_token으로 새 access_token 발급",
|
||||
"method": "POST",
|
||||
"endpoint": "/refresh",
|
||||
"body": {
|
||||
"refresh_token": "{{login.refresh_token}}"
|
||||
},
|
||||
"expect": {
|
||||
"status": [200],
|
||||
"jsonPath": {
|
||||
"$.access_token": "@isString"
|
||||
}
|
||||
},
|
||||
"extract": {
|
||||
"new_access_token": "$.access_token"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "verify_new_token",
|
||||
"name": "4. 새 토큰으로 프로필 조회",
|
||||
"description": "갱신된 토큰으로 API 호출 가능 확인",
|
||||
"method": "GET",
|
||||
"endpoint": "/users/me",
|
||||
"headers": {
|
||||
"Authorization": "Bearer {{refresh_token.new_access_token}}"
|
||||
},
|
||||
"expect": {
|
||||
"status": [200],
|
||||
"jsonPath": {
|
||||
"$.success": true
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "logout",
|
||||
"name": "5. 로그아웃",
|
||||
"description": "새 access_token으로 로그아웃",
|
||||
"method": "POST",
|
||||
"endpoint": "/logout",
|
||||
"headers": {
|
||||
"Authorization": "Bearer {{refresh_token.new_access_token}}"
|
||||
},
|
||||
"expect": {
|
||||
"status": [200],
|
||||
"jsonPath": {
|
||||
"$.success": true
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "verify_logout",
|
||||
"name": "6. 로그아웃 확인",
|
||||
"description": "로그아웃 후 토큰 무효화 확인",
|
||||
"method": "GET",
|
||||
"endpoint": "/users/me",
|
||||
"headers": {
|
||||
"Authorization": "Bearer {{refresh_token.new_access_token}}"
|
||||
},
|
||||
"expect": {
|
||||
"status": [401]
|
||||
},
|
||||
"continueOnFailure": true
|
||||
}
|
||||
]
|
||||
}
|
||||
138
plans/flow-tests/pricing-validation-test.json
Normal file
138
plans/flow-tests/pricing-validation-test.json
Normal file
@@ -0,0 +1,138 @@
|
||||
{
|
||||
"name": "Pricing API Validation Test",
|
||||
"description": "단가 API validation 테스트 - item_type_code common_codes 검증, margin_rate 100% 초과 허용 확인",
|
||||
"version": "1.0",
|
||||
"config": {
|
||||
"baseUrl": "",
|
||||
"timeout": 30000,
|
||||
"stopOnFailure": false
|
||||
},
|
||||
"variables": {
|
||||
"user_id": "{{$env.FLOW_TESTER_USER_ID}}",
|
||||
"user_pwd": "{{$env.FLOW_TESTER_USER_PWD}}"
|
||||
},
|
||||
"steps": [
|
||||
{
|
||||
"id": "login",
|
||||
"name": "1. 로그인",
|
||||
"method": "POST",
|
||||
"endpoint": "/login",
|
||||
"body": {
|
||||
"user_id": "{{user_id}}",
|
||||
"user_pwd": "{{user_pwd}}"
|
||||
},
|
||||
"expect": {
|
||||
"status": [200],
|
||||
"jsonPath": {
|
||||
"$.access_token": "@isString"
|
||||
}
|
||||
},
|
||||
"extract": {
|
||||
"token": "$.access_token"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "test_valid_item_type",
|
||||
"name": "2. 유효한 item_type_code 테스트 (PT)",
|
||||
"description": "common_codes에 있는 PT 코드로 단가 등록",
|
||||
"method": "POST",
|
||||
"endpoint": "/pricing",
|
||||
"headers": {
|
||||
"Authorization": "Bearer {{login.token}}"
|
||||
},
|
||||
"body": {
|
||||
"item_type_code": "PT",
|
||||
"item_id": 1,
|
||||
"purchase_price": 10000,
|
||||
"margin_rate": 150,
|
||||
"sales_price": 25000,
|
||||
"effective_from": "2025-01-01"
|
||||
},
|
||||
"expect": {
|
||||
"status": [200, 201],
|
||||
"jsonPath": {
|
||||
"$.success": true
|
||||
}
|
||||
},
|
||||
"extract": {
|
||||
"priceId": "$.data.id"
|
||||
},
|
||||
"continueOnFailure": true
|
||||
},
|
||||
{
|
||||
"id": "test_invalid_item_type",
|
||||
"name": "3. 잘못된 item_type_code 테스트",
|
||||
"description": "common_codes에 없는 코드로 422 에러 확인",
|
||||
"method": "POST",
|
||||
"endpoint": "/pricing",
|
||||
"headers": {
|
||||
"Authorization": "Bearer {{login.token}}"
|
||||
},
|
||||
"body": {
|
||||
"item_type_code": "INVALID_CODE",
|
||||
"item_id": 1,
|
||||
"effective_from": "2025-01-01"
|
||||
},
|
||||
"expect": {
|
||||
"status": [422],
|
||||
"jsonPath": {
|
||||
"$.success": false
|
||||
}
|
||||
},
|
||||
"continueOnFailure": true
|
||||
},
|
||||
{
|
||||
"id": "test_high_margin_rate",
|
||||
"name": "4. 100% 초과 마진율 테스트 (900%)",
|
||||
"description": "margin_rate 900% 허용 확인",
|
||||
"method": "POST",
|
||||
"endpoint": "/pricing",
|
||||
"headers": {
|
||||
"Authorization": "Bearer {{login.token}}"
|
||||
},
|
||||
"body": {
|
||||
"item_type_code": "FG",
|
||||
"item_id": 2,
|
||||
"purchase_price": 5000,
|
||||
"margin_rate": 900,
|
||||
"effective_from": "2025-01-01"
|
||||
},
|
||||
"expect": {
|
||||
"status": [200, 201],
|
||||
"jsonPath": {
|
||||
"$.success": true
|
||||
}
|
||||
},
|
||||
"extract": {
|
||||
"priceId2": "$.data.id"
|
||||
},
|
||||
"continueOnFailure": true
|
||||
},
|
||||
{
|
||||
"id": "cleanup1",
|
||||
"name": "5. 테스트 데이터 정리 (1)",
|
||||
"method": "DELETE",
|
||||
"endpoint": "/pricing/{{test_valid_item_type.priceId}}",
|
||||
"headers": {
|
||||
"Authorization": "Bearer {{login.token}}"
|
||||
},
|
||||
"expect": {
|
||||
"status": [200, 204, 404]
|
||||
},
|
||||
"continueOnFailure": true
|
||||
},
|
||||
{
|
||||
"id": "cleanup2",
|
||||
"name": "6. 테스트 데이터 정리 (2)",
|
||||
"method": "DELETE",
|
||||
"endpoint": "/pricing/{{test_high_margin_rate.priceId2}}",
|
||||
"headers": {
|
||||
"Authorization": "Bearer {{login.token}}"
|
||||
},
|
||||
"expect": {
|
||||
"status": [200, 204, 404]
|
||||
},
|
||||
"continueOnFailure": true
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user