Class MapperScriptTestCase<FactoryType>

java.lang.Object
org.junit.Assert
org.apache.lucene.util.LuceneTestCase
org.elasticsearch.test.ESTestCase
org.elasticsearch.index.mapper.MapperServiceTestCase
org.elasticsearch.index.mapper.MapperScriptTestCase<FactoryType>

public abstract class MapperScriptTestCase<FactoryType>
extends MapperServiceTestCase
  • Constructor Details

    • MapperScriptTestCase

      public MapperScriptTestCase()
  • Method Details

    • type

      protected abstract java.lang.String type()
    • serializableScript

      protected abstract FactoryType serializableScript()
    • errorThrowingScript

      protected abstract FactoryType errorThrowingScript()
    • singleValueScript

      protected abstract FactoryType singleValueScript()
    • multipleValuesScript

      protected abstract FactoryType multipleValuesScript()
    • script

      protected FactoryType script​(java.lang.String id)
    • compileScript

      protected <T> T compileScript​(org.elasticsearch.script.Script script, org.elasticsearch.script.ScriptContext<T> context)
      Overrides:
      compileScript in class MapperServiceTestCase
    • testToXContent

      public void testToXContent() throws java.io.IOException
      Throws:
      java.io.IOException
    • testCannotIndexDirectlyIntoScriptMapper

      public void testCannotIndexDirectlyIntoScriptMapper() throws java.io.IOException
      Throws:
      java.io.IOException
    • testStoredScriptsNotPermitted

      public final void testStoredScriptsNotPermitted()
    • testIndexAndDocValuesFalseNotPermitted

      public final void testIndexAndDocValuesFalseNotPermitted()
    • testMultiFieldsNotPermitted

      public final void testMultiFieldsNotPermitted()
    • testCopyToNotPermitted

      public final void testCopyToNotPermitted()
    • testOnScriptErrorParameterRequiresScript

      public final void testOnScriptErrorParameterRequiresScript()
    • testOnScriptErrorContinue

      public final void testOnScriptErrorContinue() throws java.io.IOException
      Throws:
      java.io.IOException
    • testRejectScriptErrors

      public final void testRejectScriptErrors() throws java.io.IOException
      Throws:
      java.io.IOException
    • testMultipleValues

      public final void testMultipleValues() throws java.io.IOException
      Throws:
      java.io.IOException
    • assertMultipleValues

      protected abstract void assertMultipleValues​(org.apache.lucene.index.IndexableField[] fields)
    • testDocValuesDisabled

      public final void testDocValuesDisabled() throws java.io.IOException
      Throws:
      java.io.IOException
    • assertDocValuesDisabled

      protected abstract void assertDocValuesDisabled​(org.apache.lucene.index.IndexableField[] fields)
    • testIndexDisabled

      public final void testIndexDisabled() throws java.io.IOException
      Throws:
      java.io.IOException
    • assertIndexDisabled

      protected abstract void assertIndexDisabled​(org.apache.lucene.index.IndexableField[] fields)