Skip to content

Commit

Permalink
Finish tests for luxInputButton
Browse files Browse the repository at this point in the history
  • Loading branch information
maxkadel committed Mar 2, 2024
1 parent 6a18ff7 commit 9eb486f
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions tests/unit/specs/components/luxInputButton.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,19 +33,30 @@ describe("LuxInputButton.vue", () => {
})

describe("Icon", () => {
// Note: We need to add an icon prop to this - it does not actually show an icon
// Also need to add a better assertion that indicates that a user actually sees an icon on the screen
it("displays an icon", () => {
wrapper = mount(LuxInputButton, {
props: {
variation: "icon",
icon: "search",
},
global: {
components: { LuxIconBase },
},
})
expect(wrapper.get("button").classes()).toContain("icon")
const icon = wrapper.find("lux-icon-search")
expect(icon).toBe
})
it("does not display an icon", () => {
wrapper = mount(LuxInputButton, {
props: {
variation: "solid",
},
global: {
components: { LuxIconBase },
},
})
expect(wrapper.get("button").classes()).not.toContain("icon")
})
it.todo("does not display an icon")
})
})

0 comments on commit 9eb486f

Please sign in to comment.