DEV Community

subash
subash

Posted on

Task 14

Q1.
Manual Testing;
• Manual Testing involves human intervention to execute test cases without the use of automation tools.
• Testers manually execute test cases, observe the software behaviour, and record the result.
• It is suitable for exploratory testing, ad-hoc testing, and when human judgment and creativity are required.
• Manual testing is often used in the early stage of development when the software is undergoing frequent changes or when testing user interfaces for usability.
• It can be time- consuming and labour-intensive, especially in testing repetitive, large- scale efforts.
• Manual testing sometimes not feasible for large volumes of test cases or for conducting regression testing efficiently.

Automated Testing:
• Automated testing involves the use of automation tools and scripts to execute test cases automatically without human intervention.
• Test scripts are created to perfume predefined actions, validate expected outcomes, and report result automatically.
• It is suitable for repetitive tasks, regression testing, and scenarios where the same tests need to be executed frequently.
• Automated testing helps improve efficiency, reduce human errors, and provide faster feedback on the quality of the software.
• It requires initial investment in creating and maintaining test scripts, but it can save time and effort in the long run, especially for large and complex software projects.
• Automated testing is often integrated into the software development process, allowing for continuous testing and continuous integration (CI/CD) workflows.

Q2.

  1. Selenium Web Driver - Selenium is a popular open-source automation testing framework for web applications. Selenium WebDriver allows testers to automate web browsers across different platforms and supports multiple programming languages such as Java, Python, C#, etc.

  2. Appium - Appium is an open-source automation tool for mobile applications, supporting both Android and iOS platforms. It allows testers to automate native, hybrid, and mobile web applications using a single API.

  3. Jenkins - Jenkins is an open-source automation server used for continuous integration and continuous delivery (CI/CD). It automates the build, test, and deployment processes, facilitating automation testing as part of the development pipeline.

  4. TestNG - TestNG is a testing framework for Java inspired by JUnit and NUnit. It provides features such as annotations, grouping, parameterization, and parallel execution, making it suitable for automation testing.

  5. JUnit - JUnit is a widely used unit testing framework for Java. It provides annotations and assertions to write and execute automated tests for Java applications.

  6. Cucumber - Cucumber is a behaviour-driven development (BDD) tool that supports automation testing using a domain-specific language called Gherkin. It enables collaboration between technical and non-technical stakeholders by writing test scenarios in natural language.

  7. Postman - Postman is a collaboration platform for API development that also offers automated testing capabilities. It allows testers to create and execute automated API tests, monitor API performance, and generate comprehensive test reports.

  8. JMeter - Apache JMeter is an open-source performance testing tool used for load testing and stress testing of web applications, APIs, and databases. It allows testers to simulate concurrent user activity and measure system performance under various conditions.

Q4.
Cross-browser testing is a type of software testing that ensures a web application or website functions correctly and consistently across different web browsers, browser versions, and operating systems. Since web browsers may interpret HTML, CSS, and JavaScript code differently, cross-browser testing is essential to identify and fix compatibility issues that may arise when users access the application from various browsers and devices.

1. Browser Compatibility: Web applications should work seamlessly across popular web browsers such as Google Chrome, Mozilla Firefox, Microsoft Edge, Safari, and Opera. Cross-browser testing verifies that the application's layout, functionality, and performance are consistent across different browsers.
2. Browser Versions: In addition to testing across different browsers, cross-browser testing involves checking the application's compatibility with various versions of each browser. Browser versions may have different rendering engines and support different HTML, CSS, and JavaScript features, leading to inconsistencies in how the application is displayed and behaves.
3. Operating Systems: Cross-browser testing also considers the compatibility of the web application across different operating systems such as Windows, macOS, Linux, iOS, and Android. Operating system-specific behaviours, fonts, and rendering may affect the appearance and functionality of the application.
4. Responsive Design: With the increasing use of mobile devices and tablets to access websites, cross-browser testing includes validating the responsiveness of web applications across different screen sizes and resolutions. Responsive design ensures that the application adapts and displays content optimally on various devices and orientations.
5. Functional Testing: In addition to visual consistency, cross-browser testing involves functional testing to verify that all features and functionalities of the web application work correctly across different browsers and devices. This includes testing user interactions, form submissions, navigation, and multimedia content.
6. Automation: Automation tools such as Selenium WebDriver, Test Complete, and Browser Stack automate cross-browser testing by executing test scripts across multiple browsers and environments. Automated cross-browser testing helps save time and effort by running tests in parallel and generating comprehensive test reports.

Q5
Test-Driven Development (TDD)
Test-Driven Development (TDD) is a software development process where tests are written before the actual code implementation.
The TDD cycle steps:
1. Write a Test: The developer writes a failing test case that describes a small piece of desired functionality. This test is written in anticipation of the code that will satisfy it.
2. Write the Code: The developer writes the minimal code necessary to pass the test. The goal is to write code that fulfils the requirements of the test without adding unnecessary complexity.
3. Run the Test: The developer runs the test suite to ensure that the newly written test fails. This step confirms that the test is indeed testing the desired behavior.
4. Refactor: Once the test fails, the developer refactors the code to improve its design and maintainability while keeping all tests passing. Refactoring ensures that the code remains clean, readable, and efficient.
5. Repeat: The developer repeats the process, writing more tests for additional functionality and implementing the code to pass those tests.

Behaviour-Driven Development (BDD)
Behaviour-Driven Development (BDD) is an extension of TDD that focuses on the behaviour of the system from the perspective of its stakeholders. BDD emphasizes collaboration between developers, testers, and business stakeholders to define and validate the behaviour of the software. The core principles of BDD include:

1. Ubiquitous Language: BDD promotes the use of a common, domain-specific language that is understood by all stakeholders involved in the development process. This language facilitates clear communication and shared understanding of requirements and expectations.
2. Specification by Example: BDD encourages the creation of executable specifications, often in the form of user stories or scenarios written in a human-readable format. These specifications serve as living documentation and executable tests that validate the behaviour of the system.
3. Three Amigos: BDD advocates for collaboration between three key roles in software development: developers, testers, and business analysts (or product owners). These roles, often referred to as the "Three Amigos," work together to define acceptance criteria, create executable specifications, and ensure that the software meets the needs of its users.
4. Given-When-Then: BDD scenarios follow a structured format known as "Given-When-Then." Each scenario consists of a context (Given), an action (When), and an expected outcome (Then). This format provides clarity and structure to the specifications and makes it easier to understand and validate the behaviour of the system.

Top comments (0)