()
| 21 | } |
| 22 | |
| 23 | func ExampleArgumentExtractor() { |
| 24 | req := makeExampleRequest("GET", "/", nil, url.Values{"token": {extractorTestTokenA}}) |
| 25 | tokenString, err := ArgumentExtractor{"token"}.ExtractToken(req) |
| 26 | if err == nil { |
| 27 | fmt.Println(tokenString) |
| 28 | } else { |
| 29 | fmt.Println(err) |
| 30 | } |
| 31 | // Output: A |
| 32 | } |
nothing calls this directly
no test coverage detected