circle-ci
9038 of 11357 relevant lines covered (79.58%)
104.42 hits per line
1 |
package driver
|
|
2 |
|
|
3 |
import (
|
|
4 |
"net/url"
|
|
5 |
|
|
6 |
"github.com/ory/kratos/schema"
|
|
7 |
) |
|
8 |
|
|
9 |
func (m *RegistryDefault) IdentityTraitsSchemas() schema.Schemas {
|
2,303✔ |
10 |
ms := m.c.IdentityTraitsSchemas() |
2,303✔ |
11 |
var ss schema.Schemas
|
2,303✔ |
12 |
|
2,303✔ |
13 |
for _, s := range ms { |
5,571✔ |
14 |
surl, err := url.Parse(s.URL) |
3,268✔ |
15 |
if err != nil { |
3,268✔ |
16 |
m.l.Fatalf("Could not parse url %s for schema %s", s.URL, s.ID)
|
× |
17 |
} |
× |
18 |
|
|
19 |
ss = append(ss, schema.Schema{
|
3,268✔ |
20 |
ID: s.ID, |
3,268✔ |
21 |
URL: surl, |
3,268✔ |
22 |
RawURL: s.URL, |
3,268✔ |
23 |
}) |
3,268✔ |
24 |
} |
|
25 |
|
|
26 |
return ss
|
2,303✔ |
27 |
} |