Liliana797979

dealer ship - js advanced exam

Oct 22nd, 2021
294
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. describe('dealership', () => {
  2.     it('return old car', () => {
  3.         assert.equal(dealership.newCarCost('a', 1), 1);
  4.         assert.equal(dealership.newCarCost('Audi A4 B8', 30000), 15000);
  5.     });
  6.  
  7.     it('car equipment', () => {
  8.         assert.deepEqual(dealership.carEquipment(['a', 'b', 'c'], [0, 2]), ['a', 'c']);
  9.     });
  10.  
  11.     it('euro category', () => {
  12.         assert.equal(dealership.euroCategory(3),
  13.             'Your euro category is low, so there is no discount from the final price!');
  14.     });
  15.     it('euro category1', () => {
  16.         assert.equal(dealership.euroCategory(4),
  17.             `We have added 5% discount to the final price: 14250.`);
  18.     });
  19.     it('euro category2', () => {
  20.         assert.equal(dealership.euroCategory(5),
  21.             `We have added 5% discount to the final price: 14250.`);
  22.     });
  23. });
  24.  
Advertisement
Add Comment
Please, Sign In to add comment