org.hibernate.search.test
Class SearchTestCase
java.lang.Object
junit.framework.Assert
junit.framework.TestCase
org.hibernate.testing.junit.functional.annotations.HibernateTestCase
org.hibernate.search.test.SearchTestCase
- All Implemented Interfaces:
- junit.framework.Test
public abstract class SearchTestCase
- extends org.hibernate.testing.junit.functional.annotations.HibernateTestCase
Base class for Hibernate Search unit tests.
- Author:
- Emmanuel Bernard, Hardy Ferentschik
Nested classes/interfaces inherited from class org.hibernate.testing.junit.functional.annotations.HibernateTestCase |
org.hibernate.testing.junit.functional.annotations.HibernateTestCase.RollbackWork, org.hibernate.testing.junit.functional.annotations.HibernateTestCase.Skip |
Fields inherited from class org.hibernate.testing.junit.functional.annotations.HibernateTestCase |
cfg |
Methods inherited from class org.hibernate.testing.junit.functional.annotations.HibernateTestCase |
buildSkip, determineSkipByDialect, fullTestName, getAnnotatedClasses, getCfg, getDialect, getMappings, getXmlFiles, locateAnnotation, recreateSchema, reportSkip, runBare, runSchemaDrop, runSchemaGeneration, runTest, setCfg, tearDown |
Methods inherited from class junit.framework.TestCase |
countTestCases, createResult, getName, run, run, setName, toString |
Methods inherited from class junit.framework.Assert |
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail |
standardAnalyzer
public static final org.apache.lucene.analysis.Analyzer standardAnalyzer
stopAnalyzer
public static final org.apache.lucene.analysis.Analyzer stopAnalyzer
simpleAnalyzer
public static final org.apache.lucene.analysis.Analyzer simpleAnalyzer
keywordAnalyzer
public static final org.apache.lucene.analysis.Analyzer keywordAnalyzer
sessions
protected static org.hibernate.SessionFactory sessions
session
protected org.hibernate.Session session
SearchTestCase
public SearchTestCase()
SearchTestCase
public SearchTestCase(String x)
handleUnclosedResources
protected void handleUnclosedResources()
- Specified by:
handleUnclosedResources
in class org.hibernate.testing.junit.functional.annotations.HibernateTestCase
closeResources
protected void closeResources()
- Specified by:
closeResources
in class org.hibernate.testing.junit.functional.annotations.HibernateTestCase
openSession
public org.hibernate.Session openSession()
throws org.hibernate.HibernateException
- Throws:
org.hibernate.HibernateException
openSession
public org.hibernate.Session openSession(org.hibernate.Interceptor interceptor)
throws org.hibernate.HibernateException
- Throws:
org.hibernate.HibernateException
setSessions
protected void setSessions(org.hibernate.SessionFactory sessions)
getSessions
protected org.hibernate.SessionFactory getSessions()
configure
protected void configure(org.hibernate.cfg.Configuration cfg)
- Overrides:
configure
in class org.hibernate.testing.junit.functional.annotations.HibernateTestCase
getDirectory
protected org.apache.lucene.store.Directory getDirectory(Class<?> clazz)
setUp
protected void setUp()
throws Exception
- Overrides:
setUp
in class org.hibernate.testing.junit.functional.annotations.HibernateTestCase
- Throws:
Exception
ensureIndexesAreEmpty
protected void ensureIndexesAreEmpty()
getSearchFactory
protected SearchFactory getSearchFactory()
getBaseIndexDir
protected File getBaseIndexDir()
buildConfiguration
protected void buildConfiguration()
throws Exception
- Specified by:
buildConfiguration
in class org.hibernate.testing.junit.functional.annotations.HibernateTestCase
- Throws:
Exception
getAnnotatedPackages
protected String[] getAnnotatedPackages()
- Overrides:
getAnnotatedPackages
in class org.hibernate.testing.junit.functional.annotations.HibernateTestCase
getTargetLuceneVersion
public static org.apache.lucene.util.Version getTargetLuceneVersion()
getTargetDir
public File getTargetDir()
- Returns the target directory of the build.
- Returns:
- the target directory of the build
Copyright © 2006-2010 Hibernate. All Rights Reserved.