The composer says which language a post is in
A post went out in the reader's own interface language whatever it was written in. The composer now has a language picker (each language named in itself), starting at the persona's default from Settings, else the interface's; a reply starts in its thread's language. The e2e poll test picks Italian and finds it on PrivaPub. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LsXgEaXee4GCU1hwYgPJXw
This commit is contained in:
1 parent
d7d836ba39
commit
61631bb0a7
4 files changed
+29
-4
No files matched your search
@@ -6,7 +6,8 @@ using Microsoft.Playwright;
|
||||
|
||||
namespace decePubClient.E2E.Actions
|
||||
{
|
||||
// The composer beyond words: a poll, the persona's own post edited, and a quote, each checked on PrivaPub
|
||||
// The composer beyond words: a poll in a language picked, the persona's own post edited, and a quote, each checked on
|
||||
// PrivaPub
|
||||
public sealed class ComposerTests(Browser browser)
|
||||
{
|
||||
static async Task OpenHome(IPage page)
|
||||
@@ -39,12 +40,15 @@ namespace decePubClient.E2E.Actions
|
||||
var choices = page.Locator("[data-poll-editor] input[type=text]");
|
||||
await choices.Nth(0).FillAsync("tea");
|
||||
await choices.Nth(1).FillAsync("coffee");
|
||||
// and in the language picked
|
||||
await page.Locator("[data-compose-language]").First.SelectOptionAsync("it");
|
||||
await page.GetByRole(AriaRole.Button, new() { Name = "Post" }).Last.ClickAsync();
|
||||
JsonNode latest = null;
|
||||
Assert.True(await Pasture.Eventually(async () => (latest = await Latest(persona))?["content"]?.GetValue<string>().Contains(text) == true, 15),
|
||||
"the poll was never published");
|
||||
made = latest!["id"]!.GetValue<string>();
|
||||
Assert.Equal(new[] { "tea", "coffee" }, latest["poll"]!["options"]!.AsArray().Select(o => o!["title"]!.GetValue<string>()));
|
||||
Assert.Equal("it", latest["language"]?.GetValue<string>());
|
||||
await session.AssertGuards();
|
||||
}, page);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user