Skip to content

Commit

Permalink
#8129 - remove skipped test
Browse files Browse the repository at this point in the history
  • Loading branch information
novikov82 committed May 27, 2024
1 parent eac05b4 commit d05f94f
Showing 1 changed file with 0 additions and 37 deletions.
37 changes: 0 additions & 37 deletions tests/components/popuptests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1335,43 +1335,6 @@ QUnit.test("Fixed PopupModel width calculate and overflow content position calcu
targetElement.remove();
});

QUnit.skip("PopupModel overflow content and canShrink position calculate", (assert) => {
const model: PopupModel = new PopupModel("sv-list", {}, { verticalPosition: "bottom", horizontalPosition: "left", showPointer: false });
model.setWidthByTarget = true;
const targetElement: HTMLElement = document.createElement("button");

targetElement.style.position = "absolute";
targetElement.style.top = "130px";
targetElement.style.left = "0px";
targetElement.style.height = "10px";
addElementIntoBody(targetElement);
targetElement.parentElement.scrollTop = 0;
targetElement.parentElement.scrollLeft = 0;

const viewModel: PopupDropdownViewModel = createPopupViewModel(model, targetElement) as PopupDropdownViewModel;
viewModel.initializePopupContainer();
viewModel.container.innerHTML = popupTemplate;
let popupContainer = getPopupContainer(viewModel.container);
popupContainer.style.width = "200px";
popupContainer.style.height = "700px";

(<any>window).innerWidth = 1000;
(<any>window).innerHeight = 800;
model.toggleVisibility();

viewModel.updateOnShowing();
assert.equal(viewModel.top, "130px", "top");
assert.equal(viewModel.height, "654px", "height");

viewModel.model.canShrink = false;
viewModel.updateOnShowing();
assert.equal(viewModel.top, "84px", "top");
assert.equal(viewModel.height, "700px", "height");

viewModel.dispose();
targetElement.remove();
});

QUnit.test("PopupViewModel updateOnHiding", (assert) => {
const model: PopupModel = new PopupModel("sv-list", {}, { verticalPosition: "bottom", horizontalPosition: "center", showPointer: true });
model.positionMode = "fixed";
Expand Down

0 comments on commit d05f94f

Please sign in to comment.