May 2019
Intermediate to advanced
496 pages
10h 38m
English
Both of our tests use the same two variables: container and customer. We can pull up these declarations to the outer describe scope, but leave the definitions within the tests. Since we'll be splitting declaration and definition, that also means we'll need to use let instead of const:
Just above the first test, write the following two lines:
let container;let customer;
Then, remove the word const from both of the tests, and re-run your tests, which should still be passing.
Read now
Unlock full access