Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
@Test
public void VerifyFileDownloadChrome() throws IOException {
var expectedFilePath = Paths.get("c:\\temp\\Testing_Framework_2015_3_1314_2_Free.exe");
try
{
driver.navigate().to("https://www.telerik.com/download-trial-file/v2/telerik-testing-framework");
wait.until(x -> Files.exists(expectedFilePath));
long bytes = Files.size(expectedFilePath);
Assert.assertEquals(4326192, bytes);
}
finally
{
if (Files.exists(expectedFilePath))
{
Files.delete(expectedFilePath);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment