Skip to content

Instantly share code, notes, and snippets.

@jameshd
Created April 12, 2018 20:45
Show Gist options
  • Save jameshd/156df5933134e81720b04168a0cbbb93 to your computer and use it in GitHub Desktop.
Save jameshd/156df5933134e81720b04168a0cbbb93 to your computer and use it in GitHub Desktop.
const $ = cheerio.load(pm.response.text());
pm.test("it should return a propnumber", function(){
pm.expect($('proposalNumber').text()).to.not.be.empty;
});
pm.test("Status code is 200", function () {
pm.response.to.have.status(200);
});
pm.environment.set('__proposal_id', $('proposalNumber').text());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment