Skip to content

Commit

Permalink
use a more-specific interface for updating target folder in app forms
Browse files Browse the repository at this point in the history
  • Loading branch information
labkey-chrisj committed Feb 13, 2024
1 parent 1bb9b0b commit 3c13c55
Showing 1 changed file with 11 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
package org.labkey.test.components.ui.navigation.apps;

import org.labkey.test.components.UpdatingComponent;
import org.labkey.test.components.bootstrap.ModalDialog;
import org.openqa.selenium.WebDriver;



public class ChangeProjectsAndResetFormModalDialog extends ModalDialog
public class ChangeTargetFolderDialog extends ModalDialog
{
private final UpdatingComponent _updatingComponent;
public ChangeProjectsAndResetFormModalDialog(WebDriver driver, UpdatingComponent updatingComponent)
private final UpdatesTargetFolder _updatingComponent;
public ChangeTargetFolderDialog(WebDriver driver, UpdatesTargetFolder updatingComponent)
{
super(new ModalDialogFinder(driver).withTitle("Change projects and reset form?"));
this._updatingComponent = updatingComponent;
Expand All @@ -23,8 +22,15 @@ public void clickCancel()

public void clickChangeProjects()
{
_updatingComponent.doAndWaitForUpdate(()->
_updatingComponent.doAndWaitForFolderUpdate(()->
dismiss("Change Projects"));

}



static public interface UpdatesTargetFolder
{
void doAndWaitForFolderUpdate(Runnable func);
}
}

0 comments on commit 3c13c55

Please sign in to comment.