Skip to content

Instantly share code, notes, and snippets.

@darrylkuhn
Created May 1, 2017 15:59
Show Gist options
  • Save darrylkuhn/28b83432c5b89c3872baf9455c210061 to your computer and use it in GitHub Desktop.
Save darrylkuhn/28b83432c5b89c3872baf9455c210061 to your computer and use it in GitHub Desktop.
This small bash script allows newman users to run multiple newman commands and chain the results together. Requires newman 3.5.2 or later (I think)
#!/bin/sh
# Example run-folder.sh env.json collection.json "My Folder"
echo "Generating Temporary Environment"
newman run "${2}" --environment "${1}" --silent --export-env /tmp/temp-newman-env.json --folder "Fixtures"
newman run "${2}" --environment /tmp/temp-newman-env.json --bail --reporters cli --folder "${3}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment