Commit Graph

261 Commits

Author SHA1 Message Date
lohit
4e4c94d73f sort folders by name first and then sequence (#5063)
* sort folders by name first and then sequence
---------

Co-authored-by: lohit <lohit@usebruno.com>
2025-07-14 22:17:11 +05:30
naman-bruno
a68833089f Feat: OAuth2 implicit grant type (#4307)
* add: implicit grant type
2025-07-11 13:55:03 +05:30
Pooja
fbc77fc725 feat: introduce res.getSize() helper (header/body/total) (#5018)
* feat: introduce `res.getSize()` helper (header/body/total)

* fix: unit test

* rm: request-duration from collection runner header

* change: api for getSize

* fix

* improve: getSize method

* add: todo comment

---------

Co-authored-by: lohit <lohit@usebruno.com>
2025-07-08 21:00:05 +05:30
Raino Pikkarainen
82f5f9ee88 Add dataBuffer to response to be available in test scripts (#1881)
Co-authored-by: Raino Pikkarainen <raino.pikkarainen@twoday.com>
2025-07-08 19:32:01 +05:30
Pooja
63a8201290 add: new timeline in runner (#4927)
* add: new timeline in runner
2025-07-08 15:26:21 +05:30
pooja-bruno
c96042c53f fix: testResult code 2025-07-04 15:39:29 +05:30
pooja-bruno
cab75f7543 improvements 2025-07-04 15:39:29 +05:30
pooja-bruno
587e3cfe5d add: script error card in collection runner 2025-07-04 15:39:29 +05:30
Pooja
c6c3931446 feat: support onFail api to catch errors in pre req (#4581)
support `onFail` api to catch errors in pre req

---------

Co-authored-by: Anoop M D <anoop.md1421@gmail.com>
Co-authored-by: lohit <lohit@usebruno.com>
2025-06-27 19:42:00 +05:30
lohit
6349e9b816 fix: oauth2 tokenHeaderPrefix can be set to an empty string value (#4928)
* ~ only prefill `Bearer` as token prefix only when the oauth2 is selected as the auth type for the first time
~ check if tokenPrefix is present before adding a space before the access_token value in the header

* review comment fixes

---------

Co-authored-by: lohit <lohit@usebruno.com>
2025-06-26 15:53:14 +05:30
Pragadesh-45
ef18805008 fix(electron): standardize quotes in qs.stringify for form-urlencoded data 2025-06-26 12:05:02 +05:45
Pragadesh-45
4664fd60b5 fix: update qs.stringify to use repeat array format for url serialization 2025-06-19 20:01:36 +05:45
naman-bruno
f2aedf780d Fix: showing test script errors (#4902)
* fix: catch errors in tests
2025-06-14 22:20:24 +05:30
Pooja
364fb45e97 add: pre and post tests in runner (#4878) 2025-06-11 22:38:58 +05:30
Pooja
fc697bf81b feat: support chai in scripts (#4552)
feat: support chai in scripts
2025-06-10 22:41:11 +05:30
lohit
9bc07afc77 initRunRequestEvent function for initializing request execution related details (#4863)
added a initRunRequestEvent function resetting and initializing request run event related details
2025-06-10 21:05:39 +05:30
lohit
9dde2df475 Merge pull request #4661 from devendra-bruno/fix/gql-introspection-variable-interpolation
Added combined Vars for prepareGqlIntrospectionRequest for all interp…
2025-06-05 18:05:45 +05:30
devendra-bruno
6f9daadcfb Update index.js Removed duplicate variable 2025-05-27 15:44:07 +05:30
devendra-bruno
8d5d952026 Added runtimeVars in prepareGqlIntrospectionRequest 2025-05-27 14:38:48 +05:30
devendra-bruno
afb2d3dffd Updated resolved variable assignment and testcases 2025-05-26 22:52:37 +05:30
devendra-bruno
91397eaf57 Renamed fetchGqlSchema to fetchGqlSchemaHandler 2025-05-26 16:38:09 +05:30
devendra-bruno
3e714ab9f8 Updated handler fetch-gql-schema 2025-05-21 17:54:53 +05:30
devendra-bruno
f2e9a6a502 Added folder level variable support 2025-05-21 17:39:10 +05:30
devendra-bruno
9c9afaf78f Extracted fetchGqlSchema handler seperate from ipc handler 2025-05-21 06:42:19 +05:30
lohit
2a44691cb3 Merge pull request #4590 from poojabela/feat/add-getName-api-for-script
feat: add `req.getName` & `bru.getCollectionName` api
2025-05-16 20:21:35 +05:30
devendra-bruno
5567e1b7f2 Fixed typo in prepareGqlIntrospectionRequest 2025-05-16 00:47:49 +05:30
devendra-bruno
0f318c26c2 Updated precedence in combinedVars object 2025-05-16 00:42:27 +05:30
devendra-bruno
62595c519c Added lodash merge for combining vars before interpolateVars 2025-05-15 15:56:30 +05:30
devendra-bruno
8e91640084 Added mergeEnvironmentVariables method for gql prep method 2025-05-14 12:25:41 +05:30
devendra-bruno
ad3f5de99a Added combined variable object for gqlIntrospectionRequest 2025-05-13 17:05:37 +05:30
lohit
38c307d6f1 feat: folder sequencing (#4595)
Co-authored-by: Pooja Belaramani <pooja@usebruno.com>
Co-authored-by: naman-bruno <naman@usebruno.com>
Co-authored-by: lohit <lohit@usebruno.com>
2025-05-05 16:52:00 +05:30
poojabela
e0fb379511 add: bru.collectionName api 2025-04-30 17:25:42 +05:30
lohit
220da6b58e feat: Moved logic related to html report generation to bruno-common package (#4536)
---------
Co-authored-by: lohit jiddimani <lohitjiddimani@lohits-MacBook-Air.local>
2025-04-22 16:35:54 +05:30
pooja-bruno
74bbfce8a0 fix: update global env in collection runner (#4135)
* fix: update global env in collection runner
2025-04-10 19:54:44 +05:30
Sanjai Kumar
2dd0424d8f Add @usebruno/requests package with digest authentication support (#4417)
* Add @usebruno/requests package with digest authentication support
---------

Co-authored-by: sanjai0py <sanjailucifer666@gmail.com>
Co-authored-by: ramki-bruno <ramki@usebruno.com>
2025-04-10 14:49:21 +05:30
lohit
2e5c63cfb9 improve network error handling, oauth2 logic cleanup, tls settings, and ui/test updates (#4444)
~ axios error interceptor fixes and timeline network logs ui updates
~ axios instance error interceptor now returns promise rejects instead of plain objects
~ fixed digest_auth regression
~ removed the interceptor logic for the oauth2 token url calls
~ timeline network logs ui updates
~ updated oauth2 test collections

* ssl/tls fixes and error handling
~ set the min allowed tls version to 1.0 (TLSv1)
~ proxy/certs/tls setup error handling

* enhance JSON stringification with circular reference handling
- Add getCircularReplacer to safely handle circular references in objects
- Update safeStringifyJSON to support indentation and handle undefined values
~ we currently support digest auth for bruno-cli

---------

Co-authored-by: lohit <lohit@usebruno.com>
Co-authored-by: Anoop M D <anoop.md1421@gmail.com>
2025-04-07 23:03:49 +05:30
sanjai0py
5dc7f1ae2f Refactoring and fixes in _Mock Variables Interpolation_ feature 2025-04-02 14:24:29 +05:30
Raghav Sethi
6862cb4e58 Feature: Mock Variables Interpolation (#3609)
Former title: Feature: adding dynamic variable support (#3609)
2025-04-02 14:24:29 +05:30
lohxt1
dbba22131c fix: proxy and certs not being used for oauth2 calls 2025-03-27 22:56:00 +05:30
naman-bruno
61b3853390 overwrite maxredirect on request obj 2025-03-25 18:01:40 +05:30
lohxt1
b09b4b1d17 timeline ui fixes, oauth2 validation fixes 2025-03-21 15:56:02 +05:30
lohxt1
5a98da2031 oauth2 fixes 2025-03-20 19:27:14 +05:30
lohxt1
eead96ca26 Merge remote-tracking branch 'upstream/main' into feat/oauth2-improvements 2025-03-16 14:02:12 +05:30
lohxt1
f99e8770f0 ~ reverting the bruno-electron ipc-network files refactoring work to keep the diff minimal 2025-03-16 13:37:59 +05:30
Pragadesh-45
6a85635c49 Fix: Inconsistent JSON parsing and formatting in res.body and Res-preview (#4103)
* Fix: Revert selective JSON parsing where string response is not parsed

- Revert "Merge pull request #3706 from Pragadesh-45/fix/response-format-updates"
  - e897dc1eb0
- Revert "Merge pull request #3676 from pooja-bruno/fix/string-json-response"
  - 1f2bee1f90

* Fix: Revert interpreting Assert RHS-value wrapped in quotes literally

- Revert "Merge pull request #3806 from Pragadesh-45/fix/handle-assert-results"
  - 63d3cb380d
- Revert "Merge pull request #3805 from Pragadesh-45/fix/handle-assert-results"
  - 6abd063749

* Fix: Inconsistent JSON formatting in preview when encoded value is a string

* Fix: Prettify JSON for Res-preview without parsing to avoid JS specific roundings

* Fix(testbench): req.body is always Buffer after the binary req body related changes

* Added `/api/echo/custom` where response can be configured using request itself

* Added tests for validating Assert and Response-preview

Co-authored-by: Pragadesh-45 <temporaryg7904@gmail.com>

* Handle char-encoding in Response-preview and added more tests

* Updated API endpoint in tests to use httpfaker api

* QuickJS (Safe Mode) exec logic to handle template literals similar to Developer Mode

* Safe Mode bru.runRequest to return statusText similar to Developer Mode

---------

Co-authored-by: ramki-bruno <ramki@usebruno.com>
Co-authored-by: Anoop M D <anoop.md1421@gmail.com>
2025-03-13 00:49:57 +05:30
pooja-bruno
0fbbe8a996 feat: show response errors while keeping response preview intact (#4082)
Co-authored-by: Anoop M D <anoop.md1421@gmail.com>
2025-03-10 19:51:48 +05:30
naman-bruno
3169e6cdf4 Oauth2 folder (#4105) 2025-03-06 11:03:34 +05:30
Sanjai Kumar
14d798eea7 Revert "fix: improve handling of Buffer responses and set default charset to utf-8"
This reverts commit d8a2e6f405.
2025-02-11 18:06:30 +05:30
Sanjai Kumar
8af285d41e Revert "refactor: enhance JSON parsing logic for Buffer responses"
This reverts commit 14e9227e07.
2025-02-11 18:06:30 +05:30
sanjai0py
14e9227e07 refactor: enhance JSON parsing logic for Buffer responses 2025-02-06 21:24:55 +05:30