def testNavigateAction(self): page = self.CreatePageFromUnittestDataDir('blank.html') i = navigate.NavigateAction() i.RunAction(page, self._tab) self.assertEquals( self._tab.EvaluateJavaScript('document.location.pathname;'), '/blank.html')
def testNavigateAction(self): self._browser.SetHTTPServerDirectories(util.GetUnittestDataDir()) page = self.CreatePageFromUnittestDataDir('blank.html') i = navigate.NavigateAction() i.RunAction(page, self._tab, None) self.assertEquals( self._tab.EvaluateJavaScript('document.location.pathname;'), '/blank.html')
def ImplicitPageNavigation(self, test=None): """Executes the implicit navigation that occurs for every page iteration. This function will be called once per page before any actions are executed. """ if test: test.WillNavigateToPage(self.page, self.tab) test.RunNavigateSteps(self.page, self.tab) test.DidNavigateToPage(self.page, self.tab) else: i = navigate.NavigateAction() i.RunAction(self.page, self.tab, None)
def testNavigateAction(self): i = navigate.NavigateAction(url=self.UrlOfUnittestFile('blank.html')) i.RunAction(self._tab) self.assertEquals( self._tab.EvaluateJavaScript('document.location.pathname;'), '/blank.html')