How to use protractor-helper - 10 common examples

To help you get started, we’ve selected a few protractor-helper 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 wlsf82 / protractor-components-and-page-objects / test / e2e / components / Form.js View on Github external
fillWithDataAndSubmit(data) {
    helper.fillFieldWithText(this.nameField, data.name);
    helper.fillFieldWithText(this.descriptionField, data.description);
    helper.fillFieldWithText(this.imageUrlField, data.imageUrlValue);
    helper.click(this.submitButton);
  }
}
github wlsf82 / protractor-components-and-page-objects / test / e2e / components / Form.js View on Github external
fillWithDataAndSubmit(data) {
    helper.fillFieldWithText(this.nameField, data.name);
    helper.fillFieldWithText(this.descriptionField, data.description);
    helper.fillFieldWithText(this.imageUrlField, data.imageUrlValue);
    helper.click(this.submitButton);
  }
}
github wlsf82 / protractor-components-and-page-objects / test / e2e / components / Form.js View on Github external
fillWithDataAndSubmit(data) {
    helper.fillFieldWithText(this.nameField, data.name);
    helper.fillFieldWithText(this.descriptionField, data.description);
    helper.fillFieldWithText(this.imageUrlField, data.imageUrlValue);
    helper.click(this.submitButton);
  }
}
github wlsf82 / protractor-components-and-page-objects / test / e2e / specs / createImage.spec.js View on Github external
it("Then all required fields are shown in red, meaning error", () => {
        helper.click(createImagePage.form.submitButton);

        expect(
          createImagePage.form.nameField.getCssValue("background-color")
        ).toEqual("rgb(255,0,0)");
        expect(
          createImagePage.form.descriptionField.getCssValue("background-color")
        ).toEqual("rgb(255,0,0)");
        expect(
          createImagePage.form.imageUrlField.getCssValue("background-color")
        ).toEqual("rgb(255,0,0)");
      });
    });
github wlsf82 / protractor-components-and-page-objects / test / e2e / components / Form.js View on Github external
fillWithDataAndSubmit(data) {
    helper.fillFieldWithText(this.nameField, data.name);
    helper.fillFieldWithText(this.descriptionField, data.description);
    helper.fillFieldWithText(this.imageUrlField, data.imageUrlValue);
    helper.click(this.submitButton);
  }
}
github wlsf82 / protractor-components-and-page-objects / test / e2e / specs / createImage.spec.js View on Github external
it("Then all fields are cleared and a success message is shown", () => {
        helper.waitForTextNotToBePresentInElement(
          createImagePage.form.nameField,
          data.name
        );
        helper.waitForTextNotToBePresentInElement(
          createImagePage.form.descriptionField,
          data.description
        );
        helper.waitForTextNotToBePresentInElement(
          createImagePage.form.imageUrlField,
          data.imageUrlValue
        );

        const successMessage = element(by.css(".success-message"));

        helper.waitForElementVisibility(successMessage);
      });
github wlsf82 / protractor-components-and-page-objects / test / e2e / specs / createImage.spec.js View on Github external
it("Then all fields are cleared and a success message is shown", () => {
        helper.waitForTextNotToBePresentInElement(
          createImagePage.form.nameField,
          data.name
        );
        helper.waitForTextNotToBePresentInElement(
          createImagePage.form.descriptionField,
          data.description
        );
        helper.waitForTextNotToBePresentInElement(
          createImagePage.form.imageUrlField,
          data.imageUrlValue
        );

        const successMessage = element(by.css(".success-message"));

        helper.waitForElementVisibility(successMessage);
      });
    });
github wlsf82 / protractor-components-and-page-objects / test / e2e / specs / createImage.spec.js View on Github external
it("Then all fields are cleared and a success message is shown", () => {
        helper.waitForTextNotToBePresentInElement(
          createImagePage.form.nameField,
          data.name
        );
        helper.waitForTextNotToBePresentInElement(
          createImagePage.form.descriptionField,
          data.description
        );
        helper.waitForTextNotToBePresentInElement(
          createImagePage.form.imageUrlField,
          data.imageUrlValue
        );

        const successMessage = element(by.css(".success-message"));

        helper.waitForElementVisibility(successMessage);
      });
    });
github wlsf82 / protractor-components-and-page-objects / test / e2e / specs / contact.spec.js View on Github external
it("then all required fields are shown in red, meaning error", () => {
                helper.clickWhenClickable(contactPage.form.submitButton);

                expect(contactPage.nameField.getAttribute("warning-color")).toEqual("red");
                expect(contactPage.messageField.getAttribute("warning-color")).toEqual("red");
            });
        });
github wlsf82 / protractor-components-and-page-objects / test / e2e / specs / createImage.spec.js View on Github external
it("Then I'm redirected to the home page", () => {
        helper.waitForUrlToBeEqualToExpectedUrl(browser.baseUrl);
      });
    });