GrailsInAction / graina2

Source code for the 2nd edition of Grails in Action
90 stars 92 forks source link

MEAP v13 ch09 Geb Test uses wrong selector in TimelinePage.groovy #70

Open EdZilla opened 10 years ago

EdZilla commented 10 years ago

The timeline.gsp file specifies a class but the geb test in TimelinePage.groovy is looking for a div id, instead of a class reference.

In TimelinePage.groovy at closure should have $("div.allPosts") instead of $("#allPosts")

pledbrook commented 10 years ago

Right. I think it's a mistake that allPosts is a class rather than an ID, since the AJAX tags only work with IDs. @glenasmith what do you think? Should it be an ID or a class? I lean towards to the former.

EdZilla commented 10 years ago

my $.02 (or is that 'my 2 pence'?)... I tend to prefer using id, and make it a requirement in my group since, as you point out, AJAX tags work only with ID. ...and because it makes developing geb tests faster and easier. ;) Thanks for adding a good section on geb testing, btw.

Looking forward to completion to your MEAP (no pressure). I've already recommended it to some colleagues who want to learn grails.

Happy New Year guys!!