lets say, you are QA manager and i am a QA and Manager asked you to start implementing automation testing for regression testcases for a website first. how would you do it? this will be my approach: Since we already have a set of manual regression test cases, I’d begin by reviewing and prioritizing them. Not all test cases are worth automating immediately—some may be too unstable or rarely executed. So, I'd focus first on high-impact, frequently executed tests like login, signup, checkout, and other critical flows. I'd organize these into a clear, shared spreadsheet or test management tool and tag them as "Ready for Automation." a tag always helps. Next, I’d set up a basic Java + Selenium framework. If we don’t already have one, I’d recommend using Maven for dependency management, TestNG or JUnit for test orchestration, and Page Object Model (POM) as the design pattern to keep our tests modular and maintainable. I'd also propose integrating ExtentReports for test reporting and Log4j for logging. I can bootstrap this framework myself or pair with a dev/test automation resource if needed. Once the skeleton framework is ready, I’d start converting manual test cases into automated scripts one by one. I’d begin with the smoke tests and top-priority regressions. For each script, I’d ensure proper setup, execution, teardown, and validations using assertions. then, I’ll commit code to a shared Git repo with meaningful branches and naming conventions. For execution, I'd run the tests locally first, then configure them to run on different browsers. Later, we can integrate the suite with a CI/CD tool like Jenkins to schedule regular test runs (e.g., nightly builds or pre-release checks). This would give us feedback loops without manual intervention. I’d document everything—how to run the tests, add new ones, and generate reports—so the team can scale this effort. I’d also recommend setting aside a couple of hours weekly to maintain and update tests as the app evolves. Finally, I’d keep you in the loop with weekly updates on automation progress, blockers, and test coverage. Once the core regression suite is automated and stable, we can expand into edge cases, negative tests, and possibly integrate with tools like Selenium Grid or cloud providers (e.g., BrowserStack) for cross-browser coverage. what will you be your action plan? let's share. #testautomation #automationtesting #testautomationframework #sdets
Software Testing Best Practices
Explore top LinkedIn content from expert professionals.
-
-
22 Test Automation Framework Practices That Separate Good SDETs from Great Ones Here's what actually works: 1. KISS Principle Break complex tests into smaller modules. Avoid singletons that kill parallel execution. Example: Simple initBrowser() method instead of static WebDriver instances. 2. Modular Approach Separate test data, utilities, page objects, and execution logic. Example: LoginPage class handles only login elements and actions. 3. Setup Data via API/DB Never use UI for test preconditions. It's slow and flaky. Example: RestAssured POST to create test users before running tests. 4. Ditch Excel for Test Data Use JSON, XML, or CSV. They're faster, easier to version control, and actually work. Example: Jackson ObjectMapper to read JSON into POJOs. 5. Design Patterns Factory: Create driver instances based on browser type Strategy: Switch between different browser setups Builder: Construct complex test objects step by step 6. Static Code Analysis SonarLint catches unused variables and potential bugs while you code. 7. Data-Driven Testing Run same test with multiple data sets using TestNG DataProvider. Example: One login test, 10 different user credentials. 8. Exception Handling + Logging Log failures properly. Future you will thank present you. Example: Logger.severe() with meaningful error messages. 9. Automate the Right Tests Focus on repetitive, critical tests. Each test must be independent. 10. Wait Utilities WebDriverWait with explicit conditions. Never Thread.sleep(). Example: wait.until(ExpectedConditions.visibilityOfElementLocated()) 11. POJOs for API Type-safe response handling using Gson or Jackson. Example: Convert JSON response directly to User object. 12. DRY Principle Centralize common locators and setup/teardown in BaseTest class. 13. Independent Tests Each test sets up and cleans up its own data. Enables parallel execution. 14. Config Files URLs, credentials, environment settings—all in external properties files. Example: ConfigReader class to load properties. 15. SOLID Principles Single responsibility per class. Test logic separate from data and helpers. 16. Custom Reporting ExtentReports with screenshots, logs, and environment details. 17. Cucumber Reality Check If you're not doing full BDD, skip Cucumber. It adds complexity without value. 18. Right Tool Selection Choose based on project needs, not trends. Evaluate maintenance cost. 19. Atomic Tests One test = one feature. Fast, reliable, easy to maintain. 20. Test Pyramid Many unit tests (fast) → Some API tests → Few UI tests (slow). 21. Clean Test Data Create in @BeforeMethod, delete in @AfterMethod. Zero data pollution. 22. Data-Driven API Tests Dynamic assertions, realistic data, POJO response validation. Which practice transformed your framework the most? -x-x- Most asked SDET Q&A for 2025 with SDET Coding Interview Prep (LeetCode): https://lnkd.in/gFvrJVyU #japneetsachdeva
-
The biggest businesses can get major programmes horribly wrong. Here are 4 famous examples, the fundamental reasons for failure and how that might have been avoided. Hershey: Sought to replace its legacy IT systems with a more powerful ERP system. However, due to a rushed timeline and inadequate testing, the implementation encountered severe issues. Orders worth over $100 million were not fulfilled. Quarterly revenues fell by 19% and the share price by 8% Key Failures: ❌ Rushed implementation without sufficient testing ❌ Lack of clear goals for the transition ❌ Inadequate attention and resource allocation Hewlett Packard: Wanted to consolidate its IT systems into one ERP. They planned to migrate to SAP, expecting any issues to be resolved within 3 weeks. However, due to the lack of configuration between the new ERP and the old systems, 20% of customer orders were not fulfilled. Insufficient investment in change management and the absence of manual workarounds added to the problems. This entire project cost HP an estimated $160 million in lost revenue and delayed orders. Key Failures: ❌ Failure to address potential migration complications. ❌ Lack of interim solutions and supply chain management strategies. ❌ Inadequate change management planning. Miller Coors: Spent almost $100 million on an ERP implementation to streamline procurement, accounting, and supply chain operations. There were significant delays, leading to the termination of the implementation partner and subsequent legal action. Mistakes included insufficient research on ERP options, choosing an inexperienced implementation partner, and the absence of capable in-house advisers overseeing the project. Key Failures: ❌ Inadequate research and evaluation of ERP options. ❌ Selection of an inexperienced implementation partner. ❌ Lack of in-house expertise and oversight. Revlon: Another ERP implementation disaster. Inadequate planning and testing disrupted production and caused delays in fulfilling customer orders across 22 countries. The consequences included a loss of over $64 million in unshipped orders, a 6.9% drop in share price, and investor lawsuits for financial damages. Key Failures: ❌ Insufficient planning and testing of the ERP system. ❌ Lack of robust backup solutions. ❌ Absence of a comprehensive change management strategy. Lessons to be learned: ✅ Thoroughly test and evaluate new software before deployment. ✅ Establish robust backup solutions to address unforeseen challenges. ✅ Design and implement a comprehensive change management strategy during the transition to new tools and solutions. ✅ Ensure sufficient in-house expertise is available; consider capacity of those people as well as their expertise ✅ Plan as much as is practical and sensible ✅ Don’t try to do too much too quickly with too few people ✅ Don’t expect ERP implementation to be straightforward; it rarely is
-
We all have our go-to test cases. But sometimes, the sneaky bugs hide in the places we don’t think to look. Here are 12 test scenarios that often get missed: 🔄 Using the browser back button 💤 Leaving a session idle, then coming back 📱 Switching from WiFi to mobile data mid-action 🔍 Zooming in/out on mobile or desktop 💾 Saving without filling all required fields 🕓 Schedule submitting a form right at midnight (date-related edge cases!) 🔗 Opening multiple tabs of the same app ⛔ Trying activities with limited user permissions 🌍 Using different keyboard layouts with language settings ✍️ Inputting emojis, special characters, or long text 🧪 Rapid double-clicking or tapping buttons 📥 Uploading weird file types or broken files These may seem small… until they break something in production. Sometimes it’s the “what if” moments that make the biggest difference. What would you add to the list? QA Touch #softwaretesting #edgecases #exploratorytesting #QA #bughunting #testingtips #qa #QATouch #qatouch
-
A new study shows that even the best financial LLMs hallucinate 41% of the time when faced with unexpected inputs. FailSafeQA, a new benchmark from Writer, tests LLM robustness in finance by simulating real-world mishaps, including misspelled queries, incomplete questions, irrelevant documents, and OCR-induced errors. Evaluating 24 top models revealed that: * OpenAI’s o3-mini, the most robust, hallucinated in 41% of perturbed cases * Palmyra-Fin-128k-Instruct, the model best at refusing irrelevant queries, still struggled 17% of the time FailSafeQA uniquely measures: (1) Robustness - performance across query perturbations (e.g., misspelled, incomplete) (2) Context Grounding - the ability to avoid hallucinations when context is missing or irrelevant (3) Compliance - balancing robustness and grounding to minimize false responses Developers building financial applications should implement explicit error handling that gracefully addresses context issues, rather than solely relying on model robustness. Developing systems to proactively detect and respond to problematic queries can significantly reduce costly hallucinations and enhance trust in LLM-powered financial apps. Benchmark details https://lnkd.in/gq-mijcD
-
❌ Behavior-Driven Development (BDD) is NOT Cucumber ❌ There's a common misconception that BDD is just another name for tools like Cucumber. While Cucumber is a popular tool used in BDD, it's important to recognize that BDD is a philosophy and a mindset rather than just a specific tool or framework. ✅ BDD is NOT Cucumber: At its core, BDD is about fostering collaboration, enhancing communication, and ensuring that software development efforts are aligned with the needs and expectations of stakeholders, particularly end users. So, what exactly is BDD if it's not just about Cucumber? 📌 BDD is a collaborative approach: BDD emphasizes collaboration among all stakeholders. This includes developers, testers, business analysts, product owners, and end users. By bringing everyone together to discuss and define the behaviour of the system in a common language, BDD ensures that everyone is on the same page from the outset. 📌 BDD focuses on behaviour: At its heart, BDD is all about defining the behaviour of the software from the perspective of its users. This means describing how the system should behave in various scenarios or situations. For instance, imagine a banking application where a user deposits money into their account. In BDD, this scenario might be expressed as "Given the user has logged into their account when they deposit 100, then the account balance should increase by 100." This concrete example clarifies the expected behaviour of the application. 📌 BDD uses executable specifications: One of the key principles of BDD is the creation of executable specifications. These are written in a human-readable format using Given-When-Then syntax, which describes the initial context, the action being taken, and the expected outcome. These specifications serve as living documentation that can be understood by both technical and non-technical stakeholders. 📌 BDD is about continuous feedback: Another aspect of BDD is its emphasis on continuous feedback loops. By involving stakeholders throughout the development process, teams can gather feedback early and often, making it easier to course-correct and adapt to changing requirements. This iterative approach helps in delivering software that truly meets user needs and expectations. 📌 BDD promotes shared understanding: BDD encourages teams to use a common language, a language that is understood by everyone involved in the project. This shared understanding fosters better communication and reduces the chances of misunderstandings or misinterpretations. It ensures that everyone is speaking the same language when discussing requirements, which leads to more accurate implementation and fewer errors. 📌 BDD enhances Test-Driven Development (TDD): While BDD and TDD are distinct methodologies, they complement each other well. BDD provides a higher-level perspective, focusing on the behaviour of the system, while TDD drills down into the implementation details by writing tests before writing code.
-
🎯 Quality of Test Automation Scripts: A Real-Life Experience 🎯 A few years ago, I faced a challenging experience during a knowledge transfer of an automation project for a healthcare application. This project, handed over by a large Service Integration firm, comprised thousands of scripts but guess what? Less than 5% of these scripts were functional! 😮 At first, I questioned the competence of my fresh assembled team, but further investigation revealed a different culprit: The quality of the automation scripts. They were riddled with hard-coded values, depended heavily on test data, and had poor code commenting. From this experience, I learnt that the quality of test automation scripts is as essential as the tests they are designed to perform. It's not just about writing scripts, but writing good, functional scripts. If you spend time upfront to ensure this quality, it could save you a lot of headaches later on. So, my fellow professionals, I share these tips with you: 1️⃣ Avoid hard coding values. It makes your scripts rigid and prone to failure. 2️⃣ Minimize test data dependencies where possible. Your script should not fail because of data changes. 3️⃣ Don't neglect code commenting. It's essential for understanding what the script is intended to do and aids maintenance and knowledge transfer. Let's strive for quality in our test automation scripts. Because the quality of your scripts can affect the quality of the product you're testing. What's been your experience with test automation scripts? Do you have any additional tips to share? #TestAutomation #QualityAssurance #SoftwareTesting
-
For many years I'd fallen into the bad habit of not distinguishing between fakes, mocks, and stubs when writing or talking about software testing. It's more than semantics, even if you disagree with the validity of this approach. Using definitions, helps in choosing the right tool for the job, which means better tests, which means more confidence in your code. Here’s a brief overview of commonly used "test doubles" [1], a concept I consider to be vital in building software. 1. Dummy Objects: Used only to fill parameter lists, they are never actually used. Example: Passing a null object to a function just to fulfill its signature. 2. Fake Objects: are working implementations, but are simplified/trivial versions. Example: An in-memory database for testing instead of a real database. 3. Stubs: provide "canned" answers to calls made during the test, usually not responding to anything outside what's programmed in for the test. Example: A method returning hard-coded responses when called. 4. Spies: record information about the calls they receive, allowing verification of the interaction. Example: Logging how many times a function was called. 5. Mocks: Objects pre-programmed with expectations which form a specification of the calls they are expected to receive. Example: Verifying a user authentication service was called with the correct credentials. Most systems will not require this level of granularity or design-separation. However, in large scale, complex systems with lots of services and dependencies these separations help a LOT with reasoning through test cases. More info: https://lnkd.in/eeqWRhf8 and https://lnkd.in/e45mpATj
-
🔍 Ensuring Effective Testing with Legacy Code: A Journey of Continuous Improvement! 🚀 Working with legacy code can be both challenging and rewarding! As software professionals, we understand the importance of maintaining and enhancing existing systems while keeping up with evolving technologies. But how do we ensure effective testing in the realm of legacy code? Let's explore some steps that have proved invaluable in my experience! 🎯 1️⃣ Understanding the Legacy Codebase: Dive deep into the legacy code, acquaint yourself with its architecture, and identify critical components. This knowledge forms the foundation of your testing strategy. 2️⃣ Comprehensive Test Documentation: Create detailed test documentation, covering both the existing functionalities and potential edge cases. Documenting test scenarios helps catch regressions and ensures consistent testing efforts. 3️⃣ Incremental Refactoring: Gradual refactoring helps in making the code more testable. By breaking complex methods into smaller, manageable units, we pave the way for efficient unit testing. 4️⃣ Test Automation: Introduce test automation to validate the legacy code with each change. Automated tests act as a safety net, alerting us if any modifications inadvertently impact existing functionalities. 5️⃣ Test Prioritization: Prioritize testing based on the parts of the legacy code most prone to bugs or the ones experiencing frequent changes. Targeting critical areas first maximizes the effectiveness of testing efforts. 6️⃣ Regression Testing: With each code modification or enhancement, perform thorough regression testing to ensure new features don't adversely affect existing functionalities. 7️⃣ Embrace Code Coverage Metrics: Measure code coverage regularly to gauge the effectiveness of your tests. Aim for optimal coverage to minimize untested code paths. 8️⃣ Collaboration and Code Reviews: Engage in regular code reviews and encourage collaboration among team members. A fresh pair of eyes can spot potential issues that may have gone unnoticed. 9️⃣ Learning from Defects: When defects are discovered, view them as learning opportunities. Analyze the root causes and adapt your testing approach to prevent similar issues in the future. 🌟 Remember, effective testing with legacy code is an iterative process. Embrace continuous improvement, learn from challenges, and adapt your strategies as the codebase evolves. Together, we can ensure robust software, even in the realm of legacy systems! 🚀 #SoftwareTesting #LegacyCode #TestAutomation #CodeRefactoring #ContinuousImprovement #QualityAssurance #SoftwareDevelopment #TechIndustry #TestingStrategies
-
Exciting New Research on LLM Evaluation Validity! I just read a fascinating paper titled "LLM-Evaluation Tropes: Perspectives on the Validity of LLM-Evaluations" that addresses a critical issue in our field: as Large Language Models (LLMs) increasingly replace human judges in evaluating information retrieval systems, how can we ensure these evaluations remain valid? The paper, authored by researchers from universities and companies across multiple countries (including University of New Hampshire, RMIT, Canva, University of Waterloo, The University of Edinburgh, Radboud University, and Microsoft), identifies 14 "tropes" or recurring patterns that can undermine LLM-based evaluations. The most concerning trope is "Circularity" - when the same LLM is used both to evaluate systems and within the systems themselves. The authors demonstrate this problem using TREC RAG 2024 data, showing that when systems are reranked using the Umbrela LLM evaluator and then evaluated with the same tool, it creates artificially inflated scores (some systems scored >0.95 on LLM metrics but only 0.68-0.72 on human evaluations). Other key tropes include: - LLM Narcissism: LLMs prefer outputs from their own model family - Loss of Variety of Opinion: LLMs homogenize judgment - Self-Training Collapse: Training LLMs on LLM outputs leads to concept drift - Predictable Secrets: When LLMs can guess evaluation criteria For each trope, the authors propose practical guardrails and quantification methods. They also suggest a "Coopetition" framework - a collaborative competition where researchers submit systems, evaluators, and content modification strategies to build robust test collections. If you work with LLM evaluations, this paper is essential reading. It offers a balanced perspective on when and how to use LLMs as judges while maintaining scientific rigor.