Skip to content

Commit 569c7ff

Browse files
charlesh88shefalijoshidavetsay
authored
Expanded Time List enhancements for #8091 (#8095)
* Markup and CSS changes for expanded Activities in Time List - Significant markup and CSS changes. - Activities now use Plan colors. - Greatly improved narrow space and wrapping. - Added new global data uri's for status icons. - Added new global `gear-spinner` animation for in-progress Activity status icon. - Added new global `absCenter` mixin. - Revised and greatly simplified execution status and time context labels. - Revised, refined past/current/future styling and theme colors. - Status icon coloring added to theme constants. - Updated other themes constants for new approach to bg/fg/em. - Smoke tested in Espresso and Snow themes. * Remove unused imports * Remove unused and commented out code * Remove progress pie tests as that widget no longer exists * lint fix * remove tests for progress pie as it no longer exists --------- Co-authored-by: Shefali <[email protected]> Co-authored-by: David Tsay <[email protected]>
1 parent 5872b90 commit 569c7ff

13 files changed

+289
-446
lines changed

e2e/tests/functional/planning/timelistControlledClock.e2e.spec.js

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ const examplePlanSmall1 = JSON.parse(
5454
const TIME_TO_FROM_COLUMN = 2;
5555
const HEADER_ROW = 0;
5656
const NUM_COLUMNS = 5;
57-
const FULL_CIRCLE_PATH = 'M0,-50A50,50,0,1,1,0,50A50,50,0,1,1,0,-50Z';
5857

5958
/**
6059
* The regular expression used to parse the countdown string.
@@ -176,14 +175,6 @@ test.describe('Activity progress when activity is in the future @clock', () => {
176175
await page.clock.resume();
177176
await createTimelistWithPlanAndSetActivityInProgress(page, examplePlanSmall1);
178177
});
179-
180-
test('progress pie is empty', async ({ page }) => {
181-
const anActivity = page.getByRole('row').nth(0);
182-
// Progress pie shows no progress when now is less than the start time
183-
await expect(anActivity.getByLabel('Activity in progress').locator('path')).not.toHaveAttribute(
184-
'd'
185-
);
186-
});
187178
});
188179

189180
test.describe('Activity progress when now is between start and end of the activity @clock', () => {
@@ -193,13 +184,6 @@ test.describe('Activity progress when now is between start and end of the activi
193184
await page.goto('./', { waitUntil: 'domcontentloaded' });
194185
await createTimelistWithPlanAndSetActivityInProgress(page, examplePlanSmall1);
195186
});
196-
197-
test('progress pie is partially filled', async ({ page }) => {
198-
const anActivity = page.getByRole('row').nth(0);
199-
const pathElement = anActivity.getByLabel('Activity in progress').locator('path');
200-
// Progress pie shows progress when now is greater than the start time
201-
await expect(pathElement).toHaveAttribute('d');
202-
});
203187
});
204188

205189
test.describe('Activity progress when now is after end of the activity @clock', () => {
@@ -209,15 +193,6 @@ test.describe('Activity progress when now is after end of the activity @clock',
209193
await page.goto('./', { waitUntil: 'domcontentloaded' });
210194
await createTimelistWithPlanAndSetActivityInProgress(page, examplePlanSmall1);
211195
});
212-
213-
test('progress pie is full', async ({ page }) => {
214-
const anActivity = page.getByRole('row').nth(0);
215-
// Progress pie is completely full and doesn't update if now is greater than the end time
216-
await expect(anActivity.getByLabel('Activity in progress').locator('path')).toHaveAttribute(
217-
'd',
218-
FULL_CIRCLE_PATH
219-
);
220-
});
221196
});
222197

223198
/**

e2e/tests/visual-a11y/planning-timelist.visual.spec.js

Lines changed: 0 additions & 54 deletions
This file was deleted.

e2e/tests/visual-a11y/planning-view.visual.spec.js

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -27,37 +27,17 @@ import { createPlanFromJSON } from '../../appActions.js';
2727
import { scanForA11yViolations, test } from '../../avpFixtures.js';
2828
import { VISUAL_FIXED_URL } from '../../constants.js';
2929
import {
30-
createTimelistWithPlanAndSetActivityInProgress,
3130
getFirstActivity,
3231
setBoundsToSpanAllActivities,
3332
setDraftStatusForPlan
3433
} from '../../helper/planningUtils.js';
3534

36-
const examplePlanSmall1 = JSON.parse(
37-
fs.readFileSync(new URL('../../test-data/examplePlans/ExamplePlan_Small1.json', import.meta.url))
38-
);
39-
4035
const examplePlanSmall2 = JSON.parse(
4136
fs.readFileSync(new URL('../../test-data/examplePlans/ExamplePlan_Small2.json', import.meta.url))
4237
);
4338

44-
const FIRST_ACTIVITY_SMALL_1 = getFirstActivity(examplePlanSmall1);
4539
const FIRST_ACTIVITY_SMALL_2 = getFirstActivity(examplePlanSmall2);
4640

47-
test.describe('Visual - Timelist progress bar @clock @a11y', () => {
48-
test.beforeEach(async ({ page }) => {
49-
await page.clock.install({ time: FIRST_ACTIVITY_SMALL_1.end + 10000 });
50-
await page.clock.resume();
51-
await createTimelistWithPlanAndSetActivityInProgress(page, examplePlanSmall1);
52-
await page.getByLabel('Click to collapse items').click();
53-
});
54-
55-
test('progress pie is full', async ({ page, theme }) => {
56-
// Progress pie is completely full and doesn't update if now is greater than the end time
57-
await percySnapshot(page, `Time List with Activity in Progress (theme: ${theme})`);
58-
});
59-
});
60-
6141
test.describe('Visual - Plan View @a11y', () => {
6242
test.beforeEach(async ({ page }) => {
6343
// Set the clock to the end of the first activity in the plan

0 commit comments

Comments
 (0)