1
|
/**
|
2
|
* Copyright (C) 2007 EDIT
|
3
|
* European Distributed Institute of Taxonomy
|
4
|
* http://www.e-taxonomy.eu
|
5
|
*
|
6
|
* The contents of this file are subject to the Mozilla Public License Version 1.1
|
7
|
* See LICENSE.TXT at the top of this package for the full license terms.
|
8
|
*/
|
9
|
|
10
|
package eu.etaxonomy.cdm.test.function;
|
11
|
|
12
|
import org.apache.log4j.Logger;
|
13
|
import org.junit.Before;
|
14
|
import org.junit.Ignore;
|
15
|
import org.junit.Test;
|
16
|
|
17
|
import eu.etaxonomy.cdm.api.application.CdmApplicationController;
|
18
|
import eu.etaxonomy.cdm.database.CdmDataSource;
|
19
|
import eu.etaxonomy.cdm.database.DbSchemaValidation;
|
20
|
|
21
|
/**
|
22
|
* <h2>NOTE</h2>
|
23
|
* This is a test for sole development purposes, it is not
|
24
|
* touched my mvn test since it is not matching the "\/**\/*Test" pattern,
|
25
|
* but it should be annotate with @Ignore when running the project a s junit suite in eclipse
|
26
|
*
|
27
|
*
|
28
|
* @author n.hoffmann
|
29
|
* @since Sep 25, 2009
|
30
|
*/
|
31
|
@Ignore /* IGNORE in Suite */
|
32
|
public class TestC3P0Configuration{
|
33
|
@SuppressWarnings("unused")
|
34
|
private static final Logger logger = Logger.getLogger(TestC3P0Configuration.class);
|
35
|
|
36
|
CdmApplicationController appController;
|
37
|
|
38
|
@Before
|
39
|
public void setup(){
|
40
|
CdmDataSource dataSource = CdmDataSource.NewMySqlInstance("localhost", "test", -1, "edit", "wp5");
|
41
|
appController = CdmApplicationController.NewInstance(dataSource, DbSchemaValidation.CREATE);
|
42
|
}
|
43
|
|
44
|
@Test
|
45
|
public void testLongSession() throws InterruptedException{
|
46
|
appController.NewConversation();
|
47
|
|
48
|
appController.getTaxonService().list(null, null, null, null,null);
|
49
|
|
50
|
Thread.sleep(70 * 1000);
|
51
|
|
52
|
appController.getTaxonService().list(null, null, null, null,null);
|
53
|
}
|
54
|
}
|