Skip to content

Commit 45b803b

Browse files
committed
add OpenwbBaseButtonInput test
1 parent 7021c94 commit 45b803b

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
import { describe, it, expect } from "vitest";
2+
import { mount } from "@vue/test-utils";
3+
import OpenwbBaseButtonInput from "../OpenwbBaseButtonInput.vue";
4+
5+
describe("OpenwbBaseButtonInput.vue", () => {
6+
// general constants
7+
const title = "Button Test";
8+
const buttonText= "Test Button";
9+
const buttonSubtype = "success";
10+
// check title prop
11+
it("render title", () => {
12+
const wrapper = mount(OpenwbBaseButtonInput, {
13+
props: { title, buttonText, buttonSubtype },
14+
});
15+
const titleLabel = wrapper.find("label.col-form-label");
16+
expect(titleLabel.html()).toContain(title);
17+
});
18+
});

0 commit comments

Comments
 (0)