Project

General

Profile

« Previous | Next » 

Revision 608f7100

Added by Cherian Mathew almost 9 years ago

corrected merge to latest snapshot version
updated hibernate config file and test db
setup testing framework with jetty and maven

View differences:

eu.etaxonomy.taxeditor.test/src/test/java/eu/etaxonomy/taxeditor/httpinvoker/CdmServerTest.java
9 9
*/
10 10
package eu.etaxonomy.taxeditor.httpinvoker;
11 11

  
12
import org.apache.log4j.Level;
13 12
import org.apache.log4j.Logger;
14 13
import org.junit.Assert;
15
import org.junit.Ignore;
16 14
import org.junit.Test;
17 15
import org.unitils.UnitilsJUnit4;
18 16

  
19
import eu.etaxonomy.taxeditor.lazyloading.AbstractLazyInitializerTest;
17
import eu.etaxonomy.taxeditor.remoting.server.CDMServerException;
20 18

  
21 19
/**
22 20
 * @author cmathew
......
27 25
    private static final Logger logger = Logger.getLogger(CdmServerTest.class);
28 26

  
29 27

  
28
    @Test
29
    public void startCdmServer() throws CDMServerException {
30
        CDMServer.getInstance().start();
31
    }
32

  
30 33
    @Test
31 34
    public void stopCdmServer() {
32
        Logger.getRootLogger().setLevel(Level.INFO);
33
        CDMServer.getInstance().setKeepServerRunning(false);
34 35
        try {
35 36
            CDMServer.getInstance().stop(true);
36 37
        } catch (Exception e) {
38
            e.printStackTrace();
37 39
            Assert.fail("Server could not be stopped. Reason : " + e.getMessage());
38 40
        }
39 41
    }

Also available in: Unified diff