Answer stability round 1, prose round 1 and product-owner round 1: startOf's doc names the head, the old senses leave names, comments, messages and tests, and the vocabulary defines scope, link and head
This commit is contained in:
@@ -7,7 +7,7 @@ import (
|
||||
|
||||
func TestOneItemChoiceIsRejected(t *testing.T) {
|
||||
for _, src := range []string{`["x"]`, `[{"format":"{d}","d":"x"}]`, `{"format":"{w}","w":["only"]}`} {
|
||||
if _, err := linked(t, src); err == nil || !strings.Contains(err.Error(), "one-item choice") {
|
||||
if _, err := resolved(t, src); err == nil || !strings.Contains(err.Error(), "one-item choice") {
|
||||
t.Errorf("compile(%s) = %v, want the one-item choice rejected", src, err)
|
||||
}
|
||||
}
|
||||
@@ -20,11 +20,11 @@ func TestRepeatedChoiceItemIsRejected(t *testing.T) {
|
||||
`{"format":"{w}","w":["", "", "x"]}`: `{ "format": "", "weight": 2 }`,
|
||||
`{"format":"","w":[null,null,"a"]}`: "a null takes no weight",
|
||||
} {
|
||||
if _, err := linked(t, src); err == nil || !strings.Contains(err.Error(), want) {
|
||||
if _, err := resolved(t, src); err == nil || !strings.Contains(err.Error(), want) {
|
||||
t.Errorf("compile(%s) = %v, want an error naming %s", src, err, want)
|
||||
}
|
||||
}
|
||||
if _, err := linked(t, `[{"format":"a","weight":2}, "b"]`); err != nil {
|
||||
if _, err := resolved(t, `[{"format":"a","weight":2}, "b"]`); err != nil {
|
||||
t.Errorf("compile(weighted a, b) = %v", err)
|
||||
}
|
||||
}
|
||||
@@ -39,7 +39,7 @@ func TestInertObjectIsRejected(t *testing.T) {
|
||||
`{"format":"{x}","x":"v","repeat":2,"separator":""}`: "default",
|
||||
`{"format":"","n":{"format":"1","datatype":"string"}}`: `datatype "string" is the default`,
|
||||
} {
|
||||
if _, err := linked(t, src); err == nil || !strings.Contains(err.Error(), want) {
|
||||
if _, err := resolved(t, src); err == nil || !strings.Contains(err.Error(), want) {
|
||||
t.Errorf("compile(%s) = %v, want an error mentioning %s", src, err, want)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user