🏠 Home
Benchmark Hub
📊 All Benchmarks 🦖 Dinosaur v1 🦖 Dinosaur v2 ✅ To-Do List Applications 🎨 Creative Free Pages 🎯 FSACB - Ultimate Showcase 🌍 Translation Benchmark
Models
🏆 Top 10 Models 🆓 Free Models 📋 All Models ⚙️ Kilo Code
Resources
💬 Prompts Library 📖 AI Glossary 🔗 Useful Links
← Back to categories
Beginner

Generate Pytest Unit Tests

#python #pytest #unit-testing

Create comprehensive unit tests for a Python class using the Pytest framework.

Write a set of unit tests using pytest for the following Python class: [Insert Class Code]. Ensure that you cover happy paths, edge cases, and potential error handling. Use fixtures where appropriate for setup and teardown.
Intermediate

React Component Jest Test

#react #javascript #jest #rtl

Generate a Jest and React Testing Library test suite for a specific React component.

Create a test suite for a React 'UserProfile' component that displays user name and avatar. Use Jest and React Testing Library. Test that the component renders correctly with props, handles a missing avatar gracefully, and triggers a callback when the 'Edit' button is clicked.
Advanced

Selenium E2E Test Script

#selenium #e2e #java #automation

Develop an end-to-end test script using Selenium WebDriver for a login workflow.

Write a Selenium WebDriver script in Java that automates the following end-to-end scenario: 1. Navigate to the login page. 2. Enter valid credentials. 3. Click the submit button. 4. Verify the user is redirected to the dashboard and the welcome message is present. Use explicit waits for element visibility.
Intermediate

JUnit 5 Test with Mockito

#java #junit5 #mockito #unit-testing

Write a JUnit 5 test for a service layer class using Mockito for dependency mocking.

Create a JUnit 5 test class for 'OrderService'. Mock the 'OrderRepository' dependency using Mockito. Verify that the 'createOrder' method saves the order and sends a confirmation email via the 'EmailService'. Include a test case for when the inventory check fails.
Beginner

Postman API Test Script

#api #postman #rest #integration

Create a collection of tests for a REST API using Postman's test scripting language.

Write JavaScript test code for a Postman request that hits a GET /users endpoint. The tests should verify that the status code is 200, the response time is less than 200ms, and the response body is an array containing objects with 'id' and 'username' properties.
Intermediate

Cypress Integration Test

#cypress #javascript #e2e #frontend

Develop a Cypress test for a shopping cart interaction on an e-commerce site.

Write a Cypress test that performs the following actions: 1. Visit the product page URL. 2. Select a size and color. 3. Click 'Add to Cart'. 4. Navigate to the Cart page. 5. Assert that the correct item, quantity, and total price are displayed.
Beginner

Cucumber Gherkin Scenarios

#bdd #gherkin #cucumber #acceptance-testing

Define Gherkin feature files for Behavior Driven Development (BDD) testing.

Write a Gherkin feature file for a 'Password Reset' functionality. Include scenarios for: 1. Successfully resetting a password with a valid token. 2. Attempting to reset with an expired token. 3. Attempting to reset with a new password that is too weak. Use Given, When, Then syntax.
Advanced

Load Testing with k6

#k6 #performance #load-testing #javascript

Design a load testing script using the k6 tool to stress test a web endpoint.

Create a k6 script that load tests a JSON API endpoint. Configure the script to simulate 50 virtual users (VUs) over a duration of 30 seconds. Include thresholds to ensure that 95% of requests must complete below 500ms and the error rate must not exceed 1%.
Intermediate

.NET Unit Testing with xUnit

#csharp #dotnet #xunit #moq

Generate unit tests for a C# .NET application using the xUnit framework.

Write xUnit tests for a C# class named 'Calculator' that implements basic arithmetic (Add, Subtract, Multiply, Divide). Use theories (InlineData) to test multiple input sets for the Add method. Ensure there is a test checking for DivideByZeroException.
Advanced

Visual Regression Testing Guide

#visual-regression #playwright #screenshot #ui-testing

Outline a strategy and code snippets for implementing visual regression testing.

Provide a strategy for implementing visual regression testing using Playwright. Include a code snippet demonstrating how to take a screenshot of a full page and compare it against a baseline. Explain how to handle dynamic content (like dates) to prevent false positives.
Intermediate

Unit Test Generation for Python

#python #unit testing #code generation

Generate comprehensive unit tests for a specific Python class using the unittest framework.

Write a complete set of unit tests for a Python class named 'Calculator' that has methods for add, subtract, multiply, and divide. Ensure that you include tests for handling division by zero and non-numeric inputs. Use the `unittest` module and include setup and teardown methods.
Beginner

User Acceptance Testing Checklist

#uat #qa #e-commerce #checklist

Create a detailed User Acceptance Testing (UAT) checklist for an e-commerce checkout flow.

Create a User Acceptance Testing checklist for a new guest checkout feature on an e-commerce website. The checklist should cover cart management, shipping address validation, payment gateway integration, and order confirmation emails. Organize it by test scenarios and expected results.
Intermediate

API Endpoint Test Cases

#api #rest #integration testing #json

Design test cases for a RESTful API endpoint including positive and negative scenarios.

Design a test suite for a RESTful API endpoint `GET /api/v1/users/{id}`. Include test cases for successful retrieval (200 OK), invalid ID format (400 Bad Request), user not found (404 Not Found), and unauthorized access (401 Unauthorized). Specify request headers and expected response body structures.
Advanced

SQL Data Integrity Verification

#sql #database testing #data integrity

Write SQL queries to verify data integrity and referential constraints in a database.

Write a set of SQL queries to perform data integrity checks on a database with `Orders` and `Customers` tables. The queries should identify orphan records (orders with no customer), duplicate customer email addresses, and orders with a negative total amount. Explain the purpose of each query.
Beginner

History Quiz Creation

#education #quiz #history #assessment

Generate a multiple-choice quiz for a high school history class covering a specific era.

Create a 10-question multiple-choice quiz about the Industrial Revolution for high school students. Each question should have 4 options (A, B, C, D), one correct answer, and a brief explanation of why that answer is correct. Include a mix of questions about inventions, key figures, and social impacts.