16 lines
425 B
JavaScript
16 lines
425 B
JavaScript
import { shallowMount } from "@vue/test-utils";
|
|
import Header from "./header";
|
|
|
|
describe("Header.vue", () => {
|
|
it("Should render the 'text' prop value as a span value for the header span text value.", () => {
|
|
// Act
|
|
const wrapper = shallowMount(Header, {
|
|
propsData: {
|
|
text: "Header Content",
|
|
},
|
|
});
|
|
|
|
// Assert
|
|
expect(wrapper.find("h2").text()).toContain("Header Content");
|
|
});
|
|
});
|