Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No issue: Add a unit test for get measure display info #4014

Merged
merged 3 commits into from
Jul 4, 2022

Conversation

biaoli0
Copy link
Contributor

@biaoli0 biaoli0 commented Jul 4, 2022

Issue #:

Add a unit test to describe how dynamic coloured radius works.

@@ -185,6 +185,25 @@ describe('measures', () => {
const display3 = getMeasureDisplayInfo({ questionC: 0.5 }, [optionsSpectrum]);
expect(display3).toHaveProperty('color', 'hsl(50, 100%, 50%)');
});

it('Coloured radius choose a colour from a spectrum, and pick radius from radius', () => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test title is a little hard to understand. I suggest we call it something shorter like 'should support coloured radius' and if you want the longer description pop in in a comment inside the test case

@@ -104,27 +103,6 @@ const getNullValueMapping = type => {
return baseMapping;
};

function getFormattedValue(value, type, valueInfo, scaleType, valueType, submissionDate) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I love when code gets deleted, nice one!

@biaoli0 biaoli0 merged commit 4747215 into dev Jul 4, 2022
@biaoli0 biaoli0 deleted the add-a-unit-test-for-get-measure-display-info branch July 4, 2022 06:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants