From 54e4ee2cd9a9f725f9e7ab96404bfe879eba4a25 Mon Sep 17 00:00:00 2001 From: Tony Sullivan Date: Sun, 15 May 2022 14:00:56 -0600 Subject: [PATCH] adding solid hydration and HMR tests --- .../astro/e2e/fixtures/vue/astro.config.mjs | 7 ++++ packages/astro/e2e/fixtures/vue/package.json | 10 +++++ .../fixtures/vue/src/components/Counter.vue | 40 +++++++++++++++++++ .../e2e/fixtures/vue/src/pages/index.astro | 26 ++++++++++++ pnpm-lock.yaml | 10 +++++ 5 files changed, 93 insertions(+) create mode 100644 packages/astro/e2e/fixtures/vue/astro.config.mjs create mode 100644 packages/astro/e2e/fixtures/vue/package.json create mode 100644 packages/astro/e2e/fixtures/vue/src/components/Counter.vue create mode 100644 packages/astro/e2e/fixtures/vue/src/pages/index.astro diff --git a/packages/astro/e2e/fixtures/vue/astro.config.mjs b/packages/astro/e2e/fixtures/vue/astro.config.mjs new file mode 100644 index 000000000..881930612 --- /dev/null +++ b/packages/astro/e2e/fixtures/vue/astro.config.mjs @@ -0,0 +1,7 @@ +import { defineConfig } from 'astro/config'; +import vue from '@astrojs/vue'; + +// https://astro.build/config +export default defineConfig({ + integrations: [vue()], +}); diff --git a/packages/astro/e2e/fixtures/vue/package.json b/packages/astro/e2e/fixtures/vue/package.json new file mode 100644 index 000000000..86b0c0673 --- /dev/null +++ b/packages/astro/e2e/fixtures/vue/package.json @@ -0,0 +1,10 @@ +{ + "name": "@e2e/vue", + "version": "0.0.0", + "private": true, + "dependencies": { + "@astrojs/vue": "workspace:*", + "astro": "workspace:*", + "vue": "^3.2.33" + } +} diff --git a/packages/astro/e2e/fixtures/vue/src/components/Counter.vue b/packages/astro/e2e/fixtures/vue/src/components/Counter.vue new file mode 100644 index 000000000..d5d5215f7 --- /dev/null +++ b/packages/astro/e2e/fixtures/vue/src/components/Counter.vue @@ -0,0 +1,40 @@ + + + + + diff --git a/packages/astro/e2e/fixtures/vue/src/pages/index.astro b/packages/astro/e2e/fixtures/vue/src/pages/index.astro new file mode 100644 index 000000000..77327247b --- /dev/null +++ b/packages/astro/e2e/fixtures/vue/src/pages/index.astro @@ -0,0 +1,26 @@ +--- +import Counter from '../components/Counter.vue'; + +const someProps = { + count: 0, +}; +--- + + + + + + + +

Hello, client:idle!

+
+ + +

Hello, client:load!

+
+ + +

Hello, client:visible!

+
+ + diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f0a004249..422238ffb 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -711,6 +711,16 @@ importers: '@astrojs/tailwind': link:../../../../integrations/tailwind astro: link:../../.. + packages/astro/e2e/fixtures/vue: + specifiers: + '@astrojs/vue': workspace:* + astro: workspace:* + vue: ^3.2.33 + dependencies: + '@astrojs/vue': link:../../../../integrations/vue + astro: link:../../.. + vue: 3.2.33 + packages/astro/test/fixtures/0-css: specifiers: '@astrojs/react': workspace:*