Expect a grammar-only layout error, a bare record spelling and a Swedish title table

This commit is contained in:
2026-09-18 20:01:05 +02:00
parent 6b0a2a60a8
commit 2d08bf4b32
3 changed files with 9 additions and 3 deletions
+1 -1
View File
@@ -553,7 +553,7 @@ func TestRecordTemplateRejectsATopLevelRepeat(t *testing.T) {
// error names the record that gives it one.
func TestRecordOfAFieldlessCategoryNamesTheWrapper(t *testing.T) {
f := newGenerator(t, "data", WithSeed(1))
want := `'{"format":"","personnummer":"{/sv_SE.personnummer}"}'`
want := `{"format":"","personnummer":"{/sv_SE.personnummer}"}`
_, err := f.FakeRecord("sv_SE.personnummer")
if err == nil || !strings.Contains(err.Error(), want) {
t.Fatalf("FakeRecord(sv_SE.personnummer) = %v, want it to name %s", err, want)