oficina / equipo Public

Clone
git clone https://amadan.net/oficina/equipo

Plain git — no account needed to clone.

Download

Download this file

1package equipotest
2
3import (
4 "net/http"
5 "net/url"
6 "testing"
7)
8
9func inspectPairing(t *testing.T, c *http.Client, base, code string) string {
10 t.Helper()
11 res := clientPost(t, c, base+"/runners/enrol", testOrigin, url.Values{"user_code": {code}, "action": {"inspect"}})
12 body := readBody(t, res)
13 if res.StatusCode != 200 {
14 t.Fatalf("inspect HTTP %d", res.StatusCode)
15 }
16 return body
17}
18