Commit Graph

7 Commits

Author SHA1 Message Date
Ryan Willis
78a97f4bfb fix: prevent unparseable response cookie from causing request to fail [INS-4851] (#8289)
* fix: prevent unparseable response cookie from causing request to fail

* loosen cookie parsing
2025-01-14 10:46:12 -07:00
George He
58bea08bdb chore: return friendly message when sendRequest sees an error (#7911) 2024-09-06 03:18:20 +00:00
Jack Kavanagh
02f5bf4d4d inso cli scripting first pass (#7790)
* poc

* add header test

* fix lint

* fix types

* make require work

* low cost abstraction

* test insomnia.sendRequest

* remove execa

* split tests and improve docs

* dynamic import to fix build
2024-08-27 09:36:17 +00:00
Hexxa
be2426ae82 fix: clean up sdk types (#7721) 2024-07-16 10:50:36 +02:00
Hexxa
46b6ea811e feat: enable major features of the after-response script (#7411)
* feat: update data model and request-pane to support post-req-script

* fix: unit test failed

* feat: integrate post-request script to the engine - INS-3785,INS-3786 (#7329)

* feat: integrate post-request script to the engine

* refactor: some minor improvements

* fix: lint error

* chore: clean up typings

* refactor: separate transforming into sync and async parts

* use named args

* fix: renaming pre-req vars, functions and 2 minor fixes

* fix: the error message is updated

* feat: add snippets for post-request scripting (#7395)

* feat: enable extended assertion chains on `insomnia.response` (#7396)

* feat: add snippets for post-request scripting

* feat(sdk): support response.to.have assertion for verifying response

* chore: fix lint error

---------

Co-authored-by: jackkav <jackkav@gmail.com>

* test: add tests for post-request scripts and post-request scripts - INS-3786 (#7331)

* test: add some tests for post-req script and script engine

* fix: incorrect script type

* chore: refresh package-lock after merging

* chore: clean up package-lock.json

* fix: failed tests after rebasing

* feat: support importing post-req script from Postman (#7423)

* feat: support importing post-req script from Postman

* fix: introduce post-req script property for merged changes

* test: add a test case for importing scripts

* fix: add missing fixture

* chore: remove row after merging

* chore: rename to after-response-script

* fix test

* refresh lock

* update snapshot

* extract pre request logic to function

* refresh lock again

* throw on base env

* fix: revert the logic which rejects the case of unselected environment

---------

Co-authored-by: jackkav <jackkav@gmail.com>
2024-05-23 15:25:35 +08:00
Hexxa
03c74532c0 feat(hidden-win): try to simulate the existing behavior of handling async tasks (#7281) 2024-04-19 12:23:33 +02:00
Hexxa
2d9e2da52e chore(pre-req script): move all sdk files to sdk workspace - INS-3379 (#7255)
* feat: move script sdk to one workspace and update importing paths

* test: add jest config for enabling tests

* fix: failed to build package because of missing .node loader
2024-04-12 22:24:14 +08:00