diff --git a/tools/Mimante.Schermate/Program.cs b/tools/Mimante.Schermate/Program.cs index fe6e11d..1c481f2 100644 --- a/tools/Mimante.Schermate/Program.cs +++ b/tools/Mimante.Schermate/Program.cs @@ -224,6 +224,14 @@ else await Eval("[...document.querySelectorAll('.panel .tabs button')].find(b => b.textContent === 'Paletti e valore')?.click()"); // Le impostazioni vere e proprie, sotto la sezione dell'accesso a Bidoo. await Shot("05-impostazioni", "#/impostazioni", "document.querySelector('.access-section + .section')?.scrollIntoView()"); + // La sezione Telegram con «Prova gli avvisi» premuto (#35): senza token il bot risponde subito che mancano token e + // chat, con il messaggio al centro. Così si vedono i due bottoni e si prova il comando telegram.samples per intero. + const string telegramSection = "[...document.querySelectorAll('.section')].find(s => s.querySelector('h2')?.textContent === 'Telegram')"; + await Shot("16-impostazioni-telegram", "#/impostazioni", + $"{telegramSection}?.scrollIntoView(); [...({telegramSection}?.querySelectorAll('button') ?? [])].find(b => b.textContent === 'Prova gli avvisi')?.click()", 1500); + if ((await Eval("!!document.querySelector('.modal .notice')")).ValueKind != JsonValueKind.True) + errors.Add("Telegram: nessun messaggio dopo «Prova gli avvisi»"); + await Eval("document.querySelector('.modal footer .btn')?.click()"); await Shot("06-storico", "#/storico", clickFirst); await Shot("09-cerca", "#/cerca", null, 4000); await Shot("10-registro", "#/registro");