Package com.google.jstestdriver

Examples of com.google.jstestdriver.TimeImpl


  public void testListBrowsers() throws Exception {
    CapturedBrowsers capturedBrowsers = new CapturedBrowsers(new BrowserIdStrategy(new MockTime(0)));
    BrowserInfo browserInfo = new BrowserInfo();
    browserInfo.setId(1L);
    SlaveBrowser slave =
        new SlaveBrowser(new TimeImpl(), "1", browserInfo, 20, null, CaptureHandler.QUIRKS,
            RunnerType.CLIENT, BrowserState.CAPTURED, new Instant(0));

    capturedBrowsers.addSlave(slave);
    CommandGetHandler handler = new CommandGetHandler(null, null, new Gson(), capturedBrowsers);
View Full Code Here


  public void testListBrowsersWithBrowserRunnerType() throws Exception {
    CapturedBrowsers capturedBrowsers = new CapturedBrowsers(new BrowserIdStrategy(new MockTime(0)));
    BrowserInfo browserInfo1 = new BrowserInfo();
    browserInfo1.setId(1L);
    SlaveBrowser slave1 =
        new SlaveBrowser(new TimeImpl(), "1", browserInfo1, 20, null, CaptureHandler.QUIRKS,
            RunnerType.CLIENT, BrowserState.CAPTURED, new Instant(0));
    capturedBrowsers.addSlave(slave1);

    BrowserInfo browserInfo2 = new BrowserInfo();
    browserInfo1.setId(2L);
    SlaveBrowser slave2 =
        new SlaveBrowser(new TimeImpl(), "2", browserInfo2, 20, null, CaptureHandler.QUIRKS,
            RunnerType.BROWSER, BrowserState.CAPTURED, new Instant(0));
    capturedBrowsers.addSlave(slave2);

    CommandGetHandler handler = new CommandGetHandler(null, null, new Gson(), capturedBrowsers);
View Full Code Here

  public void testGetDataFromJsPuppetServer() throws Exception {
    CapturedBrowsers browsers = new CapturedBrowsers(new BrowserIdStrategy(new MockTime(0)));
    String id = "1";
    SlaveBrowser slave =
        new SlaveBrowser(new TimeImpl(), id, new BrowserInfo(), 20, null, CaptureHandler.QUIRKS,
            RunnerType.CLIENT, BrowserState.CAPTURED, new Instant(0));
    String data = "hello";

    slave.createCommand(data);
    browsers.addSlave(slave);
View Full Code Here

  public void testSettingResponseForACommand() throws Exception {
    CapturedBrowsers browsers = new CapturedBrowsers(new BrowserIdStrategy(new MockTime(0)));
    String id = "1";
    SlaveBrowser slave =
        new SlaveBrowser(new TimeImpl(), id, new BrowserInfo(), 20, null, CaptureHandler.QUIRKS,
            RunnerType.CLIENT, BrowserState.CAPTURED, new Instant(0));

    browsers.addSlave(slave);
    BrowserQueryResponseHandler handler =
        new BrowserQueryResponseHandler(null, null, browsers, streamedResponses);
View Full Code Here

  public void testSimulatePollTimeoutDequeueNullCommand() throws Exception {
    CapturedBrowsers browsers = new CapturedBrowsers(new BrowserIdStrategy(new MockTime(0)));
    String id = "1";
    SlaveBrowser slave =
        new SlaveBrowser(new TimeImpl(), id, new BrowserInfo(), 20, null,
            CaptureHandler.QUIRKS,
            RunnerType.CLIENT, BrowserState.CAPTURED, new Instant(0));

    slave.setDequeueTimeout(0L, TimeUnit.NANOSECONDS);
    browsers.addSlave(slave);
View Full Code Here

  public void testDoNotGetCommandIfNotLastResponse() throws Exception {
    CapturedBrowsers browsers = new CapturedBrowsers(new BrowserIdStrategy(new MockTime(0)));
    String id = "1";
    SlaveBrowser slave =
        new SlaveBrowser(new TimeImpl(), id, new BrowserInfo(), 20, null, CaptureHandler.QUIRKS,
            RunnerType.CLIENT, BrowserState.CAPTURED, new Instant(0));

    browsers.addSlave(slave);
    BrowserQueryResponseHandler handler =
        new BrowserQueryResponseHandler(null, null, browsers, streamedResponses);
View Full Code Here

  public void testFilesLoadedAreAddedToTheBrowserFileSet() throws Exception {
    CapturedBrowsers browsers = new CapturedBrowsers(new BrowserIdStrategy(new MockTime(0)));
    String id = "1";
    SlaveBrowser slave =
        new SlaveBrowser(new TimeImpl(), id, new BrowserInfo(), 20, null, CaptureHandler.QUIRKS,
            RunnerType.CLIENT, BrowserState.CAPTURED, new Instant(0));

    browsers.addSlave(slave);
    BrowserQueryResponseHandler handler =
        new BrowserQueryResponseHandler(null, null, browsers, streamedResponses);
View Full Code Here

  public void testResetClearsTheBrowserFileSet() throws Exception {
    CapturedBrowsers browsers = new CapturedBrowsers(new BrowserIdStrategy(new MockTime(0)));
    String id = "1";
    SlaveBrowser slave =
        new SlaveBrowser(new TimeImpl(), id, new BrowserInfo(), 20, null, CaptureHandler.QUIRKS,
            RunnerType.CLIENT, BrowserState.READY, new Instant(0));

    browsers.addSlave(slave);
    BrowserQueryResponseHandler handler =
        new BrowserQueryResponseHandler(null, null, browsers, streamedResponses);
View Full Code Here

TOP

Related Classes of com.google.jstestdriver.TimeImpl

Copyright © 2018 www.massapicom. 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.