Re: Problems with ResourceModel and StringResourceModel

2008-02-07 Thread Marco Aurélio Silva
I solved the problem with this code on the setUp method: List resourceLoaders = application.getResourceSettings ().getStringResourceLoaders(); List copy = new ArrayList(resourceLoaders); Collections.copy(copy,resourceLoaders); application.getResourceSettings().addStringResourceLoader(new

Problems with ResourceModel and StringResourceModel

2008-02-06 Thread Marco Aurélio Silva
Hi all I'm writing test cases for my wicket application (1.2.6), and I'm having problems with the ResourceModel and StringResourceModel. It seems like when loaded by a WicketTester (with startPage method) these components doesn't load the global resource file MyApplication.properties. If I put

Re: Problems with ResourceModel and StringResourceModel

2008-02-06 Thread Igor Vaynberg
you have to make wicket tester use _your_ application subclass -igor On Feb 6, 2008 8:50 AM, Marco Aurélio Silva [EMAIL PROTECTED] wrote: Hi all I'm writing test cases for my wicket application (1.2.6), and I'm having problems with the ResourceModel and StringResourceModel. It seems like

Re: Problems with ResourceModel and StringResourceModel

2008-02-06 Thread Marco Aurélio Silva
How to make it use my application subclass? WicketTester.set(Application application) trow this exception: wicket.WicketRuntimeException: Use Application.init() method for configuring your application object at wicket.Application.getSettings(Application.java:606) at

Re: Problems with ResourceModel and StringResourceModel

2008-02-06 Thread Igor Vaynberg
dont know about 1.2, but in 1.3 there is a constructor that takes an instance of application, so you would do new WicketTester(new MyApplication()); -igor On Feb 6, 2008 9:11 AM, Marco Aurélio Silva [EMAIL PROTECTED] wrote: How to make it use my application subclass?