Skip to content

Commit

Permalink
fix: update Postman translation mappings for response and request pro…
Browse files Browse the repository at this point in the history
…perties
  • Loading branch information
sanish-bruno committed Feb 12, 2025
1 parent 705b8b5 commit ba25983
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,14 @@ const replacements = {
'pm\\.expect\\.fail\\(': 'expect.fail(',
'pm\\.response\\.responseTime': 'res.getResponseTime()',
'pm\\.environment\\.name': 'bru.getEnvName()',
'pm\\.response\\.status': 'res.statusText()',
'pm\\.response\\.status': 'res.statusText',
'pm\\.response\\.headers': 'res.headers',
'pm\\.response\\.size': 'res.getSize()',
"tests\\['([^']+)'\\]\\s*=\\s*([^;]+);": 'test("$1", function() { expect(Boolean($2)).to.be.true; });',
'pm\\.request\\.url': 'bru.getUrl()',
'pm\\.request\\.method': 'req.getMethod()',
'pm\\.request\\.headers': 'req.getHeaders()',
'pm\\.request\\.body': 'req.getBody()',
// deprecated translations
'postman\\.setEnvironmentVariable\\(': 'bru.setEnvVar(',
'postman\\.getEnvironmentVariable\\(': 'bru.getEnvVar(',
Expand Down

0 comments on commit ba25983

Please sign in to comment.