From d36cd3b1f8a2d2fa7c1f67d28a7507f32ee3dbec Mon Sep 17 00:00:00 2001 From: Gerard Burns Date: Tue, 18 Apr 2023 14:37:29 +0100 Subject: [PATCH] Builder Unit Test PoC (#10173) * wip * wip --- .github/workflows/budibase_ci.yml | 3 +- packages/bbui/src/Label/Label.svelte | 1 + packages/bbui/src/Typography/Body.svelte | 1 + packages/bbui/src/Typography/Heading.svelte | 1 + packages/builder/package.json | 8 +- .../builder/src/builderStore/store/history.js | 4 +- .../src/builderStore/store/history.test.js | 345 ++++++++++ .../common/inputs/EditableLabel.test.js | 37 + .../{dataUtils.spec.js => dataUtils.test.js} | 11 +- .../{duplicate.spec.js => duplicate.test.js} | 4 +- packages/builder/src/stores/portal/admin.js | 32 +- .../builder/src/stores/portal/admin.test.js | 268 ++++++++ .../builder/src/stores/portal/backups.test.js | 173 +++++ packages/builder/vite.config.js | 5 + packages/builder/vitest.setup.js | 28 + yarn.lock | 639 +++++++++++++++++- 16 files changed, 1510 insertions(+), 50 deletions(-) create mode 100644 packages/builder/src/builderStore/store/history.test.js create mode 100644 packages/builder/src/components/common/inputs/EditableLabel.test.js rename packages/builder/src/helpers/tests/{dataUtils.spec.js => dataUtils.test.js} (79%) rename packages/builder/src/helpers/tests/{duplicate.spec.js => duplicate.test.js} (91%) create mode 100644 packages/builder/src/stores/portal/admin.test.js create mode 100644 packages/builder/src/stores/portal/backups.test.js create mode 100644 packages/builder/vitest.setup.js diff --git a/.github/workflows/budibase_ci.yml b/.github/workflows/budibase_ci.yml index a9de0ba342..65e6529678 100644 --- a/.github/workflows/budibase_ci.yml +++ b/.github/workflows/budibase_ci.yml @@ -56,6 +56,7 @@ jobs: run: yarn install:pro $BRANCH $BASE_BRANCH - run: yarn - run: yarn bootstrap + - run: yarn build - run: yarn test - uses: codecov/codecov-action@v3 with: @@ -94,4 +95,4 @@ jobs: yarn test:ci env: BB_ADMIN_USER_EMAIL: admin - BB_ADMIN_USER_PASSWORD: admin \ No newline at end of file + BB_ADMIN_USER_PASSWORD: admin diff --git a/packages/bbui/src/Label/Label.svelte b/packages/bbui/src/Label/Label.svelte index 261ca946ea..71b0967d99 100644 --- a/packages/bbui/src/Label/Label.svelte +++ b/packages/bbui/src/Label/Label.svelte @@ -9,6 +9,7 @@