Comment on page

Tests Cases

A test case evaluates whether a software application functions correctly under various conditions. Automating these test cases can minimize human error and save significant time. However, the process of creating automated test cases can be complex and costly. At SprintsQ, we've addressed these challenges effectively.
SprintsQ: Simplified Codeless Testing
SprintsQ enables test case creation without requiring knowledge of programming or testing frameworks, making it as straightforward as manual testing.
Key Features of SprintsQ Testing:
  • Pre-built Actions: SprintsQ offers an array of pre-built actions expressed in simple English, allowing for codeless creation of test cases. These actions serve as the building blocks for test cases, enabling interaction with web pages and UI elements without writing any code.
  • Data Handling: Easily capture and utilize necessary data for tests, including text and state information, within your test cases.
  • Framework: SprintsQ utilizes Playwright as its underlying testing framework, ensuring robust and reliable test execution.
The accompanying image illustrates a comparison between manual testing, SprintsQ testing, and traditional automated test cases.
Manual Test Case
Test Steps:
  1. 1.
    Open a web browser and navigate to https://www.saucedemo.com/.
  2. 2.
    Locate the username input field and enter a valid username (e.g., 'standard_user').
  3. 3.
    Locate the password input field and enter the corresponding valid password (e.g., 'secret_sauce').
  4. 4.
    Locate and click the login button.
Expected Result:
  • The user should be successfully logged in.
  • The user should be redirected to the home page or dashboard after login.
Automation Test Case
const { chromium } = require('playwright'); // import Playwright
(async () => {
// Launch browser
const browser = await chromium.launch();
const context = await browser.newContext();
const page = await context.newPage();
// Navigate to the website
await page.goto('https://www.saucedemo.com/');
// Input valid username
await page.fill('input[name="user-name"]', 'standard_user');
// Input corresponding password
await page.fill('input[name="password"]', 'secret_sauce');
// Click on the login button
await page.click('input[type="submit"]');
// Check if login was successful by looking for a logout element or user-specific element
try {
await page.waitForSelector('#inventory_container', { timeout: 5000 }); // Adjust the selector as needed
console.log('Login successful, test passed.');
} catch (error) {
console.log('Login failed, test did not pass.');
}
// Close browser
await browser.close();
})();
SprintsQ Test Case
SprintsQ Test case - As Simple as Manual testing
Creating a Test Case in SprintsQ:
  1. 1.
    Click on the "+Test Case" button.
  2. 2.
    Assign a name to your test case.
  3. 3.
    Begin by adding actions, starting with "Go to URL."
Note: Users must have 'test creation' permissions to create a test case.
Once a test case is crafted in SprintsQ, you have the flexibility to execute it directly in the cloud or on your local machine. (Refer to the section 'Running a Test Case on a Local Machine' for more details.)