test(wbs-ux): add Vitest unit test suite for Vue templates rendering validation
Validators (Pushes and Pull Requests) / UI & Storage Validation (push) Failing after 9s
Validators (Pushes and Pull Requests) / .NET Contracts (push) Has been skipped
Validators (Pushes and Pull Requests) / WBS & Audit Validations (push) Has been skipped
Validators (Pushes and Pull Requests) / Calibration & Performance (push) Has been skipped
Validators (Pushes and Pull Requests) / Operational Report & Decision Packet (push) Has been skipped
Validators (Pushes and Pull Requests) / Core Validators & Database Setup (push) Failing after 17s
Validators (Pushes and Pull Requests) / Database & Schema Validation (push) Successful in 9s
Validators (Pushes and Pull Requests) / Security & Secrets (push) Successful in 9s
Validators (Pushes and Pull Requests) / CI Workflow Lint (push) Failing after 8s
Validators (Pushes and Pull Requests) / Notify PR Results (push) Has been skipped
Validators (Pushes and Pull Requests) / UI & Storage Validation (push) Failing after 9s
Validators (Pushes and Pull Requests) / .NET Contracts (push) Has been skipped
Validators (Pushes and Pull Requests) / WBS & Audit Validations (push) Has been skipped
Validators (Pushes and Pull Requests) / Calibration & Performance (push) Has been skipped
Validators (Pushes and Pull Requests) / Operational Report & Decision Packet (push) Has been skipped
Validators (Pushes and Pull Requests) / Core Validators & Database Setup (push) Failing after 17s
Validators (Pushes and Pull Requests) / Database & Schema Validation (push) Successful in 9s
Validators (Pushes and Pull Requests) / Security & Secrets (push) Successful in 9s
Validators (Pushes and Pull Requests) / CI Workflow Lint (push) Failing after 8s
Validators (Pushes and Pull Requests) / Notify PR Results (push) Has been skipped
This commit is contained in:
@@ -6,7 +6,8 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite",
|
"dev": "vite",
|
||||||
"build": "vue-tsc -b && vite build",
|
"build": "vue-tsc -b && vite build",
|
||||||
"preview": "vite preview"
|
"preview": "vite preview",
|
||||||
|
"test": "vitest run"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@primevue/themes": "^4.3.1",
|
"@primevue/themes": "^4.3.1",
|
||||||
@@ -21,9 +22,13 @@
|
|||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/node": "^24.13.2",
|
"@types/node": "^24.13.2",
|
||||||
"@vitejs/plugin-vue": "^6.0.7",
|
"@vitejs/plugin-vue": "^6.0.7",
|
||||||
|
"@vue/test-utils": "^2.4.6",
|
||||||
"@vue/tsconfig": "^0.9.1",
|
"@vue/tsconfig": "^0.9.1",
|
||||||
|
"jsdom": "^26.0.0",
|
||||||
"typescript": "~6.0.2",
|
"typescript": "~6.0.2",
|
||||||
"vite": "^8.1.1",
|
"vite": "^8.1.1",
|
||||||
|
"vitest": "^3.0.4",
|
||||||
"vue-tsc": "^3.3.5"
|
"vue-tsc": "^3.3.5"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,31 @@
|
|||||||
|
import { describe, it, expect } from 'vitest';
|
||||||
|
import { mount } from '@vue/test-utils';
|
||||||
|
import TemplateGalleryView from '../TemplateGalleryView.vue';
|
||||||
|
import RealOlapExportLayout from '../RealOlapExportLayout.vue';
|
||||||
|
|
||||||
|
describe('Prototype Template UI Rendering Tests', () => {
|
||||||
|
it('TemplateGalleryView should render all 9 template options', () => {
|
||||||
|
const wrapper = mount(TemplateGalleryView, {
|
||||||
|
global: {
|
||||||
|
stubs: {
|
||||||
|
'router-link': true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
// 갤러리 타이틀 렌더링 검증
|
||||||
|
expect(wrapper.text()).toContain('상용화 프로토타입 템플릿 갤러리');
|
||||||
|
|
||||||
|
// 9개의 카드 목록 카운트 검증 (가이드라인 준수)
|
||||||
|
const cards = wrapper.findAll('router-link-stub');
|
||||||
|
expect(cards.length).toBe(9);
|
||||||
|
});
|
||||||
|
|
||||||
|
it('RealOlapExportLayout should render action button', () => {
|
||||||
|
const wrapper = mount(RealOlapExportLayout);
|
||||||
|
|
||||||
|
// 엑셀 보고서 출력 버튼이 정상적으로 노출되는지 검증
|
||||||
|
expect(wrapper.find('button').text()).toContain('엑셀 보고서 출력');
|
||||||
|
expect(wrapper.text()).toContain('다차원 팩터 출력 리포트');
|
||||||
|
});
|
||||||
|
});
|
||||||
@@ -4,6 +4,10 @@ import vue from '@vitejs/plugin-vue'
|
|||||||
// https://vite.dev/config/
|
// https://vite.dev/config/
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
plugins: [vue()],
|
plugins: [vue()],
|
||||||
|
test: {
|
||||||
|
environment: 'jsdom',
|
||||||
|
globals: true
|
||||||
|
},
|
||||||
server: {
|
server: {
|
||||||
port: 5173,
|
port: 5173,
|
||||||
proxy: {
|
proxy: {
|
||||||
@@ -15,3 +19,4 @@ export default defineConfig({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user