Alternating option for Unilateral exercises

This commit is contained in:
AG
2025-12-10 18:40:54 +02:00
parent 95a5e37748
commit 9243fec947
10 changed files with 59 additions and 8 deletions

View File

@@ -404,6 +404,26 @@ test.describe('III. Workout Tracking', () => {
// Verify Side and Metrics
await expect(page.getByText('Left', { exact: true })).toBeVisible();
await expect(page.getByText('20 kg x 10 reps')).toBeVisible();
// Log Right
await page.getByText('Right').first().click();
await page.getByLabel('Weight (kg)').fill('20');
await page.getByLabel('Reps').first().fill('10');
await page.getByRole('button', { name: /Log Set/i }).click();
await expect(page.getByText('Right', { exact: true })).toBeVisible();
// Log Alternately
if (await page.getByText('Alternately').count() > 0) {
await page.getByText('Alternately').first().click();
} else {
// Fallback for i18n or exact text match if needed
await page.getByRole('button', { name: /Alternately|Alt/i }).click();
}
await page.getByLabel('Weight (kg)').fill('20');
await page.getByLabel('Reps').first().fill('10');
await page.getByRole('button', { name: /Log Set/i }).click();
await expect(page.getByText(/Alternately|Alt/i).last()).toBeVisible();
});
test('3.15 C. Active Session - Log Special Type Set', async ({ page, createUniqueUser, request }) => {