Skip to content
pledbrook edited this page Sep 13, 2010 · 2 revisions

Page 26

  1. “Grails automatically created a shell unit-test case in /grails-app/test/unit/QuoteServiceTests.groovy” is wrong. Remove “/grails-app”
  2. “This will tell Grails to create a shell /grails-app/test/integration/QuoteService-IntegrationTests.groovy file.” Again remove “/grails-app”
  3. In Listing 1.17 class QuoteServiceTests extends GrailsUnitTestCase should be class QuoteServiceIntegrationTests extends GrailsUnitTestCase
  4. Listing 1.18 has same issue as Listing 1.17
  5. The test fails because of difference in case in “quiche” assertEquals("Real Programmers Don't eat Quiche", staticQuote.content) should be assertEquals("Real Programmers Don't eat quiche", staticQuote.content)

Page 27

  1. “Grails also generates an HTML version of our test results, which you can view by opening /grails-app/test/reports/html/index.html in a web browser.” Remove the “/grails-app”

Page 28

  1. In listing 1.22, render "... should be replaced by response.outputStream << ".... This is because the render() method applies the quote.gsp layout to the generated output, which isn’t what we want.