package slidestest import ( "bytes" "net/http" "regexp" "strings" "testing" "amadan.net/oficina/estilo.git/savestatus" ) // TestEditorUsesEstiloSaveStatus: the editor's save line is estilo's // savestatus — its markup with every state's words from this app's // catalog, its CSS and its module served as fingerprinted assets — and // the slide-load error keeps a line of its own, because savestatus has // no state for it. The editor's own [slides-status] is gone. func TestEditorUsesEstiloSaveStatus(t *testing.T) { a := newApp(t) cookies := signedIn(t, a, allowedAddress) path := sampleDeck(t, a, cookies) page := mustGet(t, a, path+"/edit", http.StatusOK, cookies).Body.String() for _, want := range []string{ `estilo-save-status="inline"`, `data-state="saved"`, `role="status"`, `data-text-saved="Saved"`, `data-text-saving="Saving…"`, `data-text-retrying="Offline, retrying"`, `data-text-failed="Some changes could not be saved. Reload to continue."`, `