artilleryio / artillery

The complete load testing platform. Everything you need for production-grade load tests. Serverless & distributed. Load test with Playwright. Load test HTTP APIs, GraphQL, WebSocket, and more. Use any Node.js module.
https://www.artillery.io
Mozilla Public License 2.0
7.91k stars 505 forks source link

leading 0 in payload csv is missing #926

Open vichybaby opened 3 years ago

vichybaby commented 3 years ago

e.g. in payload.csv, data is like this:

CustomerID 001 002

in Scenario yml

config: payload: path: "payload.csv" fields:

  • "CustomerID" order: sequence skipHeader: true

Issue: When using the CustomerID, 001 becomes 1 and 002 becomes 2, the leading 0 is missing.

sibrahim-mc commented 3 years ago

@vichybaby, Artillery by defaults casts the fields into native types. Add cast: false in payload option to disable that behavior.

Have no idea about the iteration number though.