resistor-color-duo.test.ts 800 B

1234567891011121314151617181920212223242526272829303132
  1. import { decodedValue } from './resistor-color-duo'
  2. xit = it
  3. describe('Resistor Colors', () => {
  4. it('Brown and black', () => {
  5. expect(decodedValue(['brown', 'black'])).toEqual(10)
  6. })
  7. xit('Blue and grey', () => {
  8. expect(decodedValue(['blue', 'grey'])).toEqual(68)
  9. })
  10. xit('White and red', () => {
  11. expect(decodedValue(['white', 'red'])).toEqual(92)
  12. })
  13. xit('Yellow and violet', () => {
  14. expect(decodedValue(['yellow', 'violet'])).toEqual(47)
  15. })
  16. xit('Orange and orange', () => {
  17. expect(decodedValue(['orange', 'orange'])).toEqual(33)
  18. })
  19. xit('Ignore additional colors', () => {
  20. expect(decodedValue(['green', 'brown', 'orange'])).toEqual(51)
  21. })
  22. xit('Black and brown, one-digit', () => {
  23. expect(decodedValue(['black', 'brown'])).toEqual(1)
  24. })
  25. })