Skip to content

test: fix padding tests#45

Open
petemyron wants to merge 1 commit intoKartikLabhshetwar:mainfrom
petemyron:test/fix-padding-tests
Open

test: fix padding tests#45
petemyron wants to merge 1 commit intoKartikLabhshetwar:mainfrom
petemyron:test/fix-padding-tests

Conversation

@petemyron
Copy link

After updating the use/set padding methods, the tests broke, blocking pnpm tauri build from completing.

@vercel
Copy link

vercel bot commented Jan 28, 2026

Someone is attempting to deploy a commit to the knox projects Team on Vercel.

A member of the Team first needs to authorize it.

@petemyron petemyron force-pushed the test/fix-padding-tests branch 3 times, most recently from bacc282 to b4b5c23 Compare January 28, 2026 21:25
@@ -1,5 +1,5 @@
import { describe, it, expect, beforeEach } from "vitest";
import { useEditorStore, editorActions, usePadding, useSettings } from "./editorStore";
import { useEditorStore, editorActions, usePaddingTop, usePaddingBottom, usePaddingLeft, usePaddingRight, useSettings } from "./editorStore";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: this import is getting pretty wide; splitting it makes the diff/tests a bit easier to scan.

Suggested change
import { useEditorStore, editorActions, usePaddingTop, usePaddingBottom, usePaddingLeft, usePaddingRight, useSettings } from "./editorStore";
import {
useEditorStore,
editorActions,
usePaddingTop,
usePaddingBottom,
usePaddingLeft,
usePaddingRight,
useSettings,
} from "./editorStore";

});
});

describe("usePadding selector", () => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now that padding is per-side, a table-driven it.each for the selector + transient update cases might be a nice win (less repetition, easier to add coverage for undo/redo on Bottom/Left/Right too).

@petemyron petemyron force-pushed the test/fix-padding-tests branch from b4b5c23 to 5ef4912 Compare January 28, 2026 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant