Scale Slider Test Cases
Sr No. | Case Description | Data | Expected Output |
---|---|---|---|
1 | No items | items = '' | Message will display 'No data to display!' |
Bad items | items = [{ label: 'Poor' },..] | Slider will display but click functionality will not work without id. If label is there, label will display. | |
2 | items.length > 3 | items = [{ label: 'Poor', id: 1 }, { label: 'Good', id: 2 }] | Message will display 'Value is no sufficient. At least 3 values should be there!' |
3 | Good items | items = [{ id: 1, label: 'Poor' },..] | Slider section = length of items array. On change it gives the changed item object. |
4 | Wrong inputMdl | inputMdl = { label: 'poor' } | Without id, slider should not be select on page load |
5 | Good inputMdl | inputMdl = { id: 3, label: 'Good' } | As per id, slider will be selected on page load |
6 | Css property without !important | .cst-class{ margin-right : 10px } | Default margin will apply |
7 | Css property with !important | .cst-class{ margin-right : 10px !important; } | margin-right = 10px |
8 | If items object's property is not id and options.propId is not there | !options.propId or options.propId = '' | Slider will display but change functionality will not work |
9 | If items object's property is not id and options.propId is key value which is consider as id | items = [{ key:1, value:'poor' }] options.propId = 'key' | It will work properly |
10 | If items object's property is not label and options.propLabel is not there | !options.propLabel or options.propLabel = '' | Label will not display, scale will display from 1 to items.length |
11 | If items object's property is not label and options.propLabel is key value which is consider as label | items = [{ key:1, value:'poor' }] options.propLabel = 'value' | Label will display |
12 | disabled | extDisabled = true | Click functionality will not work |
13 | Screen size | Large | Disaply labels at bottom |
Small | If screen size is <= 480 px, Lables will not display only selected label will display |