Changeset 28610

Show
Ignore:
Timestamp:
01/09/08 18:13:52 (7 months ago)
Author:
sfermigier
Message:

Cosmit, deal with deprecation.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-actions-core/src/test/java/org/nuxeo/ecm/platform/actions/TestActionFilter.java

    r28580 r28610  
    2020package org.nuxeo.ecm.platform.actions; 
    2121 
    22 import java.util.Map; 
    23  
    2422import org.nuxeo.ecm.core.api.DocumentModel; 
    2523import org.nuxeo.runtime.test.NXRuntimeTestCase; 
     
    3836    protected void setUp() throws Exception { 
    3937        super.setUp(); 
    40         deploy("test-actions-service.xml"); 
    41         deploy("test-filters-contrib.xml"); 
    42         deploy("test-filters-override-contrib.xml"); 
     38        deployContrib("test-actions-service.xml"); 
     39        deployContrib("test-filters-contrib.xml"); 
     40        deployContrib("test-filters-override-contrib.xml"); 
    4341        as = (ActionService) runtime.getComponent(ActionService.ID); 
    4442    } 
    4543 
    46     private boolean filterAccept(DocumentModel doc, ActionFilter filter) { 
     44    private static boolean filterAccept(DocumentModel doc, ActionFilter filter) { 
    4745        // XXX AT: action is not used anyway 
    4846        Action action = new Action(); 
     
    157155 
    158156        DefaultActionFilter dFilter = (DefaultActionFilter) filter; 
    159         assertEquals(dFilter.getRules().length, 2); 
     157        assertEquals(2, dFilter.getRules().length); 
    160158 
    161159        doc = new MockDocumentModel("Workspace", new String[0]); 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-audit-client/src/main/java/org/nuxeo/ecm/platform/audit/ws/WSAuditBean.java

    r28230 r28610  
    6969    } 
    7070 
    71     /* 
    72      * (non-Javadoc) 
    73      * 
    74      * @see org.nuxeo.ecm.platform.audit.ws.api.WSAudit#listModifiedDocuments(java.lang.String, 
    75      *      java.lang.String) 
    76      */ 
    7771    @WebMethod 
    7872    public ModifiedDocumentDescriptor[] listModifiedDocuments(String sessionId, 
     
    8276            initSession(sessionId); 
    8377        } catch (ClientException ce) { 
    84             throw new AuditException(ce.getMessage()); 
     78            throw new AuditException(ce.getMessage(), ce); 
    8579        } 
    8680 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-audit-facade/src/main/java/org/nuxeo/ecm/platform/audit/ejb/LogsBean.java

    r28476 r28610  
    244244    @SuppressWarnings("unchecked") 
    245245    public LogEntry getLogEntryByID(long id) throws AuditException { 
     246        log.debug("getLogEntriesFor() logID=" + id); 
     247        Class<LogEntry> klass = getLogEntryClass(); 
    246248        LogEntryBase match = null; 
    247         log.debug("getLogEntriesFor() logID=" + id); 
    248         Class<LogEntry> klass = getLogEntryClass(); 
    249249        try { 
    250250            Query query = em.createQuery("from " + klass.getSimpleName() 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-audit-facade/src/test/java/org/nuxeo/ecm/platform/audit/facade/TestLogEntryFactory.java

    r19481 r28610  
    4040    public void setUp() throws Exception { 
    4141        super.setUp(); 
    42         deploy("nxaudit-service-definitions.xml"); 
    43         deploy("nxaudit-service-contrib.xml"); 
     42        deployContrib("nxaudit-service-definitions.xml"); 
     43        deployContrib("nxaudit-service-contrib.xml"); 
    4444 
    45         aes = (NXAuditEventsService) runtime 
    46                 .getComponent(NXAuditEventsService.NAME); 
     45        aes = (NXAuditEventsService) runtime.getComponent(NXAuditEventsService.NAME); 
    4746    } 
    4847 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-audit-search/src/test/java/org/nuxeo/ecm/platform/audit/search/TestAuditIndexableResource.java

    r28583 r28610  
    4343        super.setUp(); 
    4444 
    45         deploy("nxsearch-test-framework.xml"); 
    46         deploy("nxsearch-test-contrib.xml"); 
    47         deploy("test-nxsearch-backend-compass-framework.xml"); 
    48         deploy("nxsearch-compass-test-contrib.xml"); 
     45        deployContrib("nxsearch-test-framework.xml"); 
     46        deployContrib("nxsearch-test-contrib.xml"); 
     47        deployContrib("test-nxsearch-backend-compass-framework.xml"); 
     48        deployContrib("nxsearch-compass-test-contrib.xml"); 
    4949 
    5050        // Local lookup is enough 
    5151        service = Framework.getLocalService(SearchService.class); 
    5252        assertNotNull(service); 
    53  
    5453    } 
    5554 
    5655    public void testAuditResourceConfRegistration() { 
    57  
    5856        IndexableResourceConf conf = service.getIndexableResourceConfByName("audit", false); 
    5957        assertNotNull(conf); 
     
    7270        IndexableResourceFactory factory = desc.getFactory(); 
    7371        assertTrue(factory.createEmptyIndexableResource() instanceof AuditIndexableResourceImpl); 
    74  
    7572    } 
    7673 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-cache-jboss/src/main/java/org/nuxeo/ecm/platform/cache/CacheServiceException.java

    r20672 r28610  
    3131 
    3232    public CacheServiceException() { 
    33         super(); 
    34         // TODO Auto-generated constructor stub 
    3533    } 
    3634 
    3735    public CacheServiceException(String arg0, Throwable arg1) { 
    3836        super(arg0, arg1); 
    39         // TODO Auto-generated constructor stub 
    4037    } 
    4138 
    4239    public CacheServiceException(String arg0) { 
    4340        super(arg0); 
    44         // TODO Auto-generated constructor stub 
    4541    } 
    4642 
    4743    public CacheServiceException(Throwable arg0) { 
    4844        super(arg0); 
    49         // TODO Auto-generated constructor stub 
    5045    } 
    5146 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-content-template-manager/src/test/java/org/nuxeo/ecm/platform/content/template/tests/TestContentTemplateFactory.java

    r28583 r28610  
    4747        super.setUp(); 
    4848 
    49         deploy("ServiceManagement.xml"); 
    50         deploy("LoginComponent.xml"); 
    51         deploy("RepositoryManager.xml"); 
    52         deploy("RepositoryService.xml"); 
    53         deploy("CoreTestExtensions.xml"); 
    54         deploy("CoreEventListenerService.xml"); 
    55         deploy("DemoRepository.xml"); 
    56         deploy("LifeCycleService.xml"); 
    57         deploy("LifeCycleServiceExtensions.xml"); 
    58         deploy("CoreEventListenerService.xml"); 
    59         deploy("PlatformService.xml"); 
    60         deploy("DefaultPlatform.xml"); 
    61  
    62         deploy("test-content-template-framework.xml"); 
    63         deploy("test-content-template-contrib.xml"); 
    64         deploy("test-content-template-listener.xml"); 
     49        deployContrib("ServiceManagement.xml"); 
     50        deployContrib("LoginComponent.xml"); 
     51        deployContrib("RepositoryManager.xml"); 
     52        deployContrib("RepositoryService.xml"); 
     53        deployContrib("CoreTestExtensions.xml"); 
     54        deployContrib("CoreEventListenerService.xml"); 
     55        deployContrib("DemoRepository.xml"); 
     56        deployContrib("LifeCycleService.xml"); 
     57        deployContrib("LifeCycleServiceExtensions.xml"); 
     58        deployContrib("CoreEventListenerService.xml"); 
     59        deployContrib("PlatformService.xml"); 
     60        deployContrib("DefaultPlatform.xml"); 
     61 
     62        deployContrib("test-content-template-framework.xml"); 
     63        deployContrib("test-content-template-contrib.xml"); 
     64        deployContrib("test-content-template-listener.xml"); 
    6565 
    6666 
     
    7070        session = mgr.getDefaultRepository().open(); 
    7171        assertNotNull(session); 
    72  
    73     } 
    74  
    75     private ContentTemplateService getService() { 
    7672        service = Framework.getLocalService(ContentTemplateService.class); 
    77         return service; 
    78     } 
    79  
    80     public void testServiceRegistration() { 
    81         getService(); 
    8273        assertNotNull(service); 
    8374    } 
    8475 
    8576    public void testServiceFactoryContribs() { 
    86         getService(); 
    87         ContentTemplateServiceImpl serviceImpl = (ContentTemplateServiceImpl) service; 
    88         assertNotNull(serviceImpl); 
    89         Map<String, ContentFactoryDescriptor> factories = serviceImpl 
    90                 .getFactories(); 
     77        ContentTemplateServiceImpl serviceImpl = (ContentTemplateServiceImpl) service; 
     78        assertNotNull(serviceImpl); 
     79        Map<String, ContentFactoryDescriptor> factories = serviceImpl.getFactories(); 
    9180        assertTrue(factories.containsKey("SimpleTemplateFactory")); 
    9281        assertTrue(factories.containsKey("ImportFactory")); 
     
    9584 
    9685    public void testServiceFactoryBindingContribs() { 
    97         getService(); 
    98         ContentTemplateServiceImpl serviceImpl = (ContentTemplateServiceImpl) service; 
    99         assertNotNull(serviceImpl); 
    100         Map<String, FactoryBindingDescriptor> factoryBindings = serviceImpl 
    101                 .getFactoryBindings(); 
     86        ContentTemplateServiceImpl serviceImpl = (ContentTemplateServiceImpl) service; 
     87        assertNotNull(serviceImpl); 
     88        Map<String, FactoryBindingDescriptor> factoryBindings = serviceImpl.getFactoryBindings(); 
    10289        assertEquals(3, factoryBindings.size()); 
    10390        assertTrue(factoryBindings.containsKey("Root")); 
     
    11097 
    11198    public void testServiceFactoryForSecurity() { 
    112         getService(); 
    113         ContentTemplateServiceImpl serviceImpl = (ContentTemplateServiceImpl) service; 
    114         assertNotNull(serviceImpl); 
    115         Map<String, FactoryBindingDescriptor> factoryBindings = serviceImpl 
    116                 .getFactoryBindings(); 
     99        ContentTemplateServiceImpl serviceImpl = (ContentTemplateServiceImpl) service; 
     100        assertNotNull(serviceImpl); 
     101        Map<String, FactoryBindingDescriptor> factoryBindings = serviceImpl.getFactoryBindings(); 
    117102 
    118103        FactoryBindingDescriptor wsFactory = factoryBindings.get("Workspace"); 
     
    125110 
    126111    public void testServiceFactoryInstancesContribs() { 
    127         getService(); 
    128         ContentTemplateServiceImpl serviceImpl = (ContentTemplateServiceImpl) service; 
    129         assertNotNull(serviceImpl); 
    130         Map<String, ContentFactory> factoryInstances = serviceImpl 
    131                 .getFactoryInstancesByType(); 
     112        ContentTemplateServiceImpl serviceImpl = (ContentTemplateServiceImpl) service; 
     113        assertNotNull(serviceImpl); 
     114        Map<String, ContentFactory> factoryInstances = serviceImpl.getFactoryInstancesByType(); 
    132115        assertEquals(3, factoryInstances.size()); 
    133116        assertTrue(factoryInstances.containsKey("Root")); 
     
    136119 
    137120    public void testRootFactory() throws ClientException { 
    138         getService(); 
    139121        // Fake repo init for now 
    140122        DocumentModel root = session.getRootDocument(); 
     
    175157 
    176158    public void testWSFactory() throws ClientException { 
    177  
    178         getService(); 
    179  
    180159        // reach first available WSRoot 
    181160        DocumentModel root = session.getRootDocument(); 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-content-template-manager/src/test/resources/CoreEventListenerService.xml

    r23426 r28610  
    33<component name="org.nuxeo.ecm.core.listener.CoreEventListenerService"> 
    44 
    5        <require>org.nuxeo.ecm.core.repository.RepositoryService</require> 
     5  <require>org.nuxeo.ecm.core.repository.RepositoryService</require> 
    66 
    7         <implementation class="org.nuxeo.ecm.core.listener.impl.CoreEventListenerServiceImpl"/> 
     7  <implementation 
     8      class="org.nuxeo.ecm.core.listener.impl.CoreEventListenerServiceImpl"/> 
    89 
    9         <extension-point name="listener"> 
    10                 <object class="org.nuxeo.ecm.core.listener.extensions.CoreEventListenerDescriptor"/> 
    11         </extension-point> 
    12  
    13           <extension target="org.nuxeo.ecm.core.listener.CoreEventListenerService" 
    14                            point="listener"> 
    15                 <listener name="lifecyclelistener" 
    16                                                   class="org.nuxeo.ecm.core.lifecycle.impl.LifeCycleListener" 
    17                                                   /> 
    18       </extension> 
     10  <extension-point name="listener"> 
     11    <object 
     12        class="org.nuxeo.ecm.core.listener.extensions.CoreEventListenerDescriptor"/> 
     13  </extension-point> 
    1914 
    2015</component> 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-directory-api/src/main/java/org/nuxeo/ecm/directory/DirectoryException.java

    r28478 r28610  
    3434    } 
    3535 
    36     /** 
    37      * @see Exception#Exception(String, Throwable) 
    38      */ 
    3936    public DirectoryException(String message, Throwable th) { 
    4037        super(message, th); 
    4138    } 
    4239 
    43     /** 
    44      * @see Exception#Exception(String) 
    45      */ 
    4640    public DirectoryException(String message) { 
    4741        super(message); 
    4842    } 
    4943 
    50     /** 
    51      * @see Exception#Exception(Throwable) 
    52      */ 
    5344    public DirectoryException(Throwable th) { 
    5445        super(th); 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-directory-facade/src/main/java/org/nuxeo/ecm/platform/directory/ejb/DirectoryManagerBean.java

    r28583 r28610  
    5555    private static final Log log = LogFactory.getLog(DirectoryManagerBean.class); 
    5656 
    57     private final EJBExceptionHandler exceptionHandler = new EJBExceptionHandler(); 
     57    private static final Map<Long, Session> sessionMap = new HashMap<Long, Session>(); 
    5858 
    5959    private transient DirectoryService directoryService; 
    60  
    61     private static Map<Long, Session> sessionMap = new HashMap<Long, Session>(); 
    6260 
    6361    private long sessionIdCounter = 0L; 
     
    107105            return getSession(sessionId).authenticate(username, password); 
    108106        } catch (Throwable e) { 
    109             throw exceptionHandler.wrapException(e); 
     107            throw EJBExceptionHandler.wrapException(e); 
    110108        } 
    111109    } 
     
    116114            sessionMap.remove(sessionId); 
    117115        } catch (Throwable e) { 
    118             throw exceptionHandler.wrapException(e); 
     116            throw EJBExceptionHandler.wrapException(e); 
    119117        } 
    120118    } 
     
    124122            getSession(sessionId).commit(); 
    125123        } catch (Throwable e) { 
    126             throw exceptionHandler.wrapException(e); 
     124            throw EJBExceptionHandler.wrapException(e); 
    127125        } 
    128126    } 
     
    133131            return getSession(sessionId).createEntry(map); 
    134132        } catch (Throwable e) { 
    135             throw exceptionHandler.wrapException(e); 
     133            throw EJBExceptionHandler.wrapException(e); 
    136134        } 
    137135    } 
     
    142140            getSession(sessionId).deleteEntry(docModel); 
    143141        } catch (Throwable e) { 
    144             throw exceptionHandler.wrapException(e); 
    145         } 
    146     } 
    147  
    148     public void deleteEntry(long sessionId, String id) throws DirectoryException, 
     142            throw EJBExceptionHandler.wrapException(e); 
     143        } 
     144    } 
     145 
     146    public void deleteEntry(long sessionId, String id) throws 
    149147            DirectoryException { 
    150148        try { 
    151149            getSession(sessionId).deleteEntry(id); 
    152150        } catch (Throwable e) { 
    153             throw exceptionHandler.wrapException(e); 
     151            throw EJBExceptionHandler.wrapException(e); 
    154152        } 
    155153    } 
    156154 
    157155    public void deleteEntry(long sessionId, String id, Map<String, String> map) 
    158             throws DirectoryException, DirectoryException
     156            throws DirectoryException
    159157        try { 
    160158            getSession(sessionId).deleteEntry(id, map); 
    161159        } catch (Throwable e) { 
    162             throw exceptionHandler.wrapException(e); 
     160            throw EJBExceptionHandler.wrapException(e); 
    163161        } 
    164162    } 
     
    168166            return getSession(sessionId).getEntries(); 
    169167        } catch (Throwable e) { 
    170             throw exceptionHandler.wrapException(e); 
     168            throw EJBExceptionHandler.wrapException(e); 
    171169        } 
    172170    } 
     
    177175            return getSession(sessionId).getEntry(id); 
    178176        } catch (Throwable e) { 
    179             throw exceptionHandler.wrapException(e); 
     177            throw EJBExceptionHandler.wrapException(e); 
    180178        } 
    181179    } 
     
    185183            return getSession(sessionId).getIdField(); 
    186184        } catch (Throwable e) { 
    187             throw exceptionHandler.wrapException(e); 
     185            throw EJBExceptionHandler.wrapException(e); 
    188186        } 
    189187    } 
     
    193191            return getSession(sessionId).getPasswordField(); 
    194192        } catch (Throwable e) { 
    195             throw exceptionHandler.wrapException(e); 
     193            throw EJBExceptionHandler.wrapException(e); 
    196194        } 
    197195    } 
     
    203201            return getSession(sessionId).getProjection(filter, columnName); 
    204202        } catch (Throwable e) { 
    205             throw exceptionHandler.wrapException(e); 
     203            throw EJBExceptionHandler.wrapException(e); 
    206204        } 
    207205    } 
     
    214212                    columnName); 
    215213        } catch (Throwable e) { 
    216             throw exceptionHandler.wrapException(e); 
     214            throw EJBExceptionHandler.wrapException(e); 
    217215        } 
    218216    } 
     
    222220            return getSession(sessionId).isAuthenticating(); 
    223221        } catch (Throwable e) { 
    224             throw exceptionHandler.wrapException(e); 
     222            throw EJBExceptionHandler.wrapException(e); 
    225223        } 
    226224    } 
     
    230228            return getSession(sessionId).isReadOnly(); 
    231229        } catch (Throwable e) { 
    232             throw exceptionHandler.wrapException(e); 
     230            throw EJBExceptionHandler.wrapException(e); 
    233231        } 
    234232    } 
     
    239237            return getSession(sessionId).query(filter); 
    240238        } catch (Throwable e) { 
    241             throw exceptionHandler.wrapException(e); 
     239            throw EJBExceptionHandler.wrapException(e); 
    242240        } 
    243241    } 
     
    248246            return getSession(sessionId).query(filter, fulltext); 
    249247        } catch (Throwable e) { 
    250             throw exceptionHandler.wrapException(e); 
     248            throw EJBExceptionHandler.wrapException(e); 
    251249        } 
    252250    } 
     
    258256            return getSession(sessionId).query(filter, fulltext, orderBy); 
    259257        } catch (Throwable e) { 
    260             throw exceptionHandler.wrapException(e); 
     258            throw EJBExceptionHandler.wrapException(e); 
    261259        } 
    262260    } 
     
    266264            getSession(sessionId).rollback(); 
    267265        } catch (Throwable e) { 
    268             throw exceptionHandler.wrapException(e); 
     266            throw EJBExceptionHandler.wrapException(e); 
    269267        } 
    270268    } 
     
    275273            getSession(sessionId).updateEntry(docModel); 
    276274        } catch (Throwable e) { 
    277             throw exceptionHandler.wrapException(e); 
     275            throw EJBExceptionHandler.wrapException(e); 
    278276        } 
    279277    } 
     
    283281            return getService().getDirectoryNames(); 
    284282        } catch (Throwable e) { 
    285             throw exceptionHandler.wrapException(e); 
     283            throw EJBExceptionHandler.wrapException(e); 
    286284        } 
    287285    } 
     
    292290            return getService().getDirectorySchema(directoryName); 
    293291        } catch (Throwable e) { 
    294             throw exceptionHandler.wrapException(e); 
     292            throw EJBExceptionHandler.wrapException(e); 
    295293        } 
    296294    } 
     
    303301            return new DirectoryClientImpl(id); 
    304302        } catch (Throwable e) { 
    305             throw exceptionHandler.wrapException(e); 
     303            throw EJBExceptionHandler.wrapException(e); 
    306304        } 
    307305    } 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-directory-facade/src/main/java/org/nuxeo/ecm/platform/directory/ejb/EJBExceptionHandler.java

    r28460 r28610  
    4646     */ 
    4747    @SuppressWarnings({"ThrowableInstanceNeverThrown"}) 
    48     public DirectoryException wrapException(Throwable exception) { 
     48    public static DirectoryException wrapException(Throwable exception) { 
    4949        DirectoryException clientException; 
    5050 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-directory-multi/src/test/java/org/nuxeo/ecm/directory/multi/TestMultiDirectory.java

    r28583 r28610  
    6060    protected void setUp() throws Exception { 
    6161        super.setUp(); 
    62         deploy("test-multidir/typeservice.xml"); 
    63         deploy("test-multidir/schemas-config.xml"); 
    64         deploy("test-multidir/directoryservice.xml"); 
    65         deploy("test-multidir/directory-multifactory.xml"); 
    66  
    67         deploy("test-multidir/directories-config.xml"); 
     62        deployContrib("test-multidir/typeservice.xml"); 
     63        deployContrib("test-multidir/schemas-config.xml"); 
     64        deployContrib("test-multidir/directoryservice.xml"); 
     65        deployContrib("test-multidir/directory-multifactory.xml"); 
     66 
     67        deployContrib("test-multidir/directories-config.xml"); 
    6868 
    6969        // mem dir factory 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-directory-sql/src/test/java/org/nuxeo/ecm/directory/sql/SQLDirectoryTestCase.java

    r28583 r28610  
    2020package org.nuxeo.ecm.directory.sql; 
    2121 
    22 import java.net.URISyntaxException; 
    2322import java.sql.Connection; 
    2423import java.util.Properties; 
    25  
    2624import javax.sql.DataSource; 
    2725 
    2826import org.nuxeo.ecm.core.api.ClientException; 
    2927import org.nuxeo.ecm.directory.Directory; 
     28import org.nuxeo.ecm.directory.DirectoryException; 
    3029import org.nuxeo.ecm.directory.DirectoryServiceImpl; 
    3130import org.nuxeo.ecm.directory.Session; 
    32 import org.nuxeo.ecm.directory.DirectoryException; 
    3331import org.nuxeo.ecm.directory.api.DirectoryService; 
    3432import org.nuxeo.runtime.api.Framework; 
     
    4644    protected void setUp() throws Exception { 
    4745        super.setUp(); 
    48         deploy("test-CoreService.xml"); 
    49         deploy("test-TypeService.xml"); 
     46        deployContrib("test-CoreService.xml"); 
     47        deployContrib("test-TypeService.xml"); 
    5048 
    51         deploy("sql-test-setup/DirectoryTypes.xml"); 
    52         deploy("sql-test-setup/DirectoryService.xml"); 
    53         deploy("sql-test-setup/SQLDirectoryFactory.xml"); 
    54         deploy("test-sql-directories-bundle.xml"); 
     49        deployContrib("sql-test-setup/DirectoryTypes.xml"); 
     50        deployContrib("sql-test-setup/DirectoryService.xml"); 
     51        deployContrib("sql-test-setup/SQLDirectoryFactory.xml"); 
     52        deployContrib("test-sql-directories-bundle.xml"); 
    5553    } 
    5654 
     
    6058    } 
    6159 
    62     protected Session getSession(String dirName) 
     60    protected static Session getSession(String dirName) 
    6361            throws ClientException { 
    6462        DirectoryService dirService = 
     
    6765    } 
    6866 
    69     protected Directory getDirectory(String dirName) 
     67    protected static Directory getDirectory(String dirName) 
    7068            throws DirectoryException { 
    7169        DirectoryServiceImpl dirServiceImpl = 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-directory-sql/src/test/java/org/nuxeo/ecm/directory/sql/TestDescriptorOverride.java

    r23042 r28610  
    2626 
    2727    public void testOverride() throws Exception { 
    28  
    2928        Directory dir = getDirectory("userDirectory"); 
    3029        SQLDirectory sqlDir = (SQLDirectory) dir; 
    3130 
    32         SQLDirectoryDescriptor config; 
    33         config = sqlDir.getConfig(); 
     31        SQLDirectoryDescriptor config = sqlDir.getConfig(); 
    3432 
    3533        assertEquals("always", config.getCreateTablePolicy()); 
    3634        assertEquals("test-users.csv", config.getDataFileName()); 
    3735 
    38         deploy("test-sql-directories-override-bundle.xml"); 
     36        deployContrib("test-sql-directories-override-bundle.xml"); 
    3937 
    4038        dir = getDirectory("userDirectory"); 
  • org.nuxeo.ecm.platform/branches/5.1/nuxeo-platform-directory-sql/src/test/java/org/nuxeo/ecm/directory/sql/TestSQLDirectory.java

    r28057 r28610  
    2525import java.util.List; 
    2626import java.util.Map; 
    27 import java.util.TimeZone; 
    2827 
    2928import org.nuxeo.ecm.core.api.DocumentModel; 
     
    4140    private static final String SCHEMA = "user"; 
    4241 
    43     private Calendar getCalendar(int year, int month, int day, 
     42    private static Calendar getCalendar(int year, int month, int day, 
    4443            int hours, int minutes, int seconds, int milliseconds) { 
    4544        Calendar cal = Calendar.getInstance(); 
     
    5453    } 
    5554 
    56