mirror of
https://github.com/System-End/github-readme-stats.git
synced 2026-04-19 16:38:23 +00:00
tests: add missing card set title test (#3190)
This commit is contained in:
parent
13af3ba4df
commit
7a6ed4d8a8
1 changed files with 10 additions and 0 deletions
|
|
@ -41,6 +41,16 @@ describe("Card", () => {
|
|||
);
|
||||
});
|
||||
|
||||
it("should set custom title", () => {
|
||||
const card = new Card({});
|
||||
card.setTitle("custom title");
|
||||
|
||||
document.body.innerHTML = card.render(``);
|
||||
expect(queryByTestId(document.body, "card-title")).toHaveTextContent(
|
||||
"custom title",
|
||||
);
|
||||
});
|
||||
|
||||
it("should hide title", () => {
|
||||
const card = new Card({});
|
||||
card.setHideTitle(true);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue