feat: change-aware test routing skill and milestone update
This commit is contained in:
parent
cc21fff146
commit
4cafca680d
3 changed files with 51 additions and 20 deletions
|
|
@ -173,6 +173,13 @@ tools/check_proto_sync.sh
|
|||
- 실패를 통과로 단정하지 않는다. 불확실하면 미검증 또는 실패 후보로 표시한다.
|
||||
- `agent-task/archive/**`를 자동으로 읽지 않는다.
|
||||
|
||||
## functional-routing anchor 정책
|
||||
|
||||
- `--route auto`에서 일반 언어 구현 변경은 파일명 방향 단서에 따라 `functional-server-x5 <lang>` 또는 `functional-client-x5 <lang>`를 recommended로 둔다.
|
||||
- 같은 언어에서 server/client 방향이 모두 감지되거나 방향을 알 수 없으면 `functional-both-x5 <lang>`를 recommended로 둔다.
|
||||
- transport, codec/framing/communicator, queue/gateway, public API entrypoint 변경은 파일명에 server/client 단서가 있어도 수정 언어 기준 `functional-both-x5 <lang>`를 우선한다.
|
||||
- transport/queue 변경의 전역 후보(`functional-both-x5 transport/queue`)와 proto/communicator/public API wider 후보는 언어별 anchor 후보와 별도로 중복 제거된 recommended/skipped 상태로 남긴다.
|
||||
|
||||
## full-functional-periodic 정책 (RFP-1, RFP-2, RFP-3)
|
||||
|
||||
- `run_test_by_change.sh --route full --dry-run` 출력이 `functional-full`, `functional-full-dart-web`, `functional-full-dart-web-wss`를 `recommended` 상태로 포함하면 full functional periodic이 발동된다.
|
||||
|
|
|
|||
|
|
@ -244,6 +244,14 @@ classify_file() {
|
|||
esac
|
||||
fi
|
||||
|
||||
# package/public API entrypoints
|
||||
if [ -z "$domain" ]; then
|
||||
case "$f" in
|
||||
dart/lib/proto_socket.dart|python/proto_socket/__init__.py|python/proto_socket/packets/__init__.py|typescript/src/index.ts|typescript/src/node.ts)
|
||||
domain="public-api" ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
# transport / crosstest / harness path
|
||||
if [ -z "$domain" ]; then
|
||||
case "$f" in
|
||||
|
|
@ -351,10 +359,11 @@ add_recommendation() {
|
|||
build_recommendations() {
|
||||
local detected_langs="$1"
|
||||
local detected_lang_directions="$2"
|
||||
local detected_domains="$3"
|
||||
local file_count="$4"
|
||||
local docs_only="$5"
|
||||
local has_perf_term="$6"
|
||||
local detected_lang_both_domains="$3"
|
||||
local detected_domains="$4"
|
||||
local file_count="$5"
|
||||
local docs_only="$6"
|
||||
local has_perf_term="$7"
|
||||
|
||||
if [ "$file_count" -eq 0 ]; then
|
||||
add_recommendation "skipped-candidate" "noop" "-" "변경 파일 없음"
|
||||
|
|
@ -414,16 +423,17 @@ build_recommendations() {
|
|||
# full functional (functional-full) 을 기본으로 발동한다.
|
||||
# protocol/schema/communicator/transport 변경이 감지되면 wider 승격도 같이 기록한다.
|
||||
if [ "$full_activate" -eq 1 ]; then
|
||||
local has_proto=0 has_comm=0 has_transport=0 has_queue=0
|
||||
local has_proto=0 has_comm=0 has_transport=0 has_queue=0 has_public_api=0
|
||||
csv_has_item "$detected_domains" "proto" && has_proto=1 || true
|
||||
csv_has_item "$detected_domains" "communicator" && has_comm=1 || true
|
||||
csv_has_item "$detected_domains" "transport" && has_transport=1 || true
|
||||
csv_has_item "$detected_domains" "queue-gateway" && has_queue=1 || true
|
||||
csv_has_item "$detected_domains" "public-api" && has_public_api=1 || true
|
||||
|
||||
# full functional: explicit full route + non-docs-only → 기본 발동
|
||||
add_recommendation "recommended" "functional-full" "all" "full periodic: 전체 범위의 functional 검증을 기본 발동"
|
||||
if [ "$has_proto" -eq 1 ] || [ "$has_comm" -eq 1 ]; then
|
||||
add_recommendation "recommended" "functional-wider" "all" "full periodic: proto/communicator 변경으로 wider functional 승격"
|
||||
if [ "$has_proto" -eq 1 ] || [ "$has_comm" -eq 1 ] || [ "$has_public_api" -eq 1 ]; then
|
||||
add_recommendation "recommended" "functional-wider" "all" "full periodic: proto/communicator/public API 변경으로 wider functional 승격"
|
||||
fi
|
||||
if [ "$has_transport" -eq 1 ]; then
|
||||
add_recommendation "recommended" "functional-both-x5" "transport/queue" "full periodic: transport 변경은 both x5 확장"
|
||||
|
|
@ -449,26 +459,27 @@ build_recommendations() {
|
|||
fi
|
||||
fi
|
||||
|
||||
local has_proto has_comm has_transport has_queue has_perf_harness has_test_docs
|
||||
local has_proto has_comm has_transport has_queue has_public_api has_perf_harness has_test_docs
|
||||
has_proto=$(csv_has_item "$detected_domains" "proto" && echo 1 || echo 0)
|
||||
has_comm=$(csv_has_item "$detected_domains" "communicator" && echo 1 || echo 0)
|
||||
has_transport=$(csv_has_item "$detected_domains" "transport" && echo 1 || echo 0)
|
||||
has_queue=$(csv_has_item "$detected_domains" "queue-gateway" && echo 1 || echo 0)
|
||||
has_public_api=$(csv_has_item "$detected_domains" "public-api" && echo 1 || echo 0)
|
||||
has_perf_harness=$(csv_has_item "$detected_domains" "perf-harness" && echo 1 || echo 0)
|
||||
has_test_docs=$(csv_has_item "$detected_domains" "test-docs" && echo 1 || echo 0)
|
||||
|
||||
# protocol / packet / codec / framing / protobuf 변경 → wider/full functional로 승격
|
||||
if [ "$has_proto" -eq 1 ] || [ "$has_comm" -eq 1 ]; then
|
||||
# protocol / packet / codec / framing / protobuf / public API 변경 → wider/full functional로 승격
|
||||
if [ "$has_proto" -eq 1 ] || [ "$has_comm" -eq 1 ] || [ "$has_public_api" -eq 1 ]; then
|
||||
if [ "$route" = "full" ]; then
|
||||
add_recommendation "recommended" "functional-full" "all" "proto/communicator 변경은 full functional 범위로 상승"
|
||||
add_recommendation "recommended" "functional-full" "all" "proto/communicator/public API 변경은 full functional 범위로 상승"
|
||||
elif [ "$functional_status" = "recommended" ]; then
|
||||
add_recommendation "recommended" "functional-wider" "all" "proto/communicator 변경은 smoke로 둬선 안 됨"
|
||||
add_recommendation "recommended" "functional-wider" "all" "proto/communicator/public API 변경은 smoke로 둬선 안 됨"
|
||||
else
|
||||
add_recommendation "skipped-candidate" "functional-wider" "all" "명시 라우팅이 기능 테스트 중심이 아님"
|
||||
fi
|
||||
fi
|
||||
|
||||
# 언어 구현 변경: 불명확한 server/client 구분이면 보수적으로 both-x5 권장
|
||||
# 언어 구현 변경: 고위험 도메인은 방향 단서보다 both-x5를 우선한다.
|
||||
if [ -n "$detected_langs" ]; then
|
||||
local lang
|
||||
local dir
|
||||
|
|
@ -478,6 +489,8 @@ build_recommendations() {
|
|||
[ -z "$dir" ] && dir="both"
|
||||
if [ "$route" = "full" ]; then
|
||||
add_recommendation "recommended" "functional-full" "$lang" "언어별 변경 기반으로 full functional 기준 선택"
|
||||
elif csv_has_item "$detected_lang_both_domains" "$lang"; then
|
||||
add_recommendation "recommended" "functional-both-x5" "$lang" "transport/codec/communicator/public API 변경은 수정 언어 기준 both x5"
|
||||
else
|
||||
case "$dir" in
|
||||
server)
|
||||
|
|
@ -559,11 +572,12 @@ main() {
|
|||
fi
|
||||
|
||||
# 3. 파일별 언어/도메인 분류 집계
|
||||
local tmp_lang tmp_domain tmp_lang_server tmp_lang_client
|
||||
local tmp_lang tmp_domain tmp_lang_server tmp_lang_client tmp_lang_both
|
||||
tmp_lang="$(mktemp)"
|
||||
tmp_domain="$(mktemp)"
|
||||
tmp_lang_server="$(mktemp)"
|
||||
tmp_lang_client="$(mktemp)"
|
||||
tmp_lang_both="$(mktemp)"
|
||||
local file_table="" has_non_docs=0 has_performance_term=0
|
||||
|
||||
if [ -n "$changed_files" ]; then
|
||||
|
|
@ -581,6 +595,12 @@ main() {
|
|||
*client* ) printf '%s\n' "$lang_val" >> "$tmp_lang_client" ;;
|
||||
esac
|
||||
}
|
||||
[ -n "$lang_val" ] && {
|
||||
case "${domain_val:-}" in
|
||||
communicator|transport|queue-gateway|public-api)
|
||||
printf '%s\n' "$lang_val" >> "$tmp_lang_both" ;;
|
||||
esac
|
||||
}
|
||||
[ -n "$domain_val" ] && printf '%s\n' "$domain_val" >> "$tmp_domain"
|
||||
case "${domain_val:-}" in
|
||||
docs|test-docs) ;;
|
||||
|
|
@ -601,7 +621,7 @@ main() {
|
|||
fi
|
||||
|
||||
# 중복 제거 + 쉼표 결합
|
||||
local detected_langs="" detected_domains="" detected_lang_directions=""
|
||||
local detected_langs="" detected_domains="" detected_lang_directions="" detected_lang_both_domains=""
|
||||
if [ -s "$tmp_lang" ]; then
|
||||
detected_langs="$(sort -u "$tmp_lang" | tr '\n' ',' | sed 's/,$//')"
|
||||
for lang in $(sort -u "$tmp_lang"); do
|
||||
|
|
@ -619,7 +639,10 @@ main() {
|
|||
if [ -s "$tmp_domain" ]; then
|
||||
detected_domains="$(sort -u "$tmp_domain" | tr '\n' ',' | sed 's/,$//')"
|
||||
fi
|
||||
rm -f "$tmp_lang" "$tmp_domain" "$tmp_lang_server" "$tmp_lang_client"
|
||||
if [ -s "$tmp_lang_both" ]; then
|
||||
detected_lang_both_domains="$(sort -u "$tmp_lang_both" | tr '\n' ',' | sed 's/,$//')"
|
||||
fi
|
||||
rm -f "$tmp_lang" "$tmp_domain" "$tmp_lang_server" "$tmp_lang_client" "$tmp_lang_both"
|
||||
|
||||
# docs-only 판정: 변경 파일이 있고 docs 외 domain이 없으면 docs-only
|
||||
local docs_only="no"
|
||||
|
|
@ -631,7 +654,7 @@ main() {
|
|||
declare -a reco_targets=()
|
||||
declare -a reco_reasons=()
|
||||
if [ "$classify_only" -eq 0 ]; then
|
||||
build_recommendations "$detected_langs" "$detected_lang_directions" "$detected_domains" "$file_count" "$docs_only" "$has_performance_term"
|
||||
build_recommendations "$detected_langs" "$detected_lang_directions" "$detected_lang_both_domains" "$detected_domains" "$file_count" "$docs_only" "$has_performance_term"
|
||||
fi
|
||||
|
||||
# untracked 포함 여부
|
||||
|
|
|
|||
|
|
@ -45,8 +45,8 @@
|
|||
|
||||
일반 수정 후 항상 실행할 최소 기능 기준점을 정한다.
|
||||
|
||||
- [ ] [anchor-language-x5] 언어 구현 변경은 수정 언어 중심 server x5 또는 client x5를 선택한다. 검증: server-only/client-only 변경은 해당 방향 x5를 실행 후보로 만든다.
|
||||
- [ ] [anchor-language-both-x5] transport, codec, communicator, public API 변경은 수정 언어 기준 양방향 x5를 선택한다. 검증: 같은 언어 self 방향은 same-language 검증으로 채우고 중복 방향은 결과에서 한 번만 센다.
|
||||
- [x] [anchor-language-x5] 언어 구현 변경은 수정 언어 중심 server x5 또는 client x5를 선택한다. 검증: server-only/client-only 변경은 해당 방향 x5를 실행 후보로 만든다.
|
||||
- [x] [anchor-language-both-x5] transport, codec, communicator, public API 변경은 수정 언어 기준 양방향 x5를 선택한다. 검증: 같은 언어 self 방향은 same-language 검증으로 채우고 중복 방향은 결과에서 한 번만 센다.
|
||||
- [x] [dart-web-coverage] Dart.web/Dart.web(WSS)는 full functional matrix와 browser client 관련 변경에서 필수 coverage로 유지한다. 검증: full functional route가 기존 Dart.web/WSS client 열을 누락하지 않는다.
|
||||
- [x] [full-functional-periodic] 정기 full 또는 넓은 protocol 변경은 functional full 5x5와 Dart.web/WSS client coverage를 선택한다. 검증: 전체 cross matrix가 매 변경 기본값이 아니라 정기/고위험 변경용으로 분리된다.
|
||||
|
||||
|
|
@ -110,4 +110,5 @@
|
|||
- 완료: `agent-task/archive/2026/06/m-change-aware-test-routing/01_change_classifier_core/complete.log` -> `last-pass-point`, `diff-source`, `path-domain-map`
|
||||
- 완료: `agent-task/archive/2026/06/m-change-aware-test-routing/02+01_risk_routing_rules/complete.log` -> `risk-escalation`
|
||||
- 완료: `agent-task/archive/2026/06/m-change-aware-test-routing/01_dart_web_coverage/complete.log` -> `dart-web-coverage`
|
||||
- 진행중: `agent-task/m-change-aware-test-routing/02_full_functional_periodic/PLAN-local-G05.md` -> `full-functional-periodic`
|
||||
- 완료: `agent-task/archive/2026/06/m-change-aware-test-routing/02_full_functional_periodic/complete.log` -> `full-functional-periodic`
|
||||
- 완료(직접 처리): `functional-routing` anchor 보강 -> `anchor-language-x5`, `anchor-language-both-x5`; 검증=`bash -n .../run_test_by_change.sh`, focused dry-run server/client/transport, public-api unit smoke
|
||||
|
|
|
|||
Loading…
Reference in a new issue