()
| 684 | const LogHeaders = `testdata/log_header.lua` |
| 685 | |
| 686 | func ExampleLogHeaders() { |
| 687 | runExample(&testContext{ |
| 688 | script: LogHeaders, |
| 689 | params: []string{"request", "response"}, |
| 690 | // single header as iteration order is not defined |
| 691 | requestHeader: http.Header{"X-Foo": []string{"foo"}}, |
| 692 | responseHeader: http.Header{"X-Bar": []string{"bar", "baz"}}, |
| 693 | }) |
| 694 | // Output: |
| 695 | // GET http://www.example.com/foo/bar HTTP/1.1\r |
| 696 | // Host: www.example.com\r |
| 697 | // X-Foo: foo\r |
| 698 | // \r |
| 699 | // |
| 700 | // Response for GET http://www.example.com/foo/bar HTTP/1.1\r |
| 701 | // 200\r |
| 702 | // X-Bar: bar baz\r |
| 703 | // \r |
| 704 | } |
| 705 | |
| 706 | const LogRequestAuthHeader = `testdata/log_header.lua` |
| 707 |
nothing calls this directly
no test coverage detected
searching dependent graphs…