`,
}
if strings.Join(rowTags, "\n") != strings.Join(wantRows, "\n") {
t.Errorf("%s: the rows are\n%s\nwant\n%s", where, strings.Join(rowTags, "\n"), strings.Join(wantRows, "\n"))
continue
}
for i, name := range []string{"Background", "Transition"} {
if !strings.Contains(rows[2*i], "
"+name+"") {
t.Errorf("%s: the %s row does not say %s:\n%s", where, name, name, rows[2*i])
}
}
if !strings.Contains(rows[1], `name="rst-slide-background"`) || !strings.Contains(rows[1], `name="rst-slide-background-color"`) {
t.Errorf("%s: the background popover does not hold the background field and its colour", where)
}
if !strings.Contains(rows[3], `name="rst-slide-transition"`) {
t.Errorf("%s: the transition popover does not hold the transition field", where)
}
}
}
// TestQuieterBlockCardIsStyle (spec §3.2, §4.3): with a box selected the
// card is that box's style. Its form holds no outlined pill (rst-btn),
// no Delete block and no standing hint; heading level is three radio
// segments named in words, size three named by the sizes; and the
// position fields are a closed
group, shown on a
// canvas slide alone, its summary the group's name.
func TestQuieterBlockCardIsStyle(t *testing.T) {
a := newApp(t)
cookies := signedIn(t, a, allowedAddress)
page := mustGet(t, a, deckWithSlides(t, a, cookies, 2), http.StatusOK, cookies).Body.String()
live := regexp.MustCompile(`(?s)`).ReplaceAllString(page, "")
card := extent(live, strings.Index(live, "