Skip to content

Commit ac5e727

Browse files
author
Luis Otavio
committed
Rewrite tests for considering issue AuHau#11 fix
1 parent 3d8883c commit ac5e727

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

test/picker.test.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ describe("Single Picker - ", function () {
5656
expect($container).toContainElement("span.pc-list");
5757
expect($container).toContainElement("span.pc-element.pc-trigger");
5858
expect($container.find(".picker > .pc-select > .pc-list > ul > li")).toHaveLength(5);
59-
expect($container.find(".pc-element")).toContainText("aaa");
59+
expect($container.find(".pc-element")).toContainText($select.find('option:eq(0)').text());
6060
});
6161

6262
it("No options init", function () {
@@ -154,7 +154,7 @@ describe("Multi-selection Picker - ", function () {
154154
expect($container).toContainElement("span.pc-list");
155155
expect($container).toContainElement("span.pc-element.pc-trigger");
156156
expect($container.find(".picker > .pc-select > .pc-list > ul > li")).toHaveLength(5);
157-
expect($container.find(".pc-trigger")).toHaveText("Random");
157+
expect($container.find(".pc-trigger")).toHaveText($select.find('option:eq(0)').text());
158158
});
159159

160160
it("Auto init", function () {
@@ -359,7 +359,7 @@ describe("Picker configuration - ", function () {
359359
});
360360

361361
var $input = $container.find(".pc-list input[type='search']");
362-
expect($container.find(".pc-trigger")).toContainText("aaa");
362+
expect($container.find(".pc-trigger")).toContainText($select.find('option:eq(0)').text());
363363
expect($input.attr("placeholder")).toBe("ccc");
364364

365365
$input.val("asd");

0 commit comments

Comments
 (0)