The coordinates function within the mock-jutsu library serves as a robust solution for developers requiring high-fidelity location-based test data. By generating precise latitude and longitude pairs, this feature allows teams to simulate geographic points across the globe without the need for manual data entry or the use of privacy-sensitive real-world information. Whether you are building a global logistics platform or a localised mobile application, mock-jutsu ensures your datasets are both realistic and syntactically correct for any spatial application.
Technically, the function outputs coordinate pairs formatted as comma-separated decimal degrees, such as 39.925533,32.866287. These values adhere to the World Geodetic System (WGS 84) standard, which is the foundational reference frame used by modern GPS technology and mapping APIs. By producing coordinates that span the full range of the Earth’s surface—from -90 to 90 degrees latitude and -180 to 180 degrees longitude—the mock-jutsu library provides a comprehensive toolset for stress-testing spatial queries, database indexing, and front-end map visualisations.
For QA engineers and backend developers, the versatility of mock-jutsu is a significant benefit. The library facilitates the generation of mock data across multiple environments, including a straightforward CLI command for quick prototyping, a native Python method for integrated unit testing, or a custom JMeter function for complex performance testing scenarios. This cross-platform flexibility means that whether you are automating a CI/CD pipeline or conducting heavy load tests on a geospatial database, the coordinates function provides consistent and reliable test data at scale.
Beyond simple data population, the ability to generate random coordinates is vital for testing edge cases in geofencing and proximity-based services. Developers can use these outputs to verify how an application handles requests from remote locations or to validate the performance of complex spatial join operations. By integrating mock-jutsu into your development workflow, you ensure that your software is prepared for the complexities of real-world geographic data, ultimately leading to more resilient and accurate location-aware features for your end users.
mockjutsu generate coordinates --locale TRmockjutsu generate coordinates --locale DEmockjutsu bulk coordinates --count 10 --locale TRmockjutsu export coordinates --count 10 --format json --locale TRmockjutsu export coordinates --count 10 --format csv --locale TRmockjutsu export coordinates --count 10 --format sql --locale TR# --mask: regulation-compliant output (PCI DSS / GDPR / KVKK)mockjutsu generate coordinates --locale TR --maskmockjutsu bulk coordinates --count 5 --locale TR --maskfrom mockjutsu import jutsujutsu.generate('coordinates', locale='TR')jutsu.bulk('coordinates', count=10, locale='TR')jutsu.template(['coordinates'], count=5, locale='TR')# mask=True: regulation-compliant outputjutsu.generate('coordinates', locale='TR', mask=True)jutsu.bulk('coordinates', count=5, locale='TR', mask=True)${__mockjutsu_location(coordinates,TR)}# JMeter Function: __mockjutsu_location# Parameter 1: coordinates# Parameter 2: locale (TR/UK/US/DE/FR/RU)${__mockjutsu_location(coordinates,DE)}# Add 'mask' keyword to get a regulation-compliant masked value${__mockjutsu_location(coordinates,TR,mask)}GET /generate/coordinates?locale=TR# → {"type":"coordinates","result":"...","status":"ok"}GET /bulk/coordinates?count=10&locale=TRPOST /template {"types":["coordinates"],"count":1,"locale":"TR"}# mask=true: regulation-compliant outputGET /generate/coordinates?locale=TR&mask=trueGET /bulk/coordinates?count=5&locale=TR&mask=true| 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…) |