UNPKG

@gatling.io/cli

Version:

Gatling JS is a JavaScript/TypeScript interface for the [Gatling load testing tool](https://gatling.io/).

23 lines (22 loc) 1.08 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const options_1 = require("./options"); const simulations_1 = require("../simulations"); const bundle_1 = require("../bundle"); exports.default = (program) => { program .command("build") .description("Build Gatling simulations") .addOption(options_1.sourcesFolderOption) .addOption(options_1.bundleFileOption) .addOption(options_1.postmanOption) .addOption(options_1.typescriptOption) .action(async (options) => { const sourcesFolder = (0, options_1.sourcesFolderOptionValue)(options); const bundleFile = (0, options_1.bundleFileOptionValue)(options); const simulations = await (0, simulations_1.findSimulations)(sourcesFolder); const postman = (0, options_1.postmanOptionValueWithDefaults)(options); const typescript = (0, options_1.typescriptOptionValueWithDefaults)(options, simulations); await (0, bundle_1.bundle)({ sourcesFolder, bundleFile, postman, typescript, simulations }); }); };