How to use the protractor.element function in protractor

To help you get started, we’ve selected a few protractor examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github process-engine / bpmn-studio / test / e2e / src / pages / xmlView.ts View on Github external
private get _xmlCodeBlock(): ElementFinder {
    const codeBlockByTag: By = by.tagName('code');

    return element(codeBlockByTag);
  }
github rdkmaster / jigsaw / e2e / components / table.e2e-spec.ts View on Github external
it('should set header sort', async () => {
            browser.switchTo().defaultContent();
            await waitForPresence('.jigsaw-table-sort-up');
            const tableSortUp = element(by.css('.jigsaw-table-sort-up')),
                tableSortDown = element(by.css('.jigsaw-table-sort-down')),
                columnFirstEl = element(by.css('.jigsaw-table-body tbody')).all(by.tagName('TR')).first().all(by.tagName('TD')).get(0),
                columnlastEl = element(by.css('.jigsaw-table-body tbody')).all(by.tagName('TR')).last().all(by.tagName('TD')).get(0);
            expect(columnFirstEl.getText()).toBe('Michelle');
            expect(columnlastEl.getText()).toBe('Dave');
            tableSortUp.click();
            expect(columnFirstEl.getText()).toBe('Abner');
            expect(columnlastEl.getText()).toBe('Wanda');
            tableSortDown.click();
            expect(columnFirstEl.getText()).toBe('Wanda');
            expect(columnlastEl.getText()).toBe('Abner');
        })
    });
github buildbot / buildbot / smokes / e2e / pages / builder.ts View on Github external
async go() {
        await browser.get('#/builders');
        await browser.wait(EC.urlContains('#/builders'),
                           10000,
                           "URL does not contain #/builders");
        let localBuilder = element(By.linkText(this.builder));
        await browser.wait(EC.elementToBeClickable(localBuilder),
                           5000,
                           "local builder not clickable");
        await localBuilder.click();
    }
github thisissoon / angular-image-loader / e2e / src / app.po.ts View on Github external
getImageBottomElement() {
    return element(by.css('.sn-image-loader--bottom .img'));
  }
github skycoin / skycoin-web / e2e / wallets.po.ts View on Github external
cancelDeleteConfirmation() {
    let walletCount = 0;
    element.all(by.css('.-wallet')).count().then((count) => walletCount = count);

    return element(by.buttonText('No')).click().then(() => {
      return element.all(by.css('.-wallet')).count().then((count) => {
        return count === walletCount;
      });
    });
  }
github marklogic / marklogic-data-hub / web / e2e / page-objects / steps / steps.ts View on Github external
stepSelectContainer(stepName: string) {
    return element(by.cssContainingText("h3.step-name", stepName));
  }
github marklogic / marklogic-data-hub / web / e2e / page-objects / steps / steps.ts View on Github external
stepTargetFormatOptions(option: string) {
    return element(by.cssContainingText('mat-option .mat-option-text', option));
  }
github gentics / mesh-ui / e2e / page-objects / role-admin / role-admin-list-row.po.ts View on Github external
async addRole(name: string) {
        await this.root.element(by.css('mesh-user-role-select button')).click();
        await element(by.cssContainingText('gtx-dropdown-content gtx-dropdown-item', name)).click();
    }
github goharbor / harbor / src / portal / e2e / app.po.ts View on Github external
getParagraphText() {
    return element(by.css('my-app p')).getText();
  }
}
github marklogic / marklogic-data-hub / web / e2e / page-objects / steps / masteringStep.ts View on Github external
matchOptionWeightInput(property: string) {
    return element(by.css(`.match-option-${property} .match-option-weight input.mat-input-element`));
  }