当前位置: 首页>>代码示例>>TypeScript>>正文


TypeScript browser.navigate方法代码示例

本文整理汇总了TypeScript中protractor.browser.navigate方法的典型用法代码示例。如果您正苦于以下问题:TypeScript browser.navigate方法的具体用法?TypeScript browser.navigate怎么用?TypeScript browser.navigate使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在protractor.browser的用法示例。


在下文中一共展示了browser.navigate方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。

示例1: it

 it('Performing action "add" on "texts"', () => {
   // Navigate back to Project Page
   browser.navigate().back();
   browser.navigate().back();
   expect<any>(projectPage.notice.list.count()).toBe(0);
   projectPage.addNewText(constants.testText3Title, projectPage.testData.simpleUsx1);
   projectPage.notice.waitToInclude('The text \'' + constants.testText3Title + '\' was added successfully');
   projectPage.notice.firstCloseButton.click();
 });
开发者ID:sillsdev,项目名称:web-languageforge,代码行数:9,代码来源:activity.e2e-spec.ts

示例2: it

    it('can use the chapter trimmer to trim the USX when creating a new text', () => {
      const newTextTitle = sampleTitle + '6789'; // Don't re-use title from an existing text
      expect<any>(projectPage.newText.showFormButton.isDisplayed()).toBe(true);
      projectPage.newText.showFormButton.click();
      browser.wait(ExpectedConditions.visibilityOf(projectPage.newText.title), constants.conditionTimeout);
      projectPage.newText.title.sendKeys(newTextTitle);
      Utils.sendText(projectPage.newText.usx, projectPage.testData.longUsx1);
      projectPage.newText.verseRangeLink.click();
      browser.wait(ExpectedConditions.visibilityOf(projectPage.newText.fromChapter), constants.conditionTimeout);
      projectPage.newText.fromChapter.sendKeys('1');
      projectPage.newText.fromVerse.sendKeys('1');
      projectPage.newText.toChapter.sendKeys('1');
      projectPage.newText.toVerse.sendKeys('3');
      projectPage.newText.saveButton.click();
      expect<any>(SfProjectPage.textLink(newTextTitle).isDisplayed()).toBe(true);
      SfProjectPage.textLink(newTextTitle).click();
      expect(questionListPage.textContent.getText()).not.toMatch('/Cana of Galilee/');
      browser.navigate().back();

      // clean up the text
      util.setCheckbox(projectPage.getFirstCheckbox(), true);
      const archiveButton = projectPage.archiveTextButton.getWebElement();
      archiveButton.click();
      Utils.clickModalButton('Archive');
    });
开发者ID:sillsdev,项目名称:web-languageforge,代码行数:25,代码来源:project.e2e-spec.ts

示例3: it

 it('can change properties and verify they persist', () => {
   projectSettingsPage.projectTab.name.clear();
   projectSettingsPage.projectTab.name.sendKeys(newName);
   projectSettingsPage.projectTab.allowAudioDownload.click();
   projectSettingsPage.projectTab.saveButton.click();
   browser.navigate().refresh();
   projectSettingsPage.tabs.project.click();
   expect(projectSettingsPage.projectTab.name.getAttribute('value')).toBe(newName);
   expect(projectSettingsPage.projectTab.allowAudioDownload.getAttribute('checked')).toBeFalsy();
   projectSettingsPage.get(newName);
   projectSettingsPage.tabs.project.click();
   projectSettingsPage.projectTab.name.clear();
   projectSettingsPage.projectTab.name.sendKeys(constants.testProjectName);
   projectSettingsPage.projectTab.saveButton.click();
 });
开发者ID:,项目名称:,代码行数:15,代码来源:

示例4: it

 it('can re-publish the question that was just archived (Text Settings)', () => {
   SfTextPage.clickTextSettingsButton();
   browser.wait(ExpectedConditions.visibilityOf(textSettingsPage.tabs.archiveQuestions),
     constants.conditionTimeout);
   textSettingsPage.tabs.archiveQuestions.click();
   browser.wait(ExpectedConditions.visibilityOf(textSettingsPage.archivedQuestionsTab.questionLink(questionTitle)),
     constants.conditionTimeout);
   expect<any>(textSettingsPage.archivedQuestionsTab.questionLink(questionTitle).isDisplayed()).toBe(true);
   const publishButton = textSettingsPage.archivedQuestionsTab.publishButton.getWebElement();
   expect<any>(publishButton.isDisplayed()).toBe(true);
   expect<any>(publishButton.isEnabled()).toBe(false);
   util.setCheckbox(textSettingsPage.archivedQuestionsTabGetFirstCheckbox(), true);
   expect<any>(publishButton.isEnabled()).toBe(true);
   publishButton.click();
   expect<any>(textSettingsPage.archivedQuestionsTab.questionLink(questionTitle).isPresent()).toBe(false);
   expect<any>(publishButton.isEnabled()).toBe(false);
   browser.navigate().back();
   expect<any>(SfTextPage.questionLink(questionTitle).isDisplayed()).toBe(true);
 });
开发者ID:sillsdev,项目名称:web-languageforge,代码行数:19,代码来源:text.e2e-spec.ts

示例5:

browser.waitForAngular();
browser.waitForAngular('');
browser.findElement('');
browser.findElements('');
browser.isElementPresent('');
browser.addMockModule('', '');
browser.addMockModule('', '', ['','']);
browser.addMockModule('', () => {});
browser.addMockModule('', () => {}, ['','']);
browser.clearMockModules();
browser.removeMockModule('');
browser.getRegisteredMockModules();
browser.get('url');
browser.refresh();
browser.refresh(100);
browser.navigate();
browser.setLocation('url');
browser.getLocationAbsUrl();
browser.debugger();
browser.enterRepl();
browser.enterRepl(100);
browser.pause();
browser.pause(100);
browser.actions();
browser.wait('condition');
browser.wait('condition', 100);
browser.wait('condition', 100, 'message');
browser.getCurrentUrl();
browser.getTitle();
browser.takeScreenshot();
by.addLocator('name', () => {});
开发者ID:HelloMQL,项目名称:protractor,代码行数:31,代码来源:test_pass.ts

示例6: clickBrowserBackButton

export async function clickBrowserBackButton() {
    return browser.navigate().back();
}
开发者ID:,项目名称:,代码行数:3,代码来源:


注:本文中的protractor.browser.navigate方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。