From 23cfd71f290a5286ae49e47f0e42b31eaa4e4699 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tu=C4=9F=C3=A7e=20K=C3=BC=C3=A7=C3=BCko=C4=9Flu?= Date: Thu, 22 Dec 2022 11:40:59 +0300 Subject: [PATCH 01/39] github links fixed --- layouts/AppDocumentation.vue | 11 +++++++---- pages/accordion/AccordionDoc.vue | 2 +- pages/autocomplete/AutoCompleteDoc.vue | 2 +- pages/avatar/AvatarDoc.vue | 2 +- pages/badge/BadgeDoc.vue | 2 +- pages/blockui/BlockUIDoc.vue | 2 +- pages/breadcrumb/BreadcrumbDoc.vue | 2 +- pages/button/ButtonDoc.vue | 2 +- pages/calendar/CalendarDoc.vue | 2 +- pages/card/CardDoc.vue | 2 +- pages/carousel/CarouselDoc.vue | 2 +- pages/cascadeselect/CascadeSelectDoc.vue | 2 +- pages/chart/BarChartDoc.vue | 2 +- pages/chart/ComboChartDoc.vue | 2 +- pages/chart/DoughnutChartDoc.vue | 2 +- pages/chart/LineChartDoc.vue | 2 +- pages/chart/PieChartDoc.vue | 2 +- pages/chart/PolarAreaChartDoc.vue | 2 +- pages/chart/RadarChartDoc.vue | 2 +- pages/checkbox/CheckboxDoc.vue | 2 +- pages/chip/ChipDoc.vue | 2 +- pages/chips/ChipsDoc.vue | 2 +- pages/colorpicker/ColorPickerDoc.vue | 2 +- pages/confirmdialog/ConfirmDialogDoc.vue | 2 +- pages/confirmpopup/ConfirmPopupDoc.vue | 2 +- pages/contextmenu/ContextMenuDoc.vue | 2 +- pages/datatable/ColGroup.vue | 2 +- pages/datatable/ColResize.vue | 2 +- pages/datatable/ColToggle.vue | 2 +- pages/datatable/ContextMenu.vue | 2 +- pages/datatable/Crud.vue | 2 +- pages/datatable/DataTableBasicDoc.vue | 2 +- pages/datatable/DataTableDoc.vue | 2 +- pages/datatable/DynamicColumns.vue | 2 +- pages/datatable/Edit.vue | 2 +- pages/datatable/Export.vue | 2 +- pages/datatable/Filter.vue | 2 +- pages/datatable/FlexScroll.vue | 2 +- pages/datatable/GridLines.vue | 2 +- pages/datatable/Lazy.vue | 2 +- pages/datatable/Paginator.vue | 2 +- pages/datatable/Reorder.vue | 2 +- pages/datatable/Responsive.vue | 2 +- pages/datatable/RowExpand.vue | 2 +- pages/datatable/RowGroup.vue | 2 +- pages/datatable/Scroll.vue | 2 +- pages/datatable/Selection.vue | 2 +- pages/datatable/Size.vue | 2 +- pages/datatable/Sort.vue | 2 +- pages/datatable/State.vue | 2 +- pages/datatable/Striped.vue | 2 +- pages/datatable/Style.vue | 2 +- pages/datatable/Templating.vue | 2 +- pages/datatable/VirtualScroll.vue | 6 +++--- pages/dataview/DataViewDoc.vue | 2 +- pages/deferredcontent/DeferredContentDoc.vue | 2 +- pages/dialog/DialogDoc.vue | 2 +- pages/divider/DividerDoc.vue | 2 +- pages/dock/DockDoc.vue | 2 +- pages/dropdown/DropdownDoc.vue | 2 +- pages/dynamicdialog/DynamicDialogDoc.vue | 2 +- pages/editor/EditorDoc.vue | 2 +- pages/fieldset/FieldsetDoc.vue | 2 +- pages/fileupload/FileUploadDoc.vue | 2 +- pages/filterservice/FilterServiceDoc.vue | 2 +- pages/floatlabel/index.vue | 2 +- pages/focustrap/FocusTrapDoc.vue | 2 +- pages/fullcalendar/FullCalendarDoc.vue | 1 - pages/image/ImageDoc.vue | 2 +- pages/inplace/InplaceDoc.vue | 2 +- pages/inputgroup/InputGroupDoc.vue | 2 +- pages/inputmask/InputMaskDoc.vue | 2 +- pages/inputnumber/InputNumberDoc.vue | 2 +- pages/inputswitch/InputSwitchDoc.vue | 2 +- pages/inputtext/InputTextDoc.vue | 2 +- pages/invalid/index.vue | 2 +- pages/knob/KnobDoc.vue | 2 +- pages/listbox/ListboxDoc.vue | 2 +- pages/megamenu/MegaMenuDoc.vue | 2 +- pages/menu/MenuDoc.vue | 2 +- pages/menubar/MenubarDoc.vue | 2 +- pages/message/MessageDoc.vue | 2 +- pages/multiselect/MultiSelectDoc.vue | 2 +- pages/orderlist/OrderListDoc.vue | 2 +- pages/organizationchart/OrganizationChartDoc.vue | 2 +- pages/overlaypanel/OverlayPanelDoc.vue | 2 +- pages/paginator/PaginatorDoc.vue | 2 +- pages/panel/PanelDoc.vue | 2 +- pages/panelmenu/PanelMenuDoc.vue | 2 +- pages/password/PasswordDoc.vue | 2 +- pages/picklist/PickListDoc.vue | 2 +- pages/progressbar/ProgressBarDoc.vue | 2 +- pages/progressspinner/ProgressSpinnerDoc.vue | 2 +- pages/radiobutton/RadioButtonDoc.vue | 2 +- pages/rating/RatingDoc.vue | 2 +- pages/ripple/RippleDoc.vue | 2 +- pages/scrollpanel/ScrollPanelDoc.vue | 2 +- pages/scrolltop/ScrollTopDoc.vue | 2 +- pages/selectbutton/SelectButtonDoc.vue | 2 +- pages/sidebar/SidebarDoc.vue | 2 +- pages/skeleton/SkeletonDoc.vue | 2 +- pages/slider/SliderDoc.vue | 2 +- pages/speeddial/SpeedDialDoc.vue | 2 +- pages/splitbutton/SplitButtonDoc.vue | 2 +- pages/splitter/SplitterDoc.vue | 2 +- pages/steps/StepsDoc.vue | 2 +- pages/styleclass/StyleClassDoc.vue | 2 +- pages/tabmenu/TabMenuDoc.vue | 2 +- pages/tabview/TabViewDoc.vue | 2 +- pages/tag/TagDoc.vue | 2 +- pages/terminal/TerminalDoc.vue | 2 +- pages/textarea/TextareaDoc.vue | 2 +- pages/tieredmenu/TieredMenuDoc.vue | 2 +- pages/timeline/TimelineDoc.vue | 2 +- pages/toast/ToastDoc.vue | 2 +- pages/togglebutton/ToggleButtonDoc.vue | 2 +- pages/toolbar/ToolbarDoc.vue | 2 +- pages/tooltip/TooltipDoc.vue | 2 +- pages/tree/Filter.vue | 2 +- pages/tree/Lazy.vue | 2 +- pages/tree/Scroll.vue | 2 +- pages/tree/Selection.vue | 2 +- pages/tree/Templating.vue | 2 +- pages/tree/TreeDoc.vue | 2 +- pages/treeselect/TreeSelectDoc.vue | 2 +- pages/treetable/ColResize.vue | 2 +- pages/treetable/ColToggle.vue | 2 +- pages/treetable/Filter.vue | 2 +- pages/treetable/Lazy.vue | 2 +- pages/treetable/Paginator.vue | 2 +- pages/treetable/Responsive.vue | 2 +- pages/treetable/Scroll.vue | 2 +- pages/treetable/Selection.vue | 2 +- pages/treetable/Size.vue | 2 +- pages/treetable/Sort.vue | 2 +- pages/treetable/Templating.vue | 2 +- pages/treetable/TreeTableDoc.vue | 2 +- pages/tristatecheckbox/TriStateCheckboxDoc.vue | 2 +- pages/validation/index.vue | 9 +-------- pages/virtualscroller/VirtualScrollerDoc.vue | 2 +- 140 files changed, 147 insertions(+), 152 deletions(-) diff --git a/layouts/AppDocumentation.vue b/layouts/AppDocumentation.vue index 7a9aafa85..ddda5ddf4 100644 --- a/layouts/AppDocumentation.vue +++ b/layouts/AppDocumentation.vue @@ -1,7 +1,7 @@ + + diff --git a/pages/steps/Personal.vue b/pages/steps/Personal.vue deleted file mode 100755 index bc8d2bdc8..000000000 --- a/pages/steps/Personal.vue +++ /dev/null @@ -1,65 +0,0 @@ - - - diff --git a/pages/steps/index.vue b/pages/steps/index.vue index 74d15162e..bc8d2bdc8 100755 --- a/pages/steps/index.vue +++ b/pages/steps/index.vue @@ -1,88 +1,65 @@ - - diff --git a/pages/tabmenu.vue b/pages/tabmenu.vue new file mode 100755 index 000000000..a66d60bba --- /dev/null +++ b/pages/tabmenu.vue @@ -0,0 +1,72 @@ + + + + + diff --git a/pages/tabmenu/Home.vue b/pages/tabmenu/Home.vue deleted file mode 100755 index e73f7970c..000000000 --- a/pages/tabmenu/Home.vue +++ /dev/null @@ -1,9 +0,0 @@ - - - diff --git a/pages/tabmenu/index.vue b/pages/tabmenu/index.vue index 149448cd9..e73f7970c 100755 --- a/pages/tabmenu/index.vue +++ b/pages/tabmenu/index.vue @@ -1,72 +1,9 @@ - - From 14d1ef23c69378a205c25d662a35bd1cbf7aaf98 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bahad=C4=B1r=20Sofuo=C4=9Flu?= Date: Thu, 22 Dec 2022 22:47:28 +0300 Subject: [PATCH 05/39] Unit test coverage package updates --- package-lock.json | 463 ++++++++++++++++++++++++++++++++++++++++++++++ package.json | 3 +- vitest.config.js | 6 +- 3 files changed, 470 insertions(+), 2 deletions(-) diff --git a/package-lock.json b/package-lock.json index dba55c814..aee4a0d94 100644 --- a/package-lock.json +++ b/package-lock.json @@ -17,6 +17,7 @@ "@fullcalendar/timegrid": "^5.11.0", "@fullcalendar/vue3": "^5.11.0", "@vitejs/plugin-vue-jsx": "^2.0.1", + "@vitest/coverage-istanbul": "^0.26.2", "@vue/test-utils": "^2.0.0", "@vuelidate/core": "^2.0.0-alpha.14", "@vuelidate/validators": "^2.0.0-alpha.12", @@ -755,6 +756,15 @@ "integrity": "sha512-Sx1pU8EM64o2BrqNpEO1CNLtKQwyhuXuqyfH7oGKCk+1a33d2r5saW8zNwm3j6BTExtjrv2BxTgzzkMwts6vGg==", "dev": true }, + "node_modules/@istanbuljs/schema": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/@istanbuljs/schema/-/schema-0.1.3.tgz", + "integrity": "sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA==", + "dev": true, + "engines": { + "node": ">=8" + } + }, "node_modules/@jridgewell/gen-mapping": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.1.1.tgz", @@ -1817,6 +1827,118 @@ "vue": "^3.0.0" } }, + "node_modules/@vitest/coverage-istanbul": { + "version": "0.26.2", + "resolved": "https://registry.npmjs.org/@vitest/coverage-istanbul/-/coverage-istanbul-0.26.2.tgz", + "integrity": "sha512-3tU7vrgnPiGdIoX9VpIqR2geBuk5er4+2m0flO563R+1lV4guqO2bKbCNqEGpnIRcmnWJKQI1LeXndPexqIHtA==", + "dev": true, + "dependencies": { + "istanbul-lib-coverage": "^3.2.0", + "istanbul-lib-instrument": "^5.2.1", + "istanbul-lib-report": "^3.0.0", + "istanbul-lib-source-maps": "^4.0.1", + "istanbul-reports": "^3.1.5", + "test-exclude": "^6.0.0", + "vitest": "0.26.2" + }, + "funding": { + "url": "https://github.com/sponsors/antfu" + } + }, + "node_modules/@vitest/coverage-istanbul/node_modules/acorn-walk": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz", + "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==", + "dev": true, + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/@vitest/coverage-istanbul/node_modules/pathe": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/pathe/-/pathe-0.2.0.tgz", + "integrity": "sha512-sTitTPYnn23esFR3RlqYBWn4c45WGeLcsKzQiUpXJAyfcWkolvlYpV8FLo7JishK946oQwMFUCHXQ9AjGPKExw==", + "dev": true + }, + "node_modules/@vitest/coverage-istanbul/node_modules/vite-node": { + "version": "0.26.2", + "resolved": "https://registry.npmjs.org/vite-node/-/vite-node-0.26.2.tgz", + "integrity": "sha512-4M/zlatItZAyvrQG+82zQBhgDjRZRhVJYFW4T9wcAKh7eMmSiPOVSeI5zsV9UzHXgCcIDKX0o0r3s4OxExTHqg==", + "dev": true, + "dependencies": { + "debug": "^4.3.4", + "mlly": "^1.0.0", + "pathe": "^0.2.0", + "source-map": "^0.6.1", + "source-map-support": "^0.5.21", + "vite": "^3.0.0 || ^4.0.0" + }, + "bin": { + "vite-node": "vite-node.mjs" + }, + "engines": { + "node": ">=v14.16.0" + }, + "funding": { + "url": "https://github.com/sponsors/antfu" + } + }, + "node_modules/@vitest/coverage-istanbul/node_modules/vitest": { + "version": "0.26.2", + "resolved": "https://registry.npmjs.org/vitest/-/vitest-0.26.2.tgz", + "integrity": "sha512-Jvqxh6SDy9SsuslkDjts0iDewDIdq4rveEt69YgDuAb1tVDGV0lDepVaeAFraoySWqneJmOt4TngFFNhlw7GfA==", + "dev": true, + "dependencies": { + "@types/chai": "^4.3.4", + "@types/chai-subset": "^1.3.3", + "@types/node": "*", + "acorn": "^8.8.1", + "acorn-walk": "^8.2.0", + "chai": "^4.3.7", + "debug": "^4.3.4", + "local-pkg": "^0.4.2", + "source-map": "^0.6.1", + "strip-literal": "^1.0.0", + "tinybench": "^2.3.1", + "tinypool": "^0.3.0", + "tinyspy": "^1.0.2", + "vite": "^3.0.0 || ^4.0.0", + "vite-node": "0.26.2" + }, + "bin": { + "vitest": "vitest.mjs" + }, + "engines": { + "node": ">=v14.16.0" + }, + "funding": { + "url": "https://github.com/sponsors/antfu" + }, + "peerDependencies": { + "@edge-runtime/vm": "*", + "@vitest/browser": "*", + "@vitest/ui": "*", + "happy-dom": "*", + "jsdom": "*" + }, + "peerDependenciesMeta": { + "@edge-runtime/vm": { + "optional": true + }, + "@vitest/browser": { + "optional": true + }, + "@vitest/ui": { + "optional": true + }, + "happy-dom": { + "optional": true + }, + "jsdom": { + "optional": true + } + } + }, "node_modules/@vue/babel-helper-vue-transform-on": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/@vue/babel-helper-vue-transform-on/-/babel-helper-vue-transform-on-1.0.2.tgz", @@ -7302,6 +7424,12 @@ "node": ">=12" } }, + "node_modules/html-escaper": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", + "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", + "dev": true + }, "node_modules/html-tags": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/html-tags/-/html-tags-3.2.0.tgz", @@ -8088,6 +8216,93 @@ "node": ">=0.10.0" } }, + "node_modules/istanbul-lib-coverage": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.0.tgz", + "integrity": "sha512-eOeJ5BHCmHYvQK7xt9GkdHuzuCGS1Y6g9Gvnx3Ym33fz/HpLRYxiS0wHNr+m/MBC8B647Xt608vCDEvhl9c6Mw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-instrument": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-5.2.1.tgz", + "integrity": "sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg==", + "dev": true, + "dependencies": { + "@babel/core": "^7.12.3", + "@babel/parser": "^7.14.7", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-report": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-3.0.0.tgz", + "integrity": "sha512-wcdi+uAKzfiGT2abPpKZ0hSU1rGQjUQnLvtY5MpQ7QCTahD3VODhcu4wcfY1YtkGaDD5yuydOLINXsfbus9ROw==", + "dev": true, + "dependencies": { + "istanbul-lib-coverage": "^3.0.0", + "make-dir": "^3.0.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-report/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-report/node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-source-maps": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", + "integrity": "sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw==", + "dev": true, + "dependencies": { + "debug": "^4.1.1", + "istanbul-lib-coverage": "^3.0.0", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-reports": { + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.1.5.tgz", + "integrity": "sha512-nUsEMa9pBt/NOHqbcbeJEgqIlY/K7rVWUX6Lql2orY5e9roQOthbR3vtY4zzf2orPELg80fnxxk9zUyPlgwD1w==", + "dev": true, + "dependencies": { + "html-escaper": "^2.0.0", + "istanbul-lib-report": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/jest-worker": { "version": "26.6.2", "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-26.6.2.tgz", @@ -13808,6 +14023,62 @@ "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", "dev": true }, + "node_modules/test-exclude": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", + "integrity": "sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w==", + "dev": true, + "dependencies": { + "@istanbuljs/schema": "^0.1.2", + "glob": "^7.1.4", + "minimatch": "^3.0.4" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/test-exclude/node_modules/brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/test-exclude/node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "dev": true, + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/test-exclude/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, "node_modules/text-table": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", @@ -16699,6 +16970,12 @@ "integrity": "sha512-Sx1pU8EM64o2BrqNpEO1CNLtKQwyhuXuqyfH7oGKCk+1a33d2r5saW8zNwm3j6BTExtjrv2BxTgzzkMwts6vGg==", "dev": true }, + "@istanbuljs/schema": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/@istanbuljs/schema/-/schema-0.1.3.tgz", + "integrity": "sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA==", + "dev": true + }, "@jridgewell/gen-mapping": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.1.1.tgz", @@ -17496,6 +17773,72 @@ "@vue/babel-plugin-jsx": "^1.1.1" } }, + "@vitest/coverage-istanbul": { + "version": "0.26.2", + "resolved": "https://registry.npmjs.org/@vitest/coverage-istanbul/-/coverage-istanbul-0.26.2.tgz", + "integrity": "sha512-3tU7vrgnPiGdIoX9VpIqR2geBuk5er4+2m0flO563R+1lV4guqO2bKbCNqEGpnIRcmnWJKQI1LeXndPexqIHtA==", + "dev": true, + "requires": { + "istanbul-lib-coverage": "^3.2.0", + "istanbul-lib-instrument": "^5.2.1", + "istanbul-lib-report": "^3.0.0", + "istanbul-lib-source-maps": "^4.0.1", + "istanbul-reports": "^3.1.5", + "test-exclude": "^6.0.0", + "vitest": "0.26.2" + }, + "dependencies": { + "acorn-walk": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz", + "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==", + "dev": true + }, + "pathe": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/pathe/-/pathe-0.2.0.tgz", + "integrity": "sha512-sTitTPYnn23esFR3RlqYBWn4c45WGeLcsKzQiUpXJAyfcWkolvlYpV8FLo7JishK946oQwMFUCHXQ9AjGPKExw==", + "dev": true + }, + "vite-node": { + "version": "0.26.2", + "resolved": "https://registry.npmjs.org/vite-node/-/vite-node-0.26.2.tgz", + "integrity": "sha512-4M/zlatItZAyvrQG+82zQBhgDjRZRhVJYFW4T9wcAKh7eMmSiPOVSeI5zsV9UzHXgCcIDKX0o0r3s4OxExTHqg==", + "dev": true, + "requires": { + "debug": "^4.3.4", + "mlly": "^1.0.0", + "pathe": "^0.2.0", + "source-map": "^0.6.1", + "source-map-support": "^0.5.21", + "vite": "^3.0.0 || ^4.0.0" + } + }, + "vitest": { + "version": "0.26.2", + "resolved": "https://registry.npmjs.org/vitest/-/vitest-0.26.2.tgz", + "integrity": "sha512-Jvqxh6SDy9SsuslkDjts0iDewDIdq4rveEt69YgDuAb1tVDGV0lDepVaeAFraoySWqneJmOt4TngFFNhlw7GfA==", + "dev": true, + "requires": { + "@types/chai": "^4.3.4", + "@types/chai-subset": "^1.3.3", + "@types/node": "*", + "acorn": "^8.8.1", + "acorn-walk": "^8.2.0", + "chai": "^4.3.7", + "debug": "^4.3.4", + "local-pkg": "^0.4.2", + "source-map": "^0.6.1", + "strip-literal": "^1.0.0", + "tinybench": "^2.3.1", + "tinypool": "^0.3.0", + "tinyspy": "^1.0.2", + "vite": "^3.0.0 || ^4.0.0", + "vite-node": "0.26.2" + } + } + } + }, "@vue/babel-helper-vue-transform-on": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/@vue/babel-helper-vue-transform-on/-/babel-helper-vue-transform-on-1.0.2.tgz", @@ -21688,6 +22031,12 @@ "whatwg-encoding": "^2.0.0" } }, + "html-escaper": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", + "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", + "dev": true + }, "html-tags": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/html-tags/-/html-tags-3.2.0.tgz", @@ -22257,6 +22606,74 @@ "integrity": "sha512-WhB9zCku7EGTj/HQQRz5aUQEUeoQZH2bWcltRErOpymJ4boYE6wL9Tbr23krRPSZ+C5zqNSrSw+Cc7sZZ4b7vg==", "dev": true }, + "istanbul-lib-coverage": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.0.tgz", + "integrity": "sha512-eOeJ5BHCmHYvQK7xt9GkdHuzuCGS1Y6g9Gvnx3Ym33fz/HpLRYxiS0wHNr+m/MBC8B647Xt608vCDEvhl9c6Mw==", + "dev": true + }, + "istanbul-lib-instrument": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-5.2.1.tgz", + "integrity": "sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg==", + "dev": true, + "requires": { + "@babel/core": "^7.12.3", + "@babel/parser": "^7.14.7", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^6.3.0" + } + }, + "istanbul-lib-report": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-3.0.0.tgz", + "integrity": "sha512-wcdi+uAKzfiGT2abPpKZ0hSU1rGQjUQnLvtY5MpQ7QCTahD3VODhcu4wcfY1YtkGaDD5yuydOLINXsfbus9ROw==", + "dev": true, + "requires": { + "istanbul-lib-coverage": "^3.0.0", + "make-dir": "^3.0.0", + "supports-color": "^7.1.0" + }, + "dependencies": { + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true + }, + "supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "requires": { + "has-flag": "^4.0.0" + } + } + } + }, + "istanbul-lib-source-maps": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", + "integrity": "sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw==", + "dev": true, + "requires": { + "debug": "^4.1.1", + "istanbul-lib-coverage": "^3.0.0", + "source-map": "^0.6.1" + } + }, + "istanbul-reports": { + "version": "3.1.5", + "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-3.1.5.tgz", + "integrity": "sha512-nUsEMa9pBt/NOHqbcbeJEgqIlY/K7rVWUX6Lql2orY5e9roQOthbR3vtY4zzf2orPELg80fnxxk9zUyPlgwD1w==", + "dev": true, + "requires": { + "html-escaper": "^2.0.0", + "istanbul-lib-report": "^3.0.0" + } + }, "jest-worker": { "version": "26.6.2", "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-26.6.2.tgz", @@ -26539,6 +26956,52 @@ } } }, + "test-exclude": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", + "integrity": "sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w==", + "dev": true, + "requires": { + "@istanbuljs/schema": "^0.1.2", + "glob": "^7.1.4", + "minimatch": "^3.0.4" + }, + "dependencies": { + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "dev": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "dev": true, + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dev": true, + "requires": { + "brace-expansion": "^1.1.7" + } + } + } + }, "text-table": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", diff --git a/package.json b/package.json index 3a06748e6..23a0ce644 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,7 @@ "format": "prettier --write \"**/*.{js,vue,d.ts}\"", "format:check": "prettier --check \"**/*.{js,vue,d.ts}\"", "test:unit": "vitest", - "test:build": "NODE_ENV=production rollup -c", + "test:coverage": "vitest --coverage", "lint": "eslint --ext \".js,.vue\" --ignore-path .gitignore .", "lint:fix": "eslint --fix --ext \".js,.vue\" --ignore-path .gitignore ." }, @@ -32,6 +32,7 @@ "@fullcalendar/timegrid": "^5.11.0", "@fullcalendar/vue3": "^5.11.0", "@vitejs/plugin-vue-jsx": "^2.0.1", + "@vitest/coverage-istanbul": "^0.26.2", "@vue/test-utils": "^2.0.0", "@vuelidate/core": "^2.0.0-alpha.14", "@vuelidate/validators": "^2.0.0-alpha.12", diff --git a/vitest.config.js b/vitest.config.js index 4c099c9ea..e150d8642 100644 --- a/vitest.config.js +++ b/vitest.config.js @@ -5,7 +5,11 @@ export default { plugins: [vue()], test: { globals: true, - environment: 'jsdom' + environment: 'jsdom', + coverage: { + provider: 'istanbul', + reporter: ['text', 'json', 'html'] + } }, resolve: { alias: { From 38b5526bab8c7d5283fac13e9c8ec5c2a7ce2042 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bahad=C4=B1r=20Sofuo=C4=9Flu?= Date: Mon, 26 Dec 2022 12:41:33 +0300 Subject: [PATCH 06/39] Rating test updates --- components/rating/Rating.spec.js | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/components/rating/Rating.spec.js b/components/rating/Rating.spec.js index 0402ded00..f7718a649 100644 --- a/components/rating/Rating.spec.js +++ b/components/rating/Rating.spec.js @@ -1,4 +1,5 @@ import { config, mount } from '@vue/test-utils'; +import { expect } from 'vitest'; import Rating from './Rating.vue'; config.global.mocks = { @@ -43,4 +44,32 @@ describe('Rating.vue', () => { expect(wrapper.find('.p-rating-cancel').exists()).toBe(false); }); + + it('When star is clicked, onOptionClick method should triggered', async () => { + await wrapper.find('.p-rating-item').trigger('click'); + + expect(wrapper.find('.p-focus').exists()).toBe(true); + }); + + it('When input focused, focusedOptionIndex value should changed', async () => { + await wrapper.vm.onFocus(true, 5); + + expect(wrapper.vm.focusedOptionIndex).toEqual(5); + expect(wrapper.emitted().focus[0]).toEqual([true]); + }); + + it('When input changed, onOptionSelect method should triggered', async () => { + const onOptionSelectSpy = vi.spyOn(wrapper.vm, 'onOptionSelect'); + + await wrapper.vm.onChange(); + + expect(onOptionSelectSpy).toHaveBeenCalled(); + }); + + it('When input changed, onOptionSelect method should triggered', async () => { + await wrapper.setProps({ onIcon: 'test-icon' }); + await wrapper.setProps({ modelValue: 5 }); + + expect(wrapper.find('.test-icon').exists()).toBe(true); + }); }); From c3b08bd3703ff4f258c1acdcf042954b9c306eb6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tu=C4=9F=C3=A7e=20K=C3=BC=C3=A7=C3=BCko=C4=9Flu?= Date: Mon, 26 Dec 2022 19:20:31 +0300 Subject: [PATCH 07/39] alias for images --- pages/autocomplete/index.vue | 4 ++-- pages/button/ButtonDoc.vue | 4 ++-- pages/cascadeselect/CascadeSelectDoc.vue | 2 +- pages/cascadeselect/index.vue | 2 +- pages/datatable/Filter.vue | 4 ++-- pages/datatable/RowGroup.vue | 6 +++--- pages/datatable/Scroll.vue | 2 +- pages/datatable/State.vue | 4 ++-- pages/datatable/index.vue | 2 +- pages/dock/index.vue | 2 +- pages/dropdown/index.vue | 6 +++--- pages/filterservice/index.vue | 2 +- pages/landing/ThemeSection.vue | 4 ++-- pages/listbox/index.vue | 4 ++-- pages/menubar/index.vue | 2 +- pages/multiselect/index.vue | 6 +++--- pages/setup/index.vue | 10 +++++----- pages/splitbutton/SplitButtonDoc.vue | 2 +- pages/splitbutton/index.vue | 2 +- pages/theming/index.vue | 4 ++-- 20 files changed, 37 insertions(+), 37 deletions(-) diff --git a/pages/autocomplete/index.vue b/pages/autocomplete/index.vue index 83d29c0b6..52e88a181 100755 --- a/pages/autocomplete/index.vue +++ b/pages/autocomplete/index.vue @@ -22,7 +22,7 @@ @@ -32,7 +32,7 @@ diff --git a/pages/button/ButtonDoc.vue b/pages/button/ButtonDoc.vue index 9b7b5442f..af6dbbbcc 100755 --- a/pages/button/ButtonDoc.vue +++ b/pages/button/ButtonDoc.vue @@ -136,11 +136,11 @@ import Button from 'primevue/button';

Custom content such as icons, images and text can be placed inside the button via the default slot. Note that when slot is used, label, icon and badge properties are not included.


 <Button type="button" class="px-3">
-    <img alt="logo" src="../../assets/images/logo.svg" style="width: 1.5rem"/>
+    <img alt="logo" src="@/assets/images/logo.svg" style="width: 1.5rem"/>
 </Button>
 
 <Button type="button" class="p-button-outlined p-button-success">
-    <img alt="logo" src="../../assets/images/logo.svg" style="width: 1.5rem" />
+    <img alt="logo" src="@/assets/images/logo.svg" style="width: 1.5rem" />
     <span class="ml-2 font-bold">PrimeVue</span>
 </Button>
 
diff --git a/pages/cascadeselect/CascadeSelectDoc.vue b/pages/cascadeselect/CascadeSelectDoc.vue
index 12d4c2693..921207df8 100644
--- a/pages/cascadeselect/CascadeSelectDoc.vue
+++ b/pages/cascadeselect/CascadeSelectDoc.vue
@@ -118,7 +118,7 @@ data() {
         :optionGroupChildren="['states', 'cities']" style="minWidth: 14rem">
     <template #option="slotProps">
         <div class="country-item">
-            <img src="../../assets/images/flag_placeholder.png" :class="'flag flag-' + slotProps.option.code.toLowerCase()" v-if="slotProps.option.states" />
+            <img src="@/assets/images/flag_placeholder.png" :class="'flag flag-' + slotProps.option.code.toLowerCase()" v-if="slotProps.option.states" />
             <i class="pi pi-compass mr-2" v-if="slotProps.option.cities"></i>
             <i class="pi pi-map-marker mr-2" v-if="slotProps.option.cname"></i>
             <span>{{slotProps.option.cname || slotProps.option.name}}</span>
diff --git a/pages/cascadeselect/index.vue b/pages/cascadeselect/index.vue
index e6bf78bba..8834f1a44 100644
--- a/pages/cascadeselect/index.vue
+++ b/pages/cascadeselect/index.vue
@@ -22,7 +22,7 @@