Skip to content

[Breakpoint] #5 Breakpoint Logic #222

@NghiaTranUIT

Description

@NghiaTranUIT

Description

⚠️ This ticket must be implemented after #221 is done.

Continue logic

  • Continue means: Ignore all changes from the BreakpointData and send the original Request/Response.
  • Continue button can work with multiple selections.
  • "Continue All" would perform the continue to all breakpoints.
  • When the breakpoint is continued -> Remove from the waiting Breakpoint List -> Auto Select the first breakpoint -> Make sure the Request/Response Editor is updated with a selected breakpoint

Abort

  • Abort means: Stopping the connection immediately.
  • Abort button can work with multiple selections.
  • "Abort All" would perform the continue to all breakpoints.
  • When the breakpoint is aborted -> Remove from the waiting Breakpoint List -> Auto Select the first breakpoint -> Make sure the Request/Response Editor is updated with a selected breakpoint

Execute

  • Execute means: Build a new Request or Response with a current BreakpointData.
  • Ping @NghiaTranUIT to get the Breakpoint class and BreakpointData class
  • Build the Request parts properly, including Method, URL, Header, Query, Body, Formed Body
  • Build the Response part properly, including Status Code, Headers, Body

How to test

Case 1: Request Breakpoint (Happy case)

  1. Make a POST httpbin.org request to Proxyman
  2. Right-Click -> Tools -> Breakpoint
  3. Select onRequest, and deselect the onResponse checkbox
  4. Create an entry
  5. Make a request again
  6. The Breakpoint Windows ([Breakpoint] #4 Request / Response Editor & Breakpoint View (UI Only) #221) appear -> There is 1 breakpoint in the list -> Auto-select the first breakpoint -> Update the Editor Part
  7. Make sure: The Request Editor is displayed, and the Response is hidden.
  8. Modify the Body and the Header
  9. Execute
  10. Back to Insomnia app -> Check the body and verify the Request is updated properly by the Breakpoint Tool

Case 2: Response Breakpoint (Happy case)

  1. Make a POST httpbin.org request to Proxyman
  2. Right-Click -> Tools -> Breakpoint
  3. Deselect the onRequest, and select the onResponse checkbox
  4. Create an entry
  5. Make a request again
  6. The Breakpoint Windows ([Breakpoint] #4 Request / Response Editor & Breakpoint View (UI Only) #221) appear -> There is 1 breakpoint in the list -> Auto-select the first breakpoint -> Update the Editor Part
  7. Make sure: The Request Editor is displayed and it's in Read-only Mode, and the Response is displayed.
  8. Modify the Body and the Header and status code
  9. Execute
  10. Back to the Insomnia app -> Check the body and verify the Request is updated properly by the Breakpoint Tool

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request✅ DoneTicket is resolved

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions