Skip to content

Commit

Permalink
improve waiting for values to be set
Browse files Browse the repository at this point in the history
  • Loading branch information
sgiehl committed Sep 22, 2023
1 parent 81a94b6 commit 01552c3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion tests/UI/ContainerVersion_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ describe("ContainerVersion", function () {
await capture.page(page, 'create_new_shown_in_list');
});

it('should be possible to publish new version', async function () {
it('should be possible to fill in publish new version form', async function () {
await page.click('.createNewVersion');
await setVersionName('v3.0');
await page.waitForTimeout(500);
Expand Down
4 changes: 2 additions & 2 deletions tests/UI/form.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ exports.sendFieldValue = async function (page, selector, text)
$(selector).val('').change();
}, selector);

await page.waitForTimeout(100);
await page.waitForFunction("$('" + selector + "').val() == ''");
// page.sendKeys(selector, text);

await page.evaluate((selector, text) => {
$(selector).val(text).change();
}, selector, text);

await page.waitForTimeout(200);
await page.waitForFunction("$('" + selector + "').val() != ''");
};
exports.selectValue = async function (page, field, title)
{
Expand Down

0 comments on commit 01552c3

Please sign in to comment.