vehicleCommerceLocale Aware

Mock Jutsu HOW-TO | UK

The vehicle function within the mock-jutsu library provides developers with a robust solution for generating realistic automotive information. Whether you are building an e-commerce platform for car sales or an insurance premium calculator, having access to high-quality test data is essential for ensuring system reliability. By invoking this function, users receive a comprehensive data object containing key attributes such as the manufacturer (make), specific model, production year, and a unique Vehicle Identification Number (VIN). This ensures that your application logic is tested against data that mirrors real-world inventory, facilitating more accurate outcomes during the development phase.

To ensure maximum authenticity, mock-jutsu utilises industry-standard algorithms for its vehicle data generation. The VINs produced follow the ISO 3779 and ISO 3780 standards, incorporating correct check digits and world manufacturer identifiers. This level of detail is crucial for testing validation logic in backend systems that require structurally sound identifiers. By automating the creation of this mock data, engineers can bypass the tedious task of manual data entry while maintaining a high degree of variance across their datasets, preventing the common pitfalls of using repetitive or "stale" data during rigorous testing cycles.

This function is particularly beneficial for a wide range of testing scenarios, including load testing for fleet management systems and UI/UX prototyping for automotive marketplaces. Because mock-jutsu is designed for versatility, it can be seamlessly integrated into various workflows. Developers can generate a vehicle entry via the command-line interface for quick scripting, use the Python API for complex integration tests, or leverage the JMeter plugin to populate performance testing scripts with dynamic test data. This multi-platform flexibility allows teams to maintain a single source of truth for data generation across different stages of the software development lifecycle.

Beyond technical accuracy, the primary benefit of using the vehicle function is the significant reduction in development overhead. Instead of searching for public datasets or writing custom scripts to randomise car models, teams can rely on mock-jutsu to provide consistent, high-fidelity results instantly. This accelerates the feedback loop during sprint cycles and ensures that edge cases—such as older production years or specific VIN formats—are covered comprehensively. Ultimately, integrating this tool into your CI/CD pipeline enhances the reliability of commerce-driven applications, allowing you to ship automotive features with total confidence.

CLI Usage
mockjutsu generate vehicle --locale TRmockjutsu generate vehicle --locale DEmockjutsu bulk vehicle --count 10 --locale TRmockjutsu export vehicle --count 10 --format json --locale TRmockjutsu export vehicle --count 10 --format csv --locale TRmockjutsu export vehicle --count 10 --format sql --locale TR# --mask: regulation-compliant output (PCI DSS / GDPR / KVKK)mockjutsu generate vehicle --locale TR --maskmockjutsu bulk vehicle --count 5 --locale TR --mask
Python API
from mockjutsu import jutsujutsu.generate('vehicle', locale='TR')jutsu.bulk('vehicle', count=10, locale='TR')jutsu.template(['vehicle'], count=5, locale='TR')# mask=True: regulation-compliant outputjutsu.generate('vehicle', locale='TR', mask=True)jutsu.bulk('vehicle', count=5, locale='TR', mask=True)
JMeter
${__mockjutsu_commerce(vehicle,TR)}# JMeter Function: __mockjutsu_commerce# Parameter 1: vehicle# Parameter 2: locale (TR/UK/US/DE/FR/RU)${__mockjutsu_commerce(vehicle,DE)}# Add 'mask' keyword to get a regulation-compliant masked value${__mockjutsu_commerce(vehicle,TR,mask)}
REST API
GET /generate/vehicle?locale=TR# → {"type":"vehicle","result":"...","status":"ok"}GET /bulk/vehicle?count=10&locale=TRPOST /template {"types":["vehicle"],"count":1,"locale":"TR"}# mask=true: regulation-compliant outputGET /generate/vehicle?locale=TR&mask=trueGET /bulk/vehicle?count=5&locale=TR&mask=true

Parameters

Parameter Values Description
--locale TR|UK|US|DE|FR|RU Region / locale for locale-aware output
--mask true | false Return a regulation-compliant masked value (PCI DSS, GDPR, KVKK…)

Other Languages