* Run clte before tecl. Dont test for tecl if clte already works! */
(path string, headers string)
| 80 | |
| 81 | /* Run clte before tecl. Dont test for tecl if clte already works! */ |
| 82 | func clte(path string, headers string) string { |
| 83 | httpMethod := "POST" |
| 84 | if Config.Website.Cache.CBisHTTPMethod { |
| 85 | httpMethod = Config.Website.Cache.CBName |
| 86 | } |
| 87 | payload := fmt.Sprintf(""+ |
| 88 | "%s %s HTTP/1.1\r\n"+ // POST /about HTTP/1.1 |
| 89 | "Host: %s\r\n"+ // Host: example.com |
| 90 | "%s"+ // *Additional Headers generated* |
| 91 | "Transfer-Encoding: chunked\r\n"+ // Transfer-Encoding: chunked |
| 92 | "Content-Length: 4\r\n"+ // Content-Length: 4 |
| 93 | "\r\n"+ // |
| 94 | "1\r\n"+ // 1 |
| 95 | "Z\r\n"+ // Z |
| 96 | "Q"+ // Q |
| 97 | "", httpMethod, path, Config.Website.Url.Host, headers) |
| 98 | |
| 99 | return payload |
| 100 | } |
| 101 | |
| 102 | func tecl(path string, headers string) string { |
| 103 | httpMethod := "POST" |
no outgoing calls
no test coverage detected