Skip to content

theprashant-one/ui-testing-best-practices

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

UI Testing Best Practices (Work in progress)

UI testing Best Practices


2 items Last update: June 17, 2019

NoriSte Follow me on Twitter! @NoriSte


Built and maintained by our Steering Committee and Collaborators

Latest Best Practices and News

(Work in progress)



Welcome! 3 Things You Ought To Know First:

1. You are, in fact, reading dozens of the best UI testing articles - this repository is a summary and curation of the top-ranked content on UI testing best practices, as well as content written here by collaborators

2. It is the largest compilation, and it is growing every week - currently, more than XX best practices, style guides, and architectural tips are presented. New issues and pull requests are welcome to keep this live book updated. We'd love to see you contributing here, whether that is fixing code mistakes, helping with translations, or suggesting brilliant new ideas. See our writing guidelines here

3. Most best practices have additional info - most bullets include a 🔗Read More link that expands on the practice with code examples, quotes from selected blogs and more information



Table of Contents

(Work in progress, take a look at the sections draft file)

  1. Generic Best Practices (1)

1. Generic Best Practices

✔ 1.1 Await, don't sleep

TL;DR: When testing your UI, you define a sort of key points the app must pass through. Reaching these key points is an asynchronous process because, almost 100% of the times, your UI does not update synchronously. Those key points are called deterministic events, as known as something that you know that must happen. You need to wait for these events to make your tests robust.

Otherwise: Sleeping the tests make your tests slow and brittle, it's one of the most common and biggest errors in UI testing.

🔗 Read More: Await, don't sleep


✔ 1.2 Name your test files wisely

TL;DR: Lot of times you need to launch just a type of tests and it's super easy if you follow a common pattern while naming your testing files.

Otherwise: You need to launch a long test suite just to have some of them run.

🔗 Read More: Name the test files wisely


✔ 1.3 Use your testing tool as your primary development tool

TL;DR: Leveraging your testing tool to avoid manual tests is one of the biggest improvements you could do to speed up your working flow. Testing tools are faster than you and the most modern ones include some UI utilities that make easy to use them as a development tool.

Otherwise: You code the app the old way, losing a lot of time interacting manually with the UI itself.

🔗 Read More: Use your testing tool as your primary development tool







Steering Committee

Meet the steering committee members - the people who work together to provide guidance and future direction to the project.

Stefano Magni

A positive-minded front-end developer. He's a passion for good UIs, automation, testing and teaching. He's developed every kind of interface: webapps, mobile apps, smartTV apps and games.


Collaborators

Thank you to all our collaborators! 🙏

Our collaborators are members who are contributing to the repository on a reguar basis, through suggesting new best practices, triaging issues, reviewing pull requests and more. If you are interested in helping us guide thousands of people to craft better UI tests, please read our contributor guidelines 🎉


Thank You Notes

We appreciate any contribution, from a single word fix to a new best practice. Below is a list of everyone who contributed to this project. A 🌻 marks a successful pull request and a ⭐ marks an approved new best practice.

Flowers

A successfull PR gives you a 🌻, be the first to collect it.

Stars

An approved new best practice Be the first to collect a ⭐, contribute to this repository 😁




This repository is inspired to the nodebestpractices one, thank you Yoni and the whole steering team to keep it updated and to allow the creation of this repository.




About

The largest UI testing best practices list (July 2019) (work in progress)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published