The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.


I've found the following errors, mostly in the second half of the book.

Figure 5.10 appears to show the test output of the code in listing 5.11, instead of the code in 5.10. The point is that both snippets should show the same output, but the strings to report the parameters are different in each, which is confusing.

Section 6.3.4 opens (pg 177) by comparing the behavior of mocks in listings 6.13 and 6.14. 6.14 is a java class; 6.3.4 should mention listings 6.15 and 6.16 instead.

(Nitpick) Line 8 of 6.16 is missing a closing parenthesis. This error is not on gitHub (where the statement is on lines 19 and 40).

The fullCheckout() method is not shown as part of the BillableBasket class in 6.14, even though section 6.4 explicitly says it is (pg 184). The method is present on gitHub.

The text after listing 6.22 (pg 183) says that the first argument of the sale() method should be the number (price) 1500, even though all code samples check for the correct sum of 1550.

6.25 and 6.26 (the last listings of chapter 6) contain font of two different weights, as though the original IDE colors were sent to print. While this is pleasant on the eyes, all other code uses the same font weight throughout.

(Nitpick) Irregular formatting (a missing space) in 6.11 ("suite.price+ 60") and 7.1 (".getStock() ==0").

(Nitpick) The first two letters of "samsung" are bolded for some reason in 7.5.

Section 8.1.5 references the use of an argument for @AutoCleanup in listing 8.11 (pg 235). This should refer to listing 8.14.
On a more content-concerned note, I'm not sure this code snippet is a good example of the annotation on its own, though, since it makes it unclear that @AutoCleanup will automatically call any close() method in the spec if there is no argument (I had to read the following paragraph a few times to get this. The next paragraph finally spells it out as an afterthought, but it's still confusing.)

(Nitpick) Typo in 8.19 -- "contact details are kept or record" should probably be "contact details are kept ON record". This is present on gitHub.