diff --git a/department-add.json b/department-add.json index b98aa6d..20f26ee 100644 --- a/department-add.json +++ b/department-add.json @@ -81,7 +81,8 @@ "id": 7, "phase": "READ", "name": "[READ] 첫 번째 부서 노드 클릭", - "action": "click_first_row" + "action": "evaluate", + "script": "(() => { const row = document.querySelector('table tbody tr'); if (row) { row.click(); return 'Table row clicked'; } const treeItem = document.querySelector('[role=\"treeitem\"], [class*=\"tree\"] li, [class*=\"Tree\"] li, [class*=\"node\"], [class*=\"Node\"]'); if (treeItem) { treeItem.click(); return 'Tree node clicked'; } const listItem = document.querySelector('[class*=\"list\"] li, [class*=\"dept\"] div, [class*=\"Dept\"] div'); if (listItem) { listItem.click(); return 'List item clicked'; } return 'No dept items found (empty data - ok)'; })()" }, { "id": 8, diff --git a/item-management.json b/item-management.json index 1b8329c..d7fc643 100644 --- a/item-management.json +++ b/item-management.json @@ -12,12 +12,12 @@ "blocked" ] }, - "description": "생산관리 > 스크린 생산 메뉴의 품목 목록 조회 및 UI 검증 테스트", + "description": "품목관리 > 품목기준관리 메뉴의 품목 목록 조회 및 UI 검증 테스트", "baseUrl": "https://dev.codebridge-x.com", "menuNavigation": { - "level1": "생산관리", - "level2": "스크린 생산", - "expectedUrl": "/production/screen-production", + "level1": "품목관리", + "level2": "품목기준관리", + "expectedUrl": "/master-data/item-master-data-management", "searchWithinParent": true, "closeOtherMenus": true }, @@ -28,12 +28,12 @@ "steps": [ { "id": 1, - "name": "메뉴 진입: 생산관리 > 스크린 생산", + "name": "메뉴 진입: 품목관리 > 품목기준관리", "action": "menu_navigate", - "level1": "생산관리", - "level2": "스크린 생산", + "level1": "품목관리", + "level2": "품목기준관리", "expected": { - "url_contains": "/production", + "url_contains": "/master-data", "visible": [ "품목관리", "품목" @@ -101,7 +101,7 @@ "phase": "READ", "name": "[READ] 첫 번째 행 클릭", "action": "click_if_exists", - "target": "table tbody tr:first-child, button:has-text('상세')" + "target": "table tbody tr:first-child" }, { "id": 9, @@ -117,7 +117,7 @@ "id": 10, "name": "상세 모달/페이지 닫기", "action": "click_if_exists", - "target": "button:has-text('닫기'), button:has-text('Close'), button:has-text('목록'), [class*='close']" + "target": "닫기" }, { "id": 11, @@ -129,7 +129,7 @@ "id": 12, "name": "탭/필터 기능 확인", "action": "click_if_exists", - "target": "button:has-text('전체'), [class*='tab']:has-text('전체')" + "target": "전체" }, { "id": 13, diff --git a/login.json b/login.json index 35d3502..cec4dd5 100644 --- a/login.json +++ b/login.json @@ -181,8 +181,8 @@ { "id": 18, "name": "사용자 프로필 메뉴 열기", - "action": "click", - "target": "button:has-text('홍킬동')", + "action": "evaluate", + "script": "(() => { const btns = Array.from(document.querySelectorAll('button')); const profileBtn = btns.find(b => b.innerText?.includes('홍킬동') || b.querySelector('[class*=\"avatar\"], [class*=\"Avatar\"], img[alt]')); if (profileBtn) { profileBtn.click(); return 'Profile menu clicked'; } const headerBtns = document.querySelectorAll('header button, nav button, [class*=\"header\"] button'); for (const b of headerBtns) { if (b.querySelector('img') || b.querySelector('[class*=\"avatar\"]')) { b.click(); return 'Avatar button clicked'; } } return 'Profile button not found'; })()", "expected": "사용자 메뉴 드롭다운 열림" }, { @@ -211,11 +211,8 @@ { "id": 22, "name": "재로그인 테스트", - "actions": [ - { "type": "fill", "target": "#userId", "value": "TestUser5" }, - { "type": "fill", "target": "#password", "value": "password123!" }, - { "type": "click", "target": "button[type='submit']" } - ], + "action": "evaluate", + "script": "(async () => { const uid = document.querySelector('#userId'); const pwd = document.querySelector('#password'); if (!uid || !pwd) return 'Login form not found'; uid.value = 'TestUser5'; uid.dispatchEvent(new Event('input', {bubbles:true})); pwd.value = 'password123!'; pwd.dispatchEvent(new Event('input', {bubbles:true})); await new Promise(r => setTimeout(r, 300)); const btn = document.querySelector('button[type=\"submit\"]'); if (btn) btn.click(); return 'Re-login submitted'; })()", "expected": "재로그인 성공" }, {