JSConf JP

Mesut Durukal

Mesut Durukal

https://mesutdurukal.github.io/himesut/

Track C (3F 302)
13:40-14:10(30 min)

Boost your Test Implementation in Javascript by 10x?

  • English

Elevator Pitch --------------- How can we facilitate involving everyone in testing, namely holistic testing, and making collaboration as a whole team? In one of my last projects, I experienced developing a framework, by which we not only easily onboarded all parties in automation, but also reduced duplication. In this talk, I will share my story to reduce the average test implementation duration from 5 hours to 30 mins. Problem: --------------- There are various problems in testing. Firstly, to encourage holistic testing, we have to spread the quality mindset and make everyone (including developers and other roles) involved. For this purpose, test implementation should be simplified to facilitate this process. Secondly, especially in large organizations, several teams or groups are trying to cope with the same or similar technical challenges in different ways. They are even unaware of each other. To summarize: * There is no standard among these teams: Each is following a different approach/strategy. * Some of them are struggling with problems, which were solved by others. The effort is duplicated. To have a better understanding of the implementation variations, I attached a slide where I showed how a simple scenario could be automated in 4 different ways: https://drive.google.com/file/d/1c0aboWtk9WffpxNHCSuooI3QfvrrTsD0 Solution: --------------- We came up with the centralized test framework development idea. The motivation was to develop a framework in which the most common problems were handled and serve the teams. In this way, we would remove the imbalance, support those who are struggling with the problems that were solved by others, and ensure the code quality in all test frameworks used by several teams. I will show the architecture of a well-structured central framework, which includes:

  • Test runner * Parallelization (in local and remote, in spec and test levels) * Retries (in test and failing requests level) * Test reporter (Test level isolated execution details) * Config management (Execution parameters) * Execution Metrics collection Outcomes: --------------- The achievements of the distributed central framework are:
  • Ease of Automation: Average test automation duration from 5 hours to 30 mins * Execution speed: Fast runs * Reliability: Low false alarm rate * Maintainability: Fast test fixes Takeaways --------------- In this session, attendees will see: * How to publish a test automation framework * Ways to improve the reusability of tests * Solutions against flakiness and maintenance. * Ways to improve troubleshooting in test executions Agenda --------------- 7 mins: Introduction: Problem definition, Proposal: Benefits of a distributed test package 8 mins: Strategy: Things to consider for a well-equipped framework 5 mins: Architecture: Building the components 5 mins: Monitoring: Key quality metrics 5 mins: Summary & QA