play console で model の動作などを確認したい場合


play.core.StaticApplication を new すると良い様です

参照:
https://groups.google.com/d/msg/play-framework/EFYnWC1yYsg/30TGLEQ-q68J

$ play console                                                                         
[info] Loading project definition from /private/tmp/todolist/project
[info] Set current project to todolist (in build file:/private/tmp/todolist/)
[info] Starting scala interpreter...
[info] 
Welcome to Scala version 2.9.1.final (Java HotSpot(TM) 64-Bit Server VM, Java 1.6.0_35).
Type in expressions to have them evaluated.
Type :help for more information.

scala> new play.core.StaticApplication(new java.io.File("."))
[info] play - database [default] connected at jdbc:postgresql://localhost:5432/todolist
[info] play - Application started (Prod)
res0: play.core.StaticApplication = play.core.StaticApplication@4cdd09a6

scala> models.Task.all()
res1: List[models.Task] = List(Task(1,Complete the tutorial))

scala>