Add request filter for intercept

This commit is contained in:
David Stotijn
2022-03-15 19:32:29 +01:00
parent d051d48941
commit f4074a8060
18 changed files with 500 additions and 69 deletions

View File

@ -94,7 +94,7 @@ func TestParseQuery(t *testing.T) {
expectedExpression: InfixExpression{
Operator: TokOpRe,
Left: StringLiteral{Value: "foo"},
Right: regexp.MustCompile("bar"),
Right: RegexpLiteral{regexp.MustCompile("bar")},
},
expectedError: nil,
},
@ -104,7 +104,7 @@ func TestParseQuery(t *testing.T) {
expectedExpression: InfixExpression{
Operator: TokOpNotRe,
Left: StringLiteral{Value: "foo"},
Right: regexp.MustCompile("bar"),
Right: RegexpLiteral{regexp.MustCompile("bar")},
},
expectedError: nil,
},
@ -197,7 +197,7 @@ func TestParseQuery(t *testing.T) {
Right: InfixExpression{
Operator: TokOpRe,
Left: StringLiteral{Value: "baz"},
Right: regexp.MustCompile("yolo"),
Right: RegexpLiteral{regexp.MustCompile("yolo")},
},
},
expectedError: nil,