Changeset 2733

Show
Ignore:
Timestamp:
08/10/10 11:22:16 (1 year ago)
Author:
wouter
Message:

Upgrade to wicket version 1.4.9

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • his-extensions/plugins/trunk/correspondence/correspondence-letter/pom.xml

    r2686 r2733  
    9494            <version>${wicket.version}</version> 
    9595            <scope>provided</scope> 
    96  
    97             <exclusions> 
    98                 <exclusion> 
    99                     <groupId>org.slf4j</groupId> 
    100                     <artifactId>slf4j-api</artifactId> 
    101                 </exclusion> 
    102             </exclusions> 
    103         </dependency> 
    104  
    105         <dependency> 
    106             <groupId>org.apache.wicket</groupId> 
    107             <artifactId>wicket-spring-annot</artifactId> 
    108             <version>1.3.6</version> 
    109             <scope>provided</scope> 
    110             <optional>true</optional> 
    11196 
    11297            <exclusions> 
  • his-extensions/plugins/trunk/correspondence/correspondence-letter/src/test/java/org/joiningtracks/his/correspondence/letter/task/DefaultLetterTaskPanelTest.java

    r2682 r2733  
    9191        appctx.putBean("appointmentService", appointmentService); 
    9292 
    93         tester.getApplication().addComponentInstantiationListener(new SpringComponentInjector(tester.getApplication(), appctx)); 
     93        tester.getApplication().addComponentInstantiationListener(new SpringComponentInjector(tester.getApplication(), appctx, true)); 
    9494 
    9595        Authentication authentication = mock(Authentication.class); 
  • his-extensions/plugins/trunk/opinio/his-plugin/pom.xml

    r2268 r2733  
    8989            <version>${wicket.version}</version> 
    9090            <scope>provided</scope> 
    91  
    92             <exclusions> 
    93                 <exclusion> 
    94                     <groupId>org.slf4j</groupId> 
    95                     <artifactId>slf4j-api</artifactId> 
    96                 </exclusion> 
    97             </exclusions> 
    98         </dependency> 
    99  
    100         <dependency> 
    101             <groupId>org.apache.wicket</groupId> 
    102             <artifactId>wicket-spring-annot</artifactId> 
    103             <version>1.3.6</version> 
    104             <scope>provided</scope> 
    105             <optional>true</optional> 
    10691 
    10792            <exclusions> 
  • his-extensions/plugins/trunk/opinio/his-plugin/src/test/java/org/joiningtracks/his/plugin/integration/opinio/ui/AbstractQuestionnairePanelTest.java

    r1843 r2733  
    2424        appctx.putBean("questionnaireIntegrationService", questionnaireIntegrationService); 
    2525 
    26         tester.getApplication().addComponentInstantiationListener(new SpringComponentInjector(tester.getApplication(), appctx)); 
     26        tester.getApplication().addComponentInstantiationListener(new SpringComponentInjector(tester.getApplication(), appctx, true)); 
    2727    } 
    2828 
  • his-extensions/plugins/trunk/pom.xml

    r2732 r2733  
    3838    <properties> 
    3939        <his.version>1.9.13</his.version> 
    40         <wicket.version>1.4.1</wicket.version> 
     40        <wicket.version>1.4.9</wicket.version> 
    4141        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 
    4242        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> 
     
    464464            <dependency> 
    465465                <groupId>org.apache.wicket</groupId> 
    466                 <artifactId>wicket-spring-annot</artifactId> 
    467                 <version>1.3.6</version> 
    468             </dependency> 
    469             <dependency> 
    470                 <groupId>org.apache.wicket</groupId> 
    471466                <artifactId>wicket-datetime</artifactId> 
    472467                <version>${wicket.version}</version> 
  • his-extensions/plugins/trunk/treatment/importer/pom.xml

    r2709 r2733  
    8888            <version>${wicket.version}</version> 
    8989            <scope>provided</scope> 
    90  
    91             <exclusions> 
    92                 <exclusion> 
    93                     <groupId>org.slf4j</groupId> 
    94                     <artifactId>slf4j-api</artifactId> 
    95                 </exclusion> 
    96             </exclusions> 
    97         </dependency> 
    98  
    99         <dependency> 
    100             <groupId>org.apache.wicket</groupId> 
    101             <artifactId>wicket-spring-annot</artifactId> 
    102             <version>1.3.6</version> 
    103             <scope>provided</scope> 
    104             <optional>true</optional> 
    10590 
    10691            <exclusions> 
  • his-extensions/plugins/trunk/treatment/importer/src/test/java/org/joiningtracks/his/pathway/nok/treatment/forms/surgical/SurgicalDetailsUploadPanelTest.java

    r2709 r2733  
    2525        appctx.putBean("surgicalDetailsFileService",surgicalDetailsFileService); 
    2626 
    27         tester.getApplication().addComponentInstantiationListener(new SpringComponentInjector(tester.getApplication(), appctx)); 
     27        tester.getApplication().addComponentInstantiationListener(new SpringComponentInjector(tester.getApplication(), appctx, true)); 
    2828    } 
    2929 
  • his-extensions/plugins/trunk/treatment/treatment-base/pom.xml

    r2686 r2733  
    111111            <version>${wicket.version}</version> 
    112112            <scope>provided</scope> 
    113  
    114             <exclusions> 
    115                 <exclusion> 
    116                     <groupId>org.slf4j</groupId> 
    117                     <artifactId>slf4j-api</artifactId> 
    118                 </exclusion> 
    119             </exclusions> 
    120         </dependency> 
    121  
    122         <dependency> 
    123             <groupId>org.apache.wicket</groupId> 
    124             <artifactId>wicket-spring-annot</artifactId> 
    125             <version>1.3.6</version> 
    126             <scope>provided</scope> 
    127             <optional>true</optional> 
    128113 
    129114            <exclusions> 
  • his-extensions/plugins/trunk/treatment/treatment-base/src/test/java/org/joiningtracks/his/pathway/nok/treatment/forms/medication/MedicationFormTest.java

    r2714 r2733  
    7676        appctx.putBean("healthDocumentService", healthDocumentService); 
    7777 
    78         wicketTester.getApplication().addComponentInstantiationListener(new SpringComponentInjector(wicketTester.getApplication(), appctx)); 
     78        wicketTester.getApplication().addComponentInstantiationListener(new SpringComponentInjector(wicketTester.getApplication(), appctx, true)); 
    7979    } 
    8080 
  • his-extensions/plugins/trunk/treatment/treatment-base/src/test/java/org/joiningtracks/his/pathway/nok/treatment/forms/surgical/post/OperatieVerwerkingFormTest.java

    r2709 r2733  
    8383        //appctx.putBean("questionnaireIntegrationService", questionnaireIntegrationService); 
    8484 
    85         tester.getApplication().addComponentInstantiationListener(new SpringComponentInjector(tester.getApplication(), appctx)); 
     85        tester.getApplication().addComponentInstantiationListener(new SpringComponentInjector(tester.getApplication(), appctx, true)); 
    8686    } 
    8787 
  • his-extensions/plugins/trunk/treatment/treatment-base/src/test/java/org/joiningtracks/his/pathway/nok/treatment/xstream/converter/LdapEmployeeConverterTest.java

    r2507 r2733  
    1919import org.apache.wicket.spring.injection.annot.test.AnnotApplicationContextMock; 
    2020import static org.easymock.EasyMock.expect; 
     21 
     22import org.apache.wicket.util.tester.WicketTester; 
    2123import org.easymock.classextension.EasyMock; 
    2224import static org.easymock.classextension.EasyMock.replay; 
     
    3840    @Before 
    3941    public void setUp() { 
     42        WicketTester tester = new WicketTester(); 
     43 
    4044        mockApplicationContext = EasyMock.createMock(ApplicationContext.class); 
    4145        ldapEmployeeService = EasyMock.createMock(LdapEmployeeService.class); 
  • his/trunk/frontend/internal/src/main/java/org/joiningtracks/his/frontend/employee/WicketApplication.java

    r1471 r2733  
    2020import org.apache.wicket.application.IComponentInstantiationListener; 
    2121import org.apache.wicket.extensions.ajax.markup.html.form.upload.UploadWebRequest; 
     22import org.apache.wicket.injection.ConfigurableInjector; 
     23import org.apache.wicket.injection.web.InjectorHolder; 
    2224import org.apache.wicket.protocol.http.WebRequest; 
    2325import org.apache.wicket.security.hive.HiveMind; 
     
    6062    private String applicationVersion; 
    6163    private IComponentInstantiationListener componentInstantiationListener; 
     64    private ConfigurableInjector configurableInjector; 
    6265    private HisClassResolver osgiClassResolver; 
    6366 
     
    7174        super.init(); 
    7275 
     76        // Set given ConfigurableInjector. 
     77        InjectorHolder.setInjector(configurableInjector); 
    7378        // Make injection of spring beans in wicket-related classes possible using @SpringBean. 
    7479        addComponentInstantiationListener(componentInstantiationListener); 
     
    173178    } 
    174179 
     180    public void setConfigurableInjector(ConfigurableInjector configurableInjector) { 
     181        this.configurableInjector = configurableInjector; 
     182    } 
     183 
    175184    protected Object getHiveKey() { 
    176185        return "staticHiveKey"; 
  • his/trunk/frontend/internal/src/main/resources/context/applicationContext.xml

    r1318 r2733  
    2323        <property name="authenticationManager" ref="authenticationManager"/> 
    2424        <property name="componentInstantiationListener" ref="wicketInstantiationListener"/> 
     25        <property name="configurableInjector" ref="wicketComponentInjector"/> 
    2526        <property name="osgiClassResolver" ref="hisClassResolver"/> 
    2627    </bean> 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/AbstractHisWicketPanelTest.java

    r1808 r2733  
    11/* 
    2  * Copyright 2008-2009 Stichting JoiningTracks, The Netherlands 
     2 * Copyright 2008-2010 Stichting JoiningTracks, The Netherlands 
    33 * Licensed under the Apache License, Version 2.0 (the "License"); 
    44 * you may not use this file except in compliance with the License. 
     
    1616package org.joiningtracks.his.frontend.employee; 
    1717 
     18import org.apache.wicket.injection.web.InjectorHolder; 
    1819import org.apache.wicket.protocol.http.WebApplication; 
    1920import org.apache.wicket.spring.injection.annot.SpringComponentInjector; 
    20 import org.apache.wicket.spring.injection.annot.test.AnnotApplicationContextMock; 
    2121import org.junit.After; 
    2222 
    2323public abstract class AbstractHisWicketPanelTest extends AbstractWicketPanelTest { 
    2424 
    25     protected WebApplication initializeWebApplication(AnnotApplicationContextMock appctx){ 
    26         WicketApplication application = new WicketApplication(); 
     25    protected WebApplication createWebApplication() { 
    2726 
    28         application.setComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
    29         application.setOsgiClassResolver(new HisClassResolver()); 
     27        WicketApplication wicketApplication = new WicketApplication() { 
     28            @Override 
     29            protected void init() { 
     30                try { 
     31                    appctx = initializeAllServiceMocks(); 
     32                    setConfigurableInjector(InjectorHolder.getInjector()); 
     33                    setComponentInstantiationListener(new SpringComponentInjector(this, appctx, true)); 
     34                } catch (Exception e) { 
     35                    throw new RuntimeException(e); 
     36                } 
     37                super.init(); 
     38            } 
     39        }; 
    3040 
    31         return application; 
     41 
     42        wicketApplication.setOsgiClassResolver(new HisClassResolver()); 
     43 
     44        return wicketApplication; 
    3245    } 
    33      
     46 
    3447    @After 
    3548    public final void destroyActionFactory(){ 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/AbstractWicketPanelTest.java

    r2274 r2733  
    11/* 
    2  * Copyright 2008-2009 Stichting JoiningTracks, The Netherlands 
     2 * Copyright 2008-2010 Stichting JoiningTracks, The Netherlands 
    33 * Licensed under the Apache License, Version 2.0 (the "License"); 
    44 * you may not use this file except in compliance with the License. 
     
    1616package org.joiningtracks.his.frontend.employee; 
    1717 
     18import org.apache.wicket.injection.ConfigurableInjector; 
    1819import org.apache.wicket.protocol.http.WebApplication; 
    1920import org.apache.wicket.spring.injection.annot.test.AnnotApplicationContextMock; 
     
    2122import org.joiningtracks.his.data.model.LdapEmployee; 
    2223import org.joiningtracks.his.plugin.OsgiUtils; 
     24import org.joiningtracks.his.plugin.bridge.wicketsupport.ConfigurableInjectorBean; 
     25import org.joiningtracks.his.plugin.bridge.wicketsupport.MultiContextFieldValueFactory; 
    2326import org.joiningtracks.his.plugin.contract.ContractPropertyProvider; 
    2427import org.joiningtracks.his.service.ldap.LdapEmployeeService; 
     
    4952    @Before 
    5053    public final void setUp() throws Exception { 
    51         appctx = initializeAllServiceMocks(); 
    52         application = initializeWebApplication(appctx); 
    53  
     54        application = createWebApplication(); 
    5455        wicketTester = new WicketTester(application); 
    5556    } 
    56  
    57     private AnnotApplicationContextMock initializeAllServiceMocks() throws Exception { 
     57     
     58    protected AnnotApplicationContextMock initializeAllServiceMocks() throws Exception { 
    5859        AnnotApplicationContextMock appctx = new AnnotApplicationContextMock(); 
    5960        createServiceMocks(appctx, getServices("org/joiningtracks/his/service", ".*Service")); 
     
    6869    } 
    6970 
    70     protected abstract WebApplication initializeWebApplication(AnnotApplicationContextMock appctx); 
     71    protected abstract WebApplication createWebApplication(); 
    7172 
    7273    private void addBean(AnnotApplicationContextMock appctx, String beanName, Class beanClass){ 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/AllPanelsMarkupTest.java

    r1808 r2733  
    1717 
    1818import org.apache.wicket.markup.html.panel.Panel; 
     19import org.apache.wicket.util.tester.WicketTester; 
    1920import org.junit.Test; 
    2021import org.slf4j.Logger; 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/HomePageTest.java

    r1749 r2733  
    4949        appctx.putBean("frontpagePanelManager", WicketTestApplication.createMockFrontpagePanelManager()); 
    5050 
    51         application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
     51        application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx, true)); 
    5252 
    5353    } 
     
    8585        appctx.putBean("frontpagePanelManager", WicketTestApplication.createMockFrontpagePanelManager()); 
    8686 
    87         application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
     87        application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx, true)); 
    8888 
    8989 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/WicketTestApplication.java

    r1749 r2733  
    6363 
    6464        // Make injection of spring beans in wicket-related classes possible using @SpringBean. 
    65         addComponentInstantiationListener(new SpringComponentInjector(this, appctx)); 
     65        addComponentInstantiationListener(new SpringComponentInjector(this, appctx, true)); 
    6666 
    6767        ProviderManager authMan = new ProviderManager(); 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/contact/ContactPersonCreatePageTest.java

    r1749 r2733  
    7878        replay(medicalPositionService); 
    7979 
    80         application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
     80        application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx, true)); 
    8181    } 
    8282 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/contract/ContractDetailsPageTest.java

    r2284 r2733  
    6565        replay(osgiUtils); 
    6666 
    67         application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
     67        application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx, true)); 
    6868    } 
    6969 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/contract/ContractOverviewPageTest.java

    r1749 r2733  
    3737        replay(contractService); 
    3838 
    39         application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
     39        application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx, true)); 
    4040    } 
    4141 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/patient/PatientCreatePageTest.java

    r1749 r2733  
    9090        replay(contactPersonService); 
    9191 
    92         application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
     92        application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx, true)); 
    9393    } 
    9494 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/patient/SearchPatientPageTest.java

    r1749 r2733  
    5555        appctx.putBean("frontpagePanelManager", WicketTestApplication.createMockFrontpagePanelManager()); 
    5656 
    57         application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
     57        application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx, true)); 
    5858    } 
    5959 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/patient/details/PatientGroupListActionPanelTest.java

    r1471 r2733  
    5151 
    5252        // make sure the @SpringBean lookups work  
    53         application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
     53        application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx, true)); 
    5454    } 
    5555 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/patient/details/PatientGroupListDetailPanelTest.java

    r2670 r2733  
    5252        appctx.putBean("osgiUtils", osgiUtils); 
    5353        appctx.putBean("patientGroupService", patientGroupService); 
    54         application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
     54        application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx, true)); 
    5555    } 
    5656 
  • his/trunk/frontend/internal/src/test/java/org/joiningtracks/his/frontend/employee/patient/details/PatientTaskDetailPanelTest.java

    r2693 r2733  
    7070 
    7171 
    72         application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx)); 
     72        application.addComponentInstantiationListener(new SpringComponentInjector(application, appctx, true)); 
    7373 
    7474        _tasks = setupTasks(); 
  • his/trunk/frontend/pom.xml

    r2732 r2733  
    8484            <groupId>org.apache.wicket</groupId> 
    8585            <artifactId>wicket-spring</artifactId> 
    86             <scope>compile</scope> 
    87         </dependency> 
    88  
    89         <dependency> 
    90             <groupId>org.apache.wicket</groupId> 
    91             <artifactId>wicket-spring-annot</artifactId> 
    9286            <scope>compile</scope> 
    9387        </dependency> 
  • his/trunk/plugin/bridge/src/main/java/org/joiningtracks/his/plugin/bridge/wicketsupport/ConfigurableInjectorBean.java

    r1367 r2733  
    33import org.apache.wicket.injection.ConfigurableInjector; 
    44import org.apache.wicket.injection.IFieldValueFactory; 
    5 import org.apache.wicket.injection.web.InjectorHolder; 
    6 import org.springframework.beans.factory.InitializingBean; 
    75 
    86/** 
    9  * The Spring Bean version of the {@link ConfigurableInjector}. It registers itself as the injector for Wicket. 
     7 * The Spring Bean version of the {@link ConfigurableInjector}. 
    108 */ 
    11 public class ConfigurableInjectorBean extends ConfigurableInjector implements InitializingBean { 
    12  
     9public class ConfigurableInjectorBean extends ConfigurableInjector { 
    1310    private IFieldValueFactory fieldValueFactory; 
    1411 
     
    2017        this.fieldValueFactory = fieldValueFactory; 
    2118    } 
    22  
    23     public void afterPropertiesSet() { 
    24         InjectorHolder.setInjector(this); 
    25     } 
    2619} 
  • his/trunk/plugin/bridge/src/main/resources/context/osgiContainerContext.xml

    r2688 r2733  
    8989                        </list> 
    9090                    </property> 
    91                     <property name="postFix" value=";version=1.4.1"/> 
     91                    <property name="postFix" value=";version=1.4.9"/> 
    9292                </bean> 
    9393                <bean class="org.joiningtracks.his.plugin.packageresolvers.PrefixPackageResolver"> 
  • his/trunk/plugin/bridge/src/test/java/org/joiningtracks/his/plugin/bridge/wicketsupport/ConfigurableInjectorBeanTest.java

    r1178 r2733  
    22 
    33import static junit.framework.Assert.assertSame; 
     4 
     5import org.apache.wicket.Application; 
    46import org.apache.wicket.injection.NoopFieldValueFactory; 
    57import org.apache.wicket.injection.web.InjectorHolder; 
     8import org.apache.wicket.util.tester.WicketTester; 
    69import org.junit.Test; 
    710 
     
    1013    @Test 
    1114    public void testInjectorBeanRegistersItselfOnInitialization() { 
     15        WicketTester tester = new WicketTester(); 
     16 
    1217        ConfigurableInjectorBean testObject = new ConfigurableInjectorBean(); 
     18        InjectorHolder.setInjector(testObject); 
    1319 
    1420        final NoopFieldValueFactory fieldValueFactory = new NoopFieldValueFactory(); 
     
    1723        assertSame(fieldValueFactory, testObject.getFieldValueFactory()); 
    1824 
    19         testObject.afterPropertiesSet(); 
    20  
    2125        assertSame(testObject, InjectorHolder.getInjector()); 
    2226    } 
  • his/trunk/pom.xml

    r2732 r2733  
    3737 
    3838    <properties> 
    39         <wicket.version>1.4.1</wicket.version> 
     39        <wicket.version>1.4.9</wicket.version> 
    4040        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 
    4141        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> 
     
    484484            <dependency> 
    485485                <groupId>org.apache.wicket</groupId> 
    486                 <artifactId>wicket-spring-annot</artifactId> 
    487                 <version>1.3.6</version> 
    488             </dependency> 
    489             <dependency> 
    490                 <groupId>org.apache.wicket</groupId> 
    491486                <artifactId>wicket-datetime</artifactId> 
    492487                <version>${wicket.version}</version> 
  • his/trunk/questionnaire/frontend/pom.xml

    r2732 r2733  
    3333    <properties> 
    3434        <jetty.version>6.1.10</jetty.version> 
    35         <wicket.version>1.4.1</wicket.version> 
     35        <wicket.version>1.4.9</wicket.version> 
    3636    </properties> 
    3737 
     
    8585            <artifactId>wicket-spring</artifactId> 
    8686            <version>${wicket.version}</version> 
    87         </dependency> 
    88  
    89         <dependency> 
    90             <groupId>org.apache.wicket</groupId> 
    91             <artifactId>wicket-spring-annot</artifactId> 
    92             <version>1.3.6</version> 
    9387        </dependency> 
    9488