Skip to content

Commit 286fbd2

Browse files
committed
Update test file
1 parent 534a424 commit 286fbd2

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

exercises/practice/resistor-color-trio/resistor-color-trio.spec.js

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,36 @@ describe('Resistor Color Trio', () => {
3636
);
3737
});
3838

39+
xtest('Blue and violet and blue', () => {
40+
expect(new ResistorColorTrio(['blue', 'violet', 'blue']).label).toEqual(
41+
makeLabel({ value: 67, unit: 'megaohms' }),
42+
);
43+
});
44+
45+
xtest('Minimum possible value', () => {
46+
expect(new ResistorColorTrio(['black', 'black', 'black']).label).toEqual(
47+
makeLabel({ value: 0, unit: 'ohms' }),
48+
);
49+
});
50+
51+
xtest('Maximum possible value', () => {
52+
expect(new ResistorColorTrio(['white', 'white', 'white']).label).toEqual(
53+
makeLabel({ value: 99, unit: 'gigaohms' }),
54+
);
55+
});
56+
57+
xtest('First two colors make an invalid octal number', () => {
58+
expect(new ResistorColorTrio(['black', 'grey', 'black']).label).toEqual(
59+
makeLabel({ value: 8, unit: 'ohms' }),
60+
);
61+
});
62+
63+
xtest('Ignore extra colors', () => {
64+
expect(new ResistorColorTrio(['blue', 'green', 'yellow', 'orange']).label).toEqual(
65+
makeLabel({ value: 650, unit: 'kiloohms' }),
66+
);
67+
});
68+
3969
// optional: error
4070
xtest('Invalid color', () => {
4171
expect(

0 commit comments

Comments
 (0)