From 3c6cdc34acdc88e286eae009e56a9ffc244278ce Mon Sep 17 00:00:00 2001 From: Wilson Date: Wed, 28 Aug 2024 21:27:47 +0800 Subject: [PATCH] test(methods): add beforeDestroy to special method test case --- src/__tests__/vue-class-component/migrator-methods.test.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/__tests__/vue-class-component/migrator-methods.test.ts b/src/__tests__/vue-class-component/migrator-methods.test.ts index 24d225e..83c2c5a 100644 --- a/src/__tests__/vue-class-component/migrator-methods.test.ts +++ b/src/__tests__/vue-class-component/migrator-methods.test.ts @@ -13,6 +13,9 @@ describe('Methods Property Migration', () => { created() { console.log("OK"); } + beforeDestroy() { + console.log("beforeDestroy triggerd"); + } }`, // Results `import { defineComponent } from "vue"; @@ -20,6 +23,9 @@ describe('Methods Property Migration', () => { export default defineComponent({ created() { console.log("OK"); + }, + beforeDestroy() { + console.log("beforeDestroy triggerd"); } })`, );