Package net.thucydides.core.screenshots

Examples of net.thucydides.core.screenshots.SingleThreadScreenshotProcessor.terminate()


    waitUntilFileIsWritten(screenshotFile);

        ResizableImage image = ResizableImage.loadFrom(screenshotFile);

        screenshotProcessor.terminate();
        waitUntilFileIsWritten(screenshotFile);
        assertThat(image.getWitdh(), is(greaterThan(350))); // In Windows the actual dimensions may be are slightly less
    }

    @Test
View Full Code Here


        ScreenshotProcessor screenshotProcessor = new SingleThreadScreenshotProcessor(environmentVariables);
        Photographer photographer = new Photographer(driver, screenshotDirectory,screenshotProcessor);
        File screenshot1File = photographer.takeScreenshot().get();
        File screenshot2File = photographer.takeScreenshot().get();

        screenshotProcessor.terminate();
        waitUntilFileIsWritten(screenshot1File);
        waitUntilFileIsWritten(screenshot2File);
        assertThat(screenshot1File.getName(), equalTo(screenshot2File.getName()));

    }
View Full Code Here

        ScreenshotProcessor screenshotProcessor = new SingleThreadScreenshotProcessor(environmentVariables);
        Photographer photographer = new Photographer(driver, screenshotDirectory, screenshotProcessor);
        File screenshotFile = photographer.takeScreenshot().get();

        waitUntilFileIsWritten(screenshotFile);
        screenshotProcessor.terminate();

        ResizableImage image = ResizableImage.loadFrom(screenshotFile);

        assertThat(image.getWitdh(), is(300));
    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.