
Welcome Note and Small Introduction about myself
Identify prerequisites for this Java-based course, requiring basic Java knowledge and testing experience, and outline issues with reading property and Excel files using associated libraries.
Explore clumsy Java test code with manual type conversions, string handling, and list construction, verbose comparisons that lead to errors, and see how cleaner tests emerge next week.
Learn how key annotations map configuration values and how default values prevent missing data, with quotes guiding library conversions to the correct type in tests.
Discover fixture factory and how to create modules with templates by defining rules using the official GitHub repository. Generate objects based on those templates in your code.
Explore fixture factory with Java Faker to generate fake names and random values, build reusable methods and lists, and run data-driven tests using the library.
Create and implement an address template for the employee template using a template-based approach with the Fiction Factory tool, enabling inheritance and override of rules.
Explore how Lombok reduces boilerplate in Java by using annotations for no-args and all-args constructors and toString, speeding up SDET-focused development.
Learn how Lombok automates boilerplate in Java by adding the Lombok dependency and plugin, generating getters, constructors, builders, and static factory methods to create immutable objects.
Java have lot of amazing external libraries which can help us to write clean code. I have covered 4 of those amazing libraries in detail and how to use them in real time projects.
1. Owner - To resolve the problems we face while reading property files.
Owner Library can help to reduce all the boiler plate code we write while reading property files. No need to do Exception Handling. It comes bundled with some amazing features like DefaultValue on missing attributes, Key Annotation for Mapping and much more.
2. Zerocell - To resolve the problems we face while reading excel sheet. Excel Reading - No more a pain
We normally use Apache poi library for Excel Reading in Java. However we need to write lot of code to get the work done. Working with different data types like Integer, date, comma separated string in excel is again a big problem. Zero cell provides solution for all the boiler plate code we write.
Reusable Converter classes helps us to maintain the business logic away from tests.
3. Fixture Factory - Generate POJO's for you rest assured tests using Template - Easy and Fast.
We normally generate POJO's for testing rest services. However we spend so much of time in passing the values to the POJO fields. Fixture Factory helps us to create objects based on template and can create 1000's of objects on the fly.
4. Lombok - Say Good Bye to Verbosity.
Implement these libraries in your company and stun your colleagues !