Test Automation using Protractor, Jasmine, and TypeScript

0

Protractor is an end-to-end (e2e) test framework for Angular and AngularJS applications. Protractor runs tests against your application running in a real browser, interacting with it as a user would.

Protractor is an end-to-end (e2e) test framework for Angular and AngularJS applications. Protractor runs tests against your application running in a real browser, interacting with it as a user would.

Protractor is built on top of WebDriverJS, which uses native events and browser-specific drivers to interact with your application as a user would.

Protractor supports Angular-specific locator strategies, which allows you to test Angular-specific elements without any setup effort on your part. Not just Angular application but non-angular application too can be automated.

You no longer need to add waits and sleeps to your test. Protractor can automatically execute the next step in your test the moment the webpage finishes pending tasks, so you don’t have to worry about waiting for your test and webpage to sync.

Reference: https://www.protractortest.org

Let go through step by step process of creating automation framework using ProtractorJasmine, and TypeScript. At the end of this tutorial, you will be having knowledge of setting up the framework from scratch:

You can download the sample framework from GitHub where I’ve create few simple tests for demo site which is in AugularJS and Non-AngularJS.

The sample framework is hosted on GitHub. Have a suggestion or found a bug? Fork this project to help make this even better: protractor-jasmine-typescript

FAQ’S:

WHAT DO YOU THINK?

Did this work for you?
Could I have done something better?
Have I missed something?

Please share your thoughts using comments on this post. Also, let me know if there are particular things that you would enjoy reading further.

Cheers!

Leave a Reply

Your email address will not be published. Required fields are marked *