Created
July 27, 2019 07:56
-
-
Save jasongorman/6364f8f77d12d904991efec30dc30f5f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
it('adds the received copies to the stock for that CD', function(){ | |
const cd = new CD(0, 10, new Description('Bat Out Of Hell', 'Meatloaf')); | |
const catalogue = new Catalogue(contents=[cd]); | |
const warehouse = new Warehouse(catalogue); | |
const batch = { | |
cds: [ | |
{ | |
title: 'Bat Out Of Hell', | |
artist: 'Meatloaf', | |
copies: 10 | |
} | |
] | |
} | |
warehouse.receive(batch); | |
assert.equal(cd.stock, 20); | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment