|
@@ -19,11 +19,16 @@
|
|
|
|
|
|
package org.elasticsearch.index.codec;
|
|
|
|
|
|
+import static org.hamcrest.Matchers.instanceOf;
|
|
|
+
|
|
|
+import java.io.IOException;
|
|
|
+import java.util.Collections;
|
|
|
+
|
|
|
import org.apache.logging.log4j.LogManager;
|
|
|
import org.apache.lucene.codecs.Codec;
|
|
|
import org.apache.lucene.codecs.lucene50.Lucene50StoredFieldsFormat;
|
|
|
import org.apache.lucene.codecs.lucene50.Lucene50StoredFieldsFormat.Mode;
|
|
|
-import org.apache.lucene.codecs.lucene80.Lucene80Codec;
|
|
|
+import org.apache.lucene.codecs.lucene84.Lucene84Codec;
|
|
|
import org.apache.lucene.document.Document;
|
|
|
import org.apache.lucene.index.DirectoryReader;
|
|
|
import org.apache.lucene.index.IndexWriter;
|
|
@@ -42,19 +47,14 @@ import org.elasticsearch.plugins.MapperPlugin;
|
|
|
import org.elasticsearch.test.ESTestCase;
|
|
|
import org.elasticsearch.test.IndexSettingsModule;
|
|
|
|
|
|
-import java.io.IOException;
|
|
|
-import java.util.Collections;
|
|
|
-
|
|
|
-import static org.hamcrest.Matchers.instanceOf;
|
|
|
-
|
|
|
@SuppressCodecs("*") // we test against default codec so never get a random one here!
|
|
|
public class CodecTests extends ESTestCase {
|
|
|
|
|
|
public void testResolveDefaultCodecs() throws Exception {
|
|
|
CodecService codecService = createCodecService();
|
|
|
assertThat(codecService.codec("default"), instanceOf(PerFieldMappingPostingFormatCodec.class));
|
|
|
- assertThat(codecService.codec("default"), instanceOf(Lucene80Codec.class));
|
|
|
- assertThat(codecService.codec("Lucene80"), instanceOf(Lucene80Codec.class));
|
|
|
+ assertThat(codecService.codec("default"), instanceOf(Lucene84Codec.class));
|
|
|
+ assertThat(codecService.codec("Lucene84"), instanceOf(Lucene84Codec.class));
|
|
|
}
|
|
|
|
|
|
public void testDefault() throws Exception {
|