story-kit: merge 87_story_update_agent_lozenge_colour_scheme_across_panels
This commit is contained in:
@@ -88,16 +88,16 @@ describe("RosterBadge availability state", () => {
|
||||
expect(dot.style.animation).toBe("");
|
||||
});
|
||||
|
||||
it("shows green badge styling for an idle agent", async () => {
|
||||
it("shows grey badge styling for an idle agent", async () => {
|
||||
render(<AgentPanel />);
|
||||
|
||||
const badge = await screen.findByTestId("roster-badge-coder-1");
|
||||
// JSDOM normalizes #3fb95015 to rgba(63, 185, 80, 0.082) and #3fb950 to rgb(63, 185, 80)
|
||||
expect(badge.style.background).toBe("rgba(63, 185, 80, 0.082)");
|
||||
expect(badge.style.color).toBe("rgb(63, 185, 80)");
|
||||
// JSDOM normalizes #aaa18 to rgba(170, 170, 170, 0.094) and #aaa to rgb(170, 170, 170)
|
||||
expect(badge.style.background).toBe("rgba(170, 170, 170, 0.094)");
|
||||
expect(badge.style.color).toBe("rgb(170, 170, 170)");
|
||||
});
|
||||
|
||||
it("shows a blue pulsing dot for an active agent", async () => {
|
||||
it("shows a green pulsing dot for an active agent", async () => {
|
||||
const agentList: AgentInfo[] = [
|
||||
{
|
||||
story_id: "81_active",
|
||||
@@ -113,12 +113,12 @@ describe("RosterBadge availability state", () => {
|
||||
render(<AgentPanel />);
|
||||
|
||||
const dot = await screen.findByTestId("roster-dot-coder-1");
|
||||
// JSDOM normalizes #58a6ff to rgb(88, 166, 255)
|
||||
expect(dot.style.background).toBe("rgb(88, 166, 255)");
|
||||
// JSDOM normalizes #3fb950 to rgb(63, 185, 80)
|
||||
expect(dot.style.background).toBe("rgb(63, 185, 80)");
|
||||
expect(dot.style.animation).toBe("pulse 1.5s infinite");
|
||||
});
|
||||
|
||||
it("shows blue badge styling for an active agent", async () => {
|
||||
it("shows green badge styling for an active agent", async () => {
|
||||
const agentList: AgentInfo[] = [
|
||||
{
|
||||
story_id: "81_active",
|
||||
@@ -134,9 +134,8 @@ describe("RosterBadge availability state", () => {
|
||||
render(<AgentPanel />);
|
||||
|
||||
const badge = await screen.findByTestId("roster-badge-coder-1");
|
||||
// JSDOM normalizes #58a6ff18 to rgba(88, 166, 255, 0.094) and #58a6ff to rgb(88, 166, 255)
|
||||
expect(badge.style.background).toBe("rgba(88, 166, 255, 0.094)");
|
||||
expect(badge.style.color).toBe("rgb(88, 166, 255)");
|
||||
// JSDOM normalizes #3fb95018 to rgba(63, 185, 80, 0.094) and #3fb950 to rgb(63, 185, 80)
|
||||
expect(badge.style.background).toBe("rgba(63, 185, 80, 0.094)");
|
||||
expect(badge.style.color).toBe("rgb(63, 185, 80)");
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user