com.sdl.selenium.web.button.UploadFile Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of Testy Show documentation
Show all versions of Testy Show documentation
Automated Acceptance Testing. Selenium and Selenium WebDriver test framework for web applications.
(optimized for dynamic html, ExtJS, Bootstrap, complex UI, simple web applications/sites)
The newest version!
package com.sdl.selenium.web.button;
import com.sdl.selenium.bootstrap.button.Upload;
import com.sdl.selenium.web.WebLocator;
public class UploadFile extends WebLocator implements Upload {
public UploadFile() {
setClassName("UploadFile");
}
/**
* @param container parent
*/
public UploadFile(WebLocator container) {
this();
setContainer(container);
}
/**
* Upload file with AutoIT.
* Use only this: button.upload("C:\\text.txt");
*
* @param filePath e.g. "C:\\text.txt"
* @return true | false
*/
@Override
public boolean upload(String filePath) {
return upload(this, filePath);
}
/**
* Upload file with AutoIT.
* Use only this: button.upload(this, "C:\\text.txt");
*
* @param el the item that you click to open upload window
* @param filePath e.g. "C:\\text.txt"
* @return true | false
*/
public boolean upload(WebLocator el, String filePath) {
return executor.browse(el) && executor.upload(filePath);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy