Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug #599

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Bug #599

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions packages/examples/vue3-advanced-demo/team-red/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,23 @@
"build": "vue-tsc --noEmit && vite build",
"serve": "vite preview --port 5000 --strictPort",
"clean": "rm -rf dist",
"stop": "kill-port --port 5000"
"stop": "kill-port --port 5000",
"test:unit": "vitest run"
},
"dependencies": {
"element-plus": "^2.2.15",
"pinia": "^2.0.21",
"vue": "^3.2.45",
"vue-router": "^4.1.5",
"pinia": "^2.0.21"
"vue-router": "^4.1.5"
},
"devDependencies": {
"unplugin-element-plus": "0.4.1",
"@vitejs/plugin-vue": "^4.0.0",
"typescript": "^4.9.4",
"unplugin-element-plus": "0.4.1",
"vite": "^4.0.5",
"vitest": "^0.26.2",
"happy-dom": "^14.10.1",
"@vue/test-utils": "^2.4.6",
"vue-tsc": "^0.39.5"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@




import { test } from 'vitest'
import { shallowMount} from "@vue/test-utils";
import App from '../App.vue';


test('mount the app', () => {
shallowMount(App)
})
17 changes: 12 additions & 5 deletions packages/examples/vue3-advanced-demo/team-red/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { defineConfig } from 'vite'
import { defineConfig } from 'vitest/config'
import vue from '@vitejs/plugin-vue'
import federation from "@originjs/vite-plugin-federation"
import ElementPlus from 'unplugin-element-plus/vite'

// https://vitejs.dev/config/
export default defineConfig({
export default defineConfig(() => ({
plugins: [
ElementPlus(),
vue(),
Expand All @@ -17,8 +17,15 @@ export default defineConfig({
shared: ['vue','pinia']
})
],

build:{
minify:false,
target: ["chrome89", "edge89", "firefox89", "safari15"]
}
})
target: ["chrome89", "edge89", "firefox89", "safari15"],

},
test: {
globals: true,
environment: "happy-dom",
include: ["./src/**/*.{test,spec}.?(c|m)[jt]s?(x)"], // get tests in src
},
}))
Loading
Loading