Search in sources :

Example 11 with NetworkTrafficDump

use of com.wikia.webdriver.common.core.annotations.NetworkTrafficDump in project selenium-tests by Wikia.

the class TestAdsVuapMercury method adsImageClickedOpensNewPageMercury.

@InBrowser(browser = Browser.CHROME, emulator = Emulator.GOOGLE_NEXUS_5)
@NetworkTrafficDump(useMITM = true)
@Test(dataProviderClass = AdsDataProvider.class, dataProvider = "adsVuapMercury", groups = "AdsImageClickedOpensNewPageMercury")
public void adsImageClickedOpensNewPageMercury(Page page, String slotName, String iframeId, String videoUrl) {
    networkTrafficInterceptor.startIntercepting();
    AdsBaseObject ads = new AdsBaseObject(driver, urlBuilder.getUrlForPage(page));
    scrollToSlot(slotName, ads);
    ads.wait.forSuccessfulResponse(networkTrafficInterceptor, videoUrl);
    VideoFanTakeover videoFanTakeover = new VideoFanTakeover(driver, iframeId, slotName);
    videoFanTakeover.clickOnAdImage();
    String tabUrl = ads.switchToNewBrowserTab();
    videoFanTakeover.verifyFandomTabOpened(tabUrl);
}
Also used : AdsBaseObject(com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsBaseObject) VideoFanTakeover(com.wikia.webdriver.pageobjectsfactory.componentobject.ad.VideoFanTakeover) NetworkTrafficDump(com.wikia.webdriver.common.core.annotations.NetworkTrafficDump) Test(org.testng.annotations.Test) InBrowser(com.wikia.webdriver.common.core.annotations.InBrowser)

Example 12 with NetworkTrafficDump

use of com.wikia.webdriver.common.core.annotations.NetworkTrafficDump in project selenium-tests by Wikia.

the class TestAdsDetectionPageFair method adsDetectAdBlockPageFair.

@NetworkTrafficDump
@Test(groups = "AdsDetectAdBlockPageFair", dataProviderClass = AdsDataProvider.class, dataProvider = "adsDetectionPageFair")
public void adsDetectAdBlockPageFair(Page page) {
    networkTrafficInterceptor.startIntercepting();
    AdsPageFairObject adsBaseObject = new AdsPageFairObject(driver, page);
    adsBaseObject.assertPageFairResponse(true, networkTrafficInterceptor);
}
Also used : AdsPageFairObject(com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsPageFairObject) NetworkTrafficDump(com.wikia.webdriver.common.core.annotations.NetworkTrafficDump) Test(org.testng.annotations.Test)

Example 13 with NetworkTrafficDump

use of com.wikia.webdriver.common.core.annotations.NetworkTrafficDump in project selenium-tests by Wikia.

the class TestAdsDetectionPageFair method adsDetectNoAdBlockPageFair.

@NetworkTrafficDump
@Test(groups = "AdsDetectNoAdBlockPageFair", dataProviderClass = AdsDataProvider.class, dataProvider = "adsDetectionPageFair")
public void adsDetectNoAdBlockPageFair(Page page) {
    networkTrafficInterceptor.startIntercepting();
    AdsPageFairObject adsBaseObject = new AdsPageFairObject(driver, page);
    adsBaseObject.assertPageFairResponse(false, networkTrafficInterceptor);
}
Also used : AdsPageFairObject(com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsPageFairObject) NetworkTrafficDump(com.wikia.webdriver.common.core.annotations.NetworkTrafficDump) Test(org.testng.annotations.Test)

Example 14 with NetworkTrafficDump

use of com.wikia.webdriver.common.core.annotations.NetworkTrafficDump in project selenium-tests by Wikia.

the class TestAdsVuapFandom method adsVuapTimeProgressingFandom.

@NetworkTrafficDump
@Test(dataProviderClass = FandomAdsDataProvider.class, dataProvider = "vuapPage", groups = { "AdsVuapFandomDesktop", "AdsVuapTimeProgressingFandom" })
public void adsVuapTimeProgressingFandom(String pageType, String pageName, String slotName, String iframeId) throws InterruptedException {
    AdsFandomObject fandomPage = loadPage(pageName, pageType);
    VideoFanTakeover videoFanTakeover = prepareSlot(slotName, iframeId, fandomPage);
    videoFandomPage(slotName).verifyIsVideoTimeProgresingOnDesktop(networkTrafficInterceptor, videoFanTakeover);
}
Also used : VideoFanTakeover(com.wikia.webdriver.pageobjectsfactory.componentobject.ad.VideoFanTakeover) FandomVideoFanTakeover(com.wikia.webdriver.pageobjectsfactory.componentobject.ad.FandomVideoFanTakeover) AdsFandomObject(com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsFandomObject) NetworkTrafficDump(com.wikia.webdriver.common.core.annotations.NetworkTrafficDump) Test(org.testng.annotations.Test)

Example 15 with NetworkTrafficDump

use of com.wikia.webdriver.common.core.annotations.NetworkTrafficDump in project selenium-tests by Wikia.

the class TestAdsVuapMercury method adsVideoClosedAfterPlayingMercury.

@InBrowser(browser = Browser.CHROME, emulator = Emulator.GOOGLE_NEXUS_5)
@NetworkTrafficDump(useMITM = true)
@Test(dataProviderClass = AdsDataProvider.class, dataProvider = "adsVuapMercury", groups = "AdsTopAdVideoClosesWhenFinishPlaysMercury")
public void adsVideoClosedAfterPlayingMercury(Page page, String slotName, String iframeId, String videoUrl) {
    networkTrafficInterceptor.startIntercepting();
    AdsBaseObject ads = new AdsBaseObject(driver, urlBuilder.getUrlForPage(page));
    scrollToSlot(slotName, ads);
    ads.wait.forSuccessfulResponse(networkTrafficInterceptor, videoUrl);
    VideoFanTakeover videoFanTakeover = new VideoFanTakeover(driver, iframeId, slotName);
    videoFanTakeover.play();
    videoFanTakeover.waitForVideoPlayerHidden();
}
Also used : AdsBaseObject(com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsBaseObject) VideoFanTakeover(com.wikia.webdriver.pageobjectsfactory.componentobject.ad.VideoFanTakeover) NetworkTrafficDump(com.wikia.webdriver.common.core.annotations.NetworkTrafficDump) Test(org.testng.annotations.Test) InBrowser(com.wikia.webdriver.common.core.annotations.InBrowser)

Aggregations

NetworkTrafficDump (com.wikia.webdriver.common.core.annotations.NetworkTrafficDump)29 Test (org.testng.annotations.Test)29 VideoFanTakeover (com.wikia.webdriver.pageobjectsfactory.componentobject.ad.VideoFanTakeover)15 InBrowser (com.wikia.webdriver.common.core.annotations.InBrowser)13 AdsBaseObject (com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsBaseObject)12 FandomVideoFanTakeover (com.wikia.webdriver.pageobjectsfactory.componentobject.ad.FandomVideoFanTakeover)7 AdsFandomObject (com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsFandomObject)7 Execute (com.wikia.webdriver.common.core.annotations.Execute)5 DontRun (com.wikia.webdriver.common.core.annotations.DontRun)2 HomePage (com.wikia.webdriver.pageobjectsfactory.pageobject.HomePage)2 WikiBasePageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.WikiBasePageObject)2 AdsOoyalaObject (com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsOoyalaObject)2 AdsPageFairObject (com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsPageFairObject)2 RelatedIssue (com.wikia.webdriver.common.core.annotations.RelatedIssue)1 UseUnstablePageLoadStrategy (com.wikia.webdriver.common.driverprovider.UseUnstablePageLoadStrategy)1 AdsPrebidObject (com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsPrebidObject)1 AdsTaboolaObject (com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsTaboolaObject)1 InteractiveMapPageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.special.interactivemaps.InteractiveMapPageObject)1 HarEntry (net.lightbody.bmp.core.har.HarEntry)1