hexsha
stringlengths 40
40
| size
int64 3
1.05M
| ext
stringclasses 1
value | lang
stringclasses 1
value | max_stars_repo_path
stringlengths 5
1.02k
| max_stars_repo_name
stringlengths 4
126
| max_stars_repo_head_hexsha
stringlengths 40
78
| max_stars_repo_licenses
list | max_stars_count
float64 1
191k
⌀ | max_stars_repo_stars_event_min_datetime
stringlengths 24
24
⌀ | max_stars_repo_stars_event_max_datetime
stringlengths 24
24
⌀ | max_issues_repo_path
stringlengths 5
1.02k
| max_issues_repo_name
stringlengths 4
114
| max_issues_repo_head_hexsha
stringlengths 40
78
| max_issues_repo_licenses
list | max_issues_count
float64 1
92.2k
⌀ | max_issues_repo_issues_event_min_datetime
stringlengths 24
24
⌀ | max_issues_repo_issues_event_max_datetime
stringlengths 24
24
⌀ | max_forks_repo_path
stringlengths 5
1.02k
| max_forks_repo_name
stringlengths 4
136
| max_forks_repo_head_hexsha
stringlengths 40
78
| max_forks_repo_licenses
list | max_forks_count
float64 1
105k
⌀ | max_forks_repo_forks_event_min_datetime
stringlengths 24
24
⌀ | max_forks_repo_forks_event_max_datetime
stringlengths 24
24
⌀ | avg_line_length
float64 2.55
99.9
| max_line_length
int64 3
1k
| alphanum_fraction
float64 0.25
1
| index
int64 0
1M
| content
stringlengths 3
1.05M
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
3e075d942f76b0c6303e539c5273f2ec60d9cbb7
| 5,568 |
java
|
Java
|
src/test/java/ninja/egg82/mvn/TestBuilder.java
|
egg82/MVNLoader
|
276fc2165f10b97a0266e974b89495c4f15df41f
|
[
"MIT"
] | 1 |
2021-04-23T10:05:44.000Z
|
2021-04-23T10:05:44.000Z
|
src/test/java/ninja/egg82/mvn/TestBuilder.java
|
plan-player-analytics/MVNLoader
|
276fc2165f10b97a0266e974b89495c4f15df41f
|
[
"MIT"
] | 1 |
2021-05-13T18:13:51.000Z
|
2021-05-15T16:19:29.000Z
|
src/test/java/ninja/egg82/mvn/TestBuilder.java
|
plan-player-analytics/MVNLoader
|
276fc2165f10b97a0266e974b89495c4f15df41f
|
[
"MIT"
] | 1 |
2021-05-29T06:24:20.000Z
|
2021-05-29T06:24:20.000Z
| 55.68 | 168 | 0.581717 | 3,118 |
package ninja.egg82.mvn;
import org.apache.maven.model.Dependency;
import org.apache.maven.model.Model;
import org.apache.maven.model.Repository;
import org.apache.maven.model.building.ModelBuildingException;
import org.jetbrains.annotations.NotNull;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
import java.io.File;
import java.io.IOException;
import java.net.URISyntaxException;
class TestBuilder {
@Test
void buildSimple() throws URISyntaxException, ModelBuildingException, IOException {
Model model = new JarBuilder("io.ebean", "ebean-core", "12.7.2", "https://repo.maven.apache.org/maven2")
.build(new File(getCurrentDir(), "cache"));
Assertions.assertNotNull(model);
System.out.println(model.getGroupId() + ":" + model.getArtifactId() + ":" + model.getVersion());
for (Repository repo : model.getRepositories()) {
if (repo.getReleases() != null && repo.getSnapshots() != null) {
System.out.println(repo.getUrl() + " [" + repo.getId() + "/" + repo.getName() + "] - R:" + repo.getReleases().isEnabled() + ", S:" + repo.getSnapshots()
.isEnabled());
} else {
System.out.println(repo.getUrl() + " [" + repo.getId() + "/" + repo.getName() + "]");
}
}
for (Dependency dep : model.getDependencies()) {
System.out.println(dep.getGroupId() + ":" + dep.getArtifactId() + ":" + dep.getVersion() + " [" + dep.getScope() + "]");
}
}
@Test
void buildSimpleProxy() throws URISyntaxException, ModelBuildingException, IOException {
Model model = new JarBuilder("io.ebean", "ebean-core", "12.7.2", "https://repo.maven.apache.org/maven2")
.setRepositoryProxy("https://repo.maven.apache.org/maven2", "https://nexus.egg82.me/repository/maven-central/")
.build(new File(getCurrentDir(), "cache"));
Assertions.assertNotNull(model);
System.out.println(model.getGroupId() + ":" + model.getArtifactId() + ":" + model.getVersion());
for (Repository repo : model.getRepositories()) {
if (repo.getReleases() != null && repo.getSnapshots() != null) {
System.out.println(repo.getUrl() + " [" + repo.getId() + "/" + repo.getName() + "] - R:" + repo.getReleases().isEnabled() + ", S:" + repo.getSnapshots()
.isEnabled());
} else {
System.out.println(repo.getUrl() + " [" + repo.getId() + "/" + repo.getName() + "]");
}
}
for (Dependency dep : model.getDependencies()) {
System.out.println(dep.getGroupId() + ":" + dep.getArtifactId() + ":" + dep.getVersion() + " [" + dep.getScope() + "]");
}
}
@Test
void buildComplex() throws URISyntaxException, ModelBuildingException, IOException {
Model model = new JarBuilder("com.destroystokyo.paper", "paper-api", "1.16.5-R0.1-SNAPSHOT", "https://papermc.io/repo/repository/maven-public/")
.build(new File(getCurrentDir(), "cache"));
Assertions.assertNotNull(model);
System.out.println(model.getGroupId() + ":" + model.getArtifactId() + ":" + model.getVersion());
for (Repository repo : model.getRepositories()) {
if (repo.getReleases() != null && repo.getSnapshots() != null) {
System.out.println(repo.getUrl() + " [" + repo.getId() + "/" + repo.getName() + "] - R:" + repo.getReleases().isEnabled() + ", S:" + repo.getSnapshots()
.isEnabled());
} else {
System.out.println(repo.getUrl() + " [" + repo.getId() + "/" + repo.getName() + "]");
}
}
for (Dependency dep : model.getDependencies()) {
System.out.println(dep.getGroupId() + ":" + dep.getArtifactId() + ":" + dep.getVersion() + " [" + dep.getScope() + "]");
}
}
@Test
void buildComplexProxy() throws URISyntaxException, ModelBuildingException, IOException {
Model model = new JarBuilder("com.destroystokyo.paper", "paper-api", "1.16.5-R0.1-SNAPSHOT", "https://papermc.io/repo/repository/maven-public/")
.setRepositoryProxy("https://papermc.io/repo/repository/maven-public/", "https://nexus.egg82.me/repository/papermc/")
.setRepositoryProxy("https://repo.maven.apache.org/maven2", "https://nexus.egg82.me/repository/maven-central/")
.build(new File(getCurrentDir(), "cache"));
Assertions.assertNotNull(model);
System.out.println(model.getGroupId() + ":" + model.getArtifactId() + ":" + model.getVersion());
for (Repository repo : model.getRepositories()) {
if (repo.getReleases() != null && repo.getSnapshots() != null) {
System.out.println(repo.getUrl() + " [" + repo.getId() + "/" + repo.getName() + "] - R:" + repo.getReleases().isEnabled() + ", S:" + repo.getSnapshots()
.isEnabled());
} else {
System.out.println(repo.getUrl() + " [" + repo.getId() + "/" + repo.getName() + "]");
}
}
for (Dependency dep : model.getDependencies()) {
System.out.println(dep.getGroupId() + ":" + dep.getArtifactId() + ":" + dep.getVersion() + " [" + dep.getScope() + "]");
}
}
@NotNull
private File getCurrentDir() throws URISyntaxException {
return new File(getClass().getProtectionDomain().getCodeSource().getLocation().toURI()).getParentFile();
}
}
|
3e075d9f7e08d05f44fac901a8ee88fe61961f93
| 6,626 |
java
|
Java
|
src/main/java/eu/amidst/extension/learn/structure/operator/hc/tree/BltmHcIncreaseCard.java
|
ferjorosa/bayesian-latent-forests
|
3d9e19f1d0be1e4cca0b390866589061a670cc20
|
[
"Apache-2.0"
] | 1 |
2021-05-21T07:44:57.000Z
|
2021-05-21T07:44:57.000Z
|
src/main/java/eu/amidst/extension/learn/structure/operator/hc/tree/BltmHcIncreaseCard.java
|
ferjorosa/parkinson-subtypes
|
e40fe476430b74c0098c806502e91acb164036d7
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/eu/amidst/extension/learn/structure/operator/hc/tree/BltmHcIncreaseCard.java
|
ferjorosa/parkinson-subtypes
|
e40fe476430b74c0098c806502e91acb164036d7
|
[
"Apache-2.0"
] | null | null | null | 45.383562 | 133 | 0.676124 | 3,119 |
package eu.amidst.extension.learn.structure.operator.hc.tree;
import eu.amidst.core.learning.parametric.bayesian.utils.PlateuStructure;
import eu.amidst.core.models.DAG;
import eu.amidst.core.variables.Variable;
import eu.amidst.core.variables.Variables;
import eu.amidst.core.variables.stateSpaceTypes.FiniteStateSpace;
import eu.amidst.extension.learn.parameter.VBEMConfig;
import eu.amidst.extension.learn.parameter.VBEM_Global;
import eu.amidst.extension.learn.parameter.VBEM_Local;
import eu.amidst.extension.learn.structure.Result;
import eu.amidst.extension.learn.structure.typelocalvbem.TypeLocalVBEM;
import eu.amidst.extension.util.GraphUtilsAmidst;
import java.util.HashSet;
import java.util.List;
import java.util.stream.Collectors;
public class BltmHcIncreaseCard implements BltmHcOperator {
private int maxCardinality;
private VBEMConfig localVBEMConfig;
private VBEMConfig globalVBEMConfig;
private TypeLocalVBEM typeLocalVBEM;
public BltmHcIncreaseCard(int maxCardinality, TypeLocalVBEM typeLocalVBEM) {
this(maxCardinality,
new VBEMConfig(),
new VBEMConfig(),
typeLocalVBEM);
}
public BltmHcIncreaseCard(int maxCardinality,
VBEMConfig localVBEMConfig,
VBEMConfig globalVBEMConfig,
TypeLocalVBEM typeLocalVBEM) {
this.maxCardinality = maxCardinality;
this.localVBEMConfig = localVBEMConfig;
this.globalVBEMConfig = globalVBEMConfig;
this.typeLocalVBEM = typeLocalVBEM;
}
/** ALGORITMO:
La idea principal es la de aprender de forma local el mejor modelo generado por este operador.
Una vez se ha escogido el mejor modelo local, lo podemos afinar con aprendizaje global
Copias el objeto Variables
Copias el objeto DAG
Incrementas el numero de estados de la variable seleccionada
Creas un nuevo plateau y copias aquellos aspectos que no han sido modificados por el incremento de card
Aprendes y guardas el score
Decrementas la cardinalidad de la variable seleccionada
Pasas a la siguiente variable y vuelves a empezar
RETURN:
Para poder seguir trabajando con el modelo aprendido, se va a devolver la copia del Plateau
modificado tras hacer un aprendizaje completo con VBEM.
Por esto, creo que el mejor objeto de retorno deberia ser Result.
MyNote: Al igual que en BltmHcDecreaseCard, me aprovecho de la separacion de Variables con Plateau para acelerar
el proceso de copia del Plateau, pero en VBEM_Global tengo que restaurar la cardinalidad o lanza IndexOutOfBounds
*/
@Override
public Result apply(PlateuStructure plateuStructure, DAG dag, boolean globalVBEM) {
List<String> discreteLatentVars = dag.getVariables().getListOfVariables()
.stream()
.filter(x-> x.isDiscrete() && !x.isObservable())
.map(x->x.getName())
.collect(Collectors.toList());
return apply(plateuStructure, dag, discreteLatentVars, globalVBEM);
}
public Result apply(PlateuStructure plateuStructure, DAG dag, List<String> whiteList, boolean globalVBEM) {
PlateuStructure bestModel = null; // TODO: Cambio del 30-08, no deberia dar problema
double bestModelScore = -Double.MAX_VALUE;
Variable bestVariable = null;
Variables copyVariables = dag.getVariables().deepCopy();
DAG copyDAG = dag.deepCopy(copyVariables);
/* Iteramos por el conjunto de variables latentes */
for(Variable variable: copyVariables){
if(!variable.isObservable()
&& variable.isDiscrete()
&& whiteList.contains(variable.getName())
&& variable.getNumberOfStates() < this.maxCardinality) {
/* Incrementamos la cardinalidad de la variable */
int newCardinality = variable.getNumberOfStates() + 1;
variable.setNumberOfStates(newCardinality);
variable.setStateSpaceType(new FiniteStateSpace(newCardinality));
/* Creamos un nuevo Plateau para el aprendizaje donde omitimos copiar la variable en cuestion y sus hijos */
HashSet<Variable> omittedVariables = new HashSet<>();
omittedVariables.add(variable);
omittedVariables.addAll(GraphUtilsAmidst.getChildren(variable, copyDAG));
PlateuStructure copyPlateauStructure = plateuStructure.deepCopy(copyDAG, omittedVariables);
/* Aprendemos el modelo de forma local */
VBEM_Local localVBEM = new VBEM_Local(this.localVBEMConfig);
localVBEM.learnModel(copyPlateauStructure, copyDAG, typeLocalVBEM.variablesToUpdate(variable, copyDAG));
/* Comparamos el modelo generado con el mejor modelo actual */
if(localVBEM.getPlateuStructure().getLogProbabilityOfEvidence() > bestModelScore) {
bestModel = localVBEM.getPlateuStructure();
bestModelScore = localVBEM.getPlateuStructure().getLogProbabilityOfEvidence();
bestVariable = variable;
}
/* Decrementamos la cardinalidad de la variable para poder resetear el proceso */
variable.setNumberOfStates(newCardinality - 1);
variable.setStateSpaceType(new FiniteStateSpace(newCardinality - 1));
}
}
/* Si el operador produjo un mejor modelo, lo aprendemos con VBEM_HC de forma "global" */
// TODO: Escoger el tipo de inicializacion a utilizar aqui, podria ser incluso NONE
if(bestModelScore > -Double.MAX_VALUE) {
// Incrementamos la cardinalidad de la mejor variable para que no salte una IndexOutOfBoundsException en VMP.runInference
bestVariable.setNumberOfStates(bestVariable.getNumberOfStates() + 1);
bestVariable.setStateSpaceType(new FiniteStateSpace(bestVariable.getNumberOfStates()));
if(globalVBEM) {
VBEM_Global vbem_hc = new VBEM_Global(this.globalVBEMConfig);
vbem_hc.learnModel(bestModel, copyDAG);
bestModel = vbem_hc.getPlateuStructure();
bestModelScore = vbem_hc.getPlateuStructure().getLogProbabilityOfEvidence();
}
}
/* Devolvemos el resultado */
return new Result(bestModel, bestModelScore, copyDAG, "IncreaseCard");
}
}
|
3e075dd1bbc3b67a2bb868dc9e41e7353e41ca2a
| 17,199 |
java
|
Java
|
test/framework/src/main/java/org/opensearch/repositories/blobstore/OpenSearchMockAPIBasedRepositoryIntegTestCase.java
|
korpx-z/OpenSearch
|
dd9622fec64805141848537c0cf5265e8650ffb9
|
[
"Apache-2.0"
] | 4,822 |
2021-04-12T15:03:57.000Z
|
2022-03-31T23:37:49.000Z
|
test/framework/src/main/java/org/opensearch/repositories/blobstore/OpenSearchMockAPIBasedRepositoryIntegTestCase.java
|
korpx-z/OpenSearch
|
dd9622fec64805141848537c0cf5265e8650ffb9
|
[
"Apache-2.0"
] | 2,146 |
2021-04-12T14:10:48.000Z
|
2022-03-31T23:58:34.000Z
|
test/framework/src/main/java/org/opensearch/repositories/blobstore/OpenSearchMockAPIBasedRepositoryIntegTestCase.java
|
dlvenable/OpenSearch
|
17e7a4962da9e85f30c16f552dafea00fd921649
|
[
"Apache-2.0"
] | 593 |
2021-04-12T16:26:05.000Z
|
2022-03-31T11:33:45.000Z
| 39.904872 | 134 | 0.662655 | 3,120 |
/*
* SPDX-License-Identifier: Apache-2.0
*
* The OpenSearch Contributors require contributions made to
* this file be licensed under the Apache-2.0 license or a
* compatible open source license.
*/
/*
* Licensed to Elasticsearch under one or more contributor
* license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright
* ownership. Elasticsearch licenses this file to you under
* the Apache License, Version 2.0 (the "License"); you may
* not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
/*
* Modifications Copyright OpenSearch Contributors. See
* GitHub history for details.
*/
package org.opensearch.repositories.blobstore;
import com.sun.net.httpserver.Headers;
import com.sun.net.httpserver.HttpExchange;
import com.sun.net.httpserver.HttpHandler;
import com.sun.net.httpserver.HttpServer;
import org.apache.http.HttpStatus;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.apache.logging.log4j.message.ParameterizedMessage;
import org.apache.lucene.util.LuceneTestCase;
import org.opensearch.action.admin.indices.forcemerge.ForceMergeResponse;
import org.opensearch.cluster.metadata.IndexMetadata;
import org.opensearch.common.Strings;
import org.opensearch.common.SuppressForbidden;
import org.opensearch.common.bytes.BytesReference;
import org.opensearch.common.network.InetAddresses;
import org.opensearch.common.settings.Settings;
import org.opensearch.repositories.RepositoriesService;
import org.opensearch.repositories.Repository;
import org.opensearch.repositories.RepositoryMissingException;
import org.opensearch.repositories.RepositoryStats;
import org.opensearch.test.BackgroundIndexer;
import org.junit.After;
import org.junit.AfterClass;
import org.junit.Before;
import org.junit.BeforeClass;
import java.io.IOException;
import java.io.InputStream;
import java.net.InetAddress;
import java.net.InetSocketAddress;
import java.util.Collections;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.stream.Collectors;
import java.util.stream.StreamSupport;
import static org.opensearch.test.hamcrest.OpenSearchAssertions.assertAcked;
import static org.opensearch.test.hamcrest.OpenSearchAssertions.assertHitCount;
import static org.hamcrest.Matchers.equalTo;
import static org.hamcrest.Matchers.hasSize;
/**
* Integration tests for {@link BlobStoreRepository} implementations rely on mock APIs that emulate cloud-based services.
*/
@SuppressForbidden(reason = "this test uses a HttpServer to emulate a cloud-based storage service")
// The tests in here do a lot of state updates and other writes to disk and are slowed down too much by WindowsFS
@LuceneTestCase.SuppressFileSystems(value = { "WindowsFS", "ExtrasFS" })
public abstract class OpenSearchMockAPIBasedRepositoryIntegTestCase extends OpenSearchBlobStoreRepositoryIntegTestCase {
/**
* A {@link HttpHandler} that allows to list stored blobs
*/
@SuppressForbidden(reason = "Uses a HttpServer to emulate a cloud-based storage service")
protected interface BlobStoreHttpHandler extends HttpHandler {
Map<String, BytesReference> blobs();
}
private static final byte[] BUFFER = new byte[1024];
private static HttpServer httpServer;
protected Map<String, HttpHandler> handlers;
private static final Logger log = LogManager.getLogger();
@BeforeClass
public static void startHttpServer() throws Exception {
httpServer = HttpServer.create(new InetSocketAddress(InetAddress.getLoopbackAddress(), 0), 0);
httpServer.setExecutor(r -> {
try {
r.run();
} catch (Throwable t) {
log.error("Error in execution on mock http server IO thread", t);
throw t;
}
});
httpServer.start();
}
@Before
public void setUpHttpServer() {
handlers = new HashMap<>(createHttpHandlers());
handlers.replaceAll((k, h) -> wrap(randomBoolean() ? createErroneousHttpHandler(h) : h, logger));
handlers.forEach(httpServer::createContext);
}
@AfterClass
public static void stopHttpServer() {
httpServer.stop(0);
httpServer = null;
}
@After
public void tearDownHttpServer() {
if (handlers != null) {
for (Map.Entry<String, HttpHandler> handler : handlers.entrySet()) {
httpServer.removeContext(handler.getKey());
HttpHandler h = handler.getValue();
while (h instanceof DelegatingHttpHandler) {
h = ((DelegatingHttpHandler) h).getDelegate();
}
if (h instanceof BlobStoreHttpHandler) {
List<String> blobs = ((BlobStoreHttpHandler) h).blobs()
.keySet()
.stream()
.filter(blob -> blob.contains("index") == false)
.collect(Collectors.toList());
assertThat("Only index blobs should remain in repository but found " + blobs, blobs, hasSize(0));
}
}
}
}
protected abstract Map<String, HttpHandler> createHttpHandlers();
protected abstract HttpHandler createErroneousHttpHandler(HttpHandler delegate);
/**
* Test the snapshot and restore of an index which has large segments files.
*/
public void testSnapshotWithLargeSegmentFiles() throws Exception {
final String repository = createRepository(randomName());
final String index = "index-no-merges";
createIndex(
index,
Settings.builder().put(IndexMetadata.SETTING_NUMBER_OF_SHARDS, 1).put(IndexMetadata.SETTING_NUMBER_OF_REPLICAS, 0).build()
);
final long nbDocs = randomLongBetween(10_000L, 20_000L);
try (BackgroundIndexer indexer = new BackgroundIndexer(index, "_doc", client(), (int) nbDocs)) {
waitForDocs(nbDocs, indexer);
}
flushAndRefresh(index);
ForceMergeResponse forceMerge = client().admin().indices().prepareForceMerge(index).setFlush(true).setMaxNumSegments(1).get();
assertThat(forceMerge.getSuccessfulShards(), equalTo(1));
assertHitCount(client().prepareSearch(index).setSize(0).setTrackTotalHits(true).get(), nbDocs);
final String snapshot = "snapshot";
assertSuccessfulSnapshot(
client().admin().cluster().prepareCreateSnapshot(repository, snapshot).setWaitForCompletion(true).setIndices(index)
);
assertAcked(client().admin().indices().prepareDelete(index));
assertSuccessfulRestore(client().admin().cluster().prepareRestoreSnapshot(repository, snapshot).setWaitForCompletion(true));
ensureGreen(index);
assertHitCount(client().prepareSearch(index).setSize(0).setTrackTotalHits(true).get(), nbDocs);
assertAcked(client().admin().cluster().prepareDeleteSnapshot(repository, snapshot).get());
}
public void testRequestStats() throws Exception {
final String repository = createRepository(randomName());
final String index = "index-no-merges";
createIndex(
index,
Settings.builder().put(IndexMetadata.SETTING_NUMBER_OF_SHARDS, 1).put(IndexMetadata.SETTING_NUMBER_OF_REPLICAS, 0).build()
);
final long nbDocs = randomLongBetween(10_000L, 20_000L);
try (BackgroundIndexer indexer = new BackgroundIndexer(index, "_doc", client(), (int) nbDocs)) {
waitForDocs(nbDocs, indexer);
}
flushAndRefresh(index);
ForceMergeResponse forceMerge = client().admin().indices().prepareForceMerge(index).setFlush(true).setMaxNumSegments(1).get();
assertThat(forceMerge.getSuccessfulShards(), equalTo(1));
assertHitCount(client().prepareSearch(index).setSize(0).setTrackTotalHits(true).get(), nbDocs);
final String snapshot = "snapshot";
assertSuccessfulSnapshot(
client().admin().cluster().prepareCreateSnapshot(repository, snapshot).setWaitForCompletion(true).setIndices(index)
);
assertAcked(client().admin().indices().prepareDelete(index));
assertSuccessfulRestore(client().admin().cluster().prepareRestoreSnapshot(repository, snapshot).setWaitForCompletion(true));
ensureGreen(index);
assertHitCount(client().prepareSearch(index).setSize(0).setTrackTotalHits(true).get(), nbDocs);
assertAcked(client().admin().cluster().prepareDeleteSnapshot(repository, snapshot).get());
final RepositoryStats repositoryStats = StreamSupport.stream(
internalCluster().getInstances(RepositoriesService.class).spliterator(),
false
).map(repositoriesService -> {
try {
return repositoriesService.repository(repository);
} catch (RepositoryMissingException e) {
return null;
}
}).filter(Objects::nonNull).map(Repository::stats).reduce(RepositoryStats::merge).get();
Map<String, Long> sdkRequestCounts = repositoryStats.requestCounts;
final Map<String, Long> mockCalls = getMockRequestCounts();
String assertionErrorMsg = String.format("SDK sent [%s] calls and handler measured [%s] calls", sdkRequestCounts, mockCalls);
assertEquals(assertionErrorMsg, mockCalls, sdkRequestCounts);
}
private Map<String, Long> getMockRequestCounts() {
for (HttpHandler h : handlers.values()) {
while (h instanceof DelegatingHttpHandler) {
if (h instanceof HttpStatsCollectorHandler) {
return ((HttpStatsCollectorHandler) h).getOperationsCount();
}
h = ((DelegatingHttpHandler) h).getDelegate();
}
}
return Collections.emptyMap();
}
protected static String httpServerUrl() {
InetSocketAddress address = httpServer.getAddress();
return "http://" + InetAddresses.toUriString(address.getAddress()) + ":" + address.getPort();
}
/**
* Consumes and closes the given {@link InputStream}
*/
protected static void drainInputStream(final InputStream inputStream) throws IOException {
while (inputStream.read(BUFFER) >= 0)
;
}
/**
* HTTP handler that injects random service errors
*
* Note: it is not a good idea to allow this handler to simulate too many errors as it would
* slow down the test suite.
*/
@SuppressForbidden(reason = "this test uses a HttpServer to emulate a cloud-based storage service")
protected abstract static class ErroneousHttpHandler implements DelegatingHttpHandler {
// first key is a unique identifier for the incoming HTTP request,
// value is the number of times the request has been seen
private final Map<String, AtomicInteger> requests;
private final HttpHandler delegate;
private final int maxErrorsPerRequest;
@SuppressForbidden(reason = "this test uses a HttpServer to emulate a cloud-based storage service")
protected ErroneousHttpHandler(final HttpHandler delegate, final int maxErrorsPerRequest) {
this.requests = new ConcurrentHashMap<>();
this.delegate = delegate;
this.maxErrorsPerRequest = maxErrorsPerRequest;
assert maxErrorsPerRequest > 1;
}
@Override
public void handle(final HttpExchange exchange) throws IOException {
try {
final String requestId = requestUniqueId(exchange);
assert Strings.hasText(requestId);
final boolean canFailRequest = canFailRequest(exchange);
final int count = requests.computeIfAbsent(requestId, req -> new AtomicInteger(0)).incrementAndGet();
if (count >= maxErrorsPerRequest || canFailRequest == false) {
requests.remove(requestId);
delegate.handle(exchange);
} else {
handleAsError(exchange);
}
} finally {
try {
int read = exchange.getRequestBody().read();
assert read == -1 : "Request body should have been fully read here but saw [" + read + "]";
} catch (IOException e) {
// ignored, stream is assumed to have been closed by previous handler
}
exchange.close();
}
}
protected void handleAsError(final HttpExchange exchange) throws IOException {
try {
drainInputStream(exchange.getRequestBody());
exchange.sendResponseHeaders(HttpStatus.SC_INTERNAL_SERVER_ERROR, -1);
} finally {
exchange.close();
}
}
protected abstract String requestUniqueId(HttpExchange exchange);
protected boolean canFailRequest(final HttpExchange exchange) {
return true;
}
public HttpHandler getDelegate() {
return delegate;
}
}
@SuppressForbidden(reason = "this test uses a HttpServer to emulate a cloud-based storage service")
public interface DelegatingHttpHandler extends HttpHandler {
HttpHandler getDelegate();
}
/**
* HTTP handler that allows collect request stats per request type.
*
* Implementors should keep track of the desired requests on {@link #maybeTrack(String, Headers)}.
*/
@SuppressForbidden(reason = "this test uses a HttpServer to emulate a cloud-based storage service")
public abstract static class HttpStatsCollectorHandler implements DelegatingHttpHandler {
private final HttpHandler delegate;
private final Map<String, Long> operationCount = new HashMap<>();
public HttpStatsCollectorHandler(HttpHandler delegate) {
this.delegate = delegate;
}
@Override
public HttpHandler getDelegate() {
return delegate;
}
synchronized Map<String, Long> getOperationsCount() {
return org.opensearch.common.collect.Map.copyOf(operationCount);
}
protected synchronized void trackRequest(final String requestType) {
operationCount.put(requestType, operationCount.getOrDefault(requestType, 0L) + 1);
}
@Override
public void handle(HttpExchange exchange) throws IOException {
final String request = exchange.getRequestMethod() + " " + exchange.getRequestURI().toString();
maybeTrack(request, exchange.getRequestHeaders());
delegate.handle(exchange);
}
/**
* Tracks the given request if it matches the criteria.
*
* The request is represented as:
* Request = Method SP Request-URI
*
* @param request the request to be tracked if it matches the criteria
* @param requestHeaders the http request headers
*/
protected abstract void maybeTrack(String request, Headers requestHeaders);
}
/**
* Wrap a {@link HttpHandler} to log any thrown exception using the given {@link Logger}.
*/
public static DelegatingHttpHandler wrap(final HttpHandler handler, final Logger logger) {
return new ExceptionCatchingHttpHandler(handler, logger);
}
@SuppressForbidden(reason = "this test uses a HttpServer to emulate a cloud-based storage service")
private static class ExceptionCatchingHttpHandler implements DelegatingHttpHandler {
private final HttpHandler handler;
private final Logger logger;
ExceptionCatchingHttpHandler(HttpHandler handler, Logger logger) {
this.handler = handler;
this.logger = logger;
}
@Override
public void handle(HttpExchange exchange) throws IOException {
try {
handler.handle(exchange);
} catch (Throwable t) {
logger.error(
() -> new ParameterizedMessage(
"Exception when handling request {} {} {}",
exchange.getRemoteAddress(),
exchange.getRequestMethod(),
exchange.getRequestURI()
),
t
);
throw t;
}
}
@Override
public HttpHandler getDelegate() {
return handler;
}
}
}
|
3e075e6216b1bc724b86e02621f913b2d5c59ae7
| 177 |
java
|
Java
|
common/src/main/java/ru/medisov/home_finance/common/model/SimpleModel.java
|
fmedisov/homefinance
|
d62a14404fc6d16aec250579f400a903d4ba79fc
|
[
"MIT"
] | null | null | null |
common/src/main/java/ru/medisov/home_finance/common/model/SimpleModel.java
|
fmedisov/homefinance
|
d62a14404fc6d16aec250579f400a903d4ba79fc
|
[
"MIT"
] | null | null | null |
common/src/main/java/ru/medisov/home_finance/common/model/SimpleModel.java
|
fmedisov/homefinance
|
d62a14404fc6d16aec250579f400a903d4ba79fc
|
[
"MIT"
] | null | null | null | 13.615385 | 45 | 0.666667 | 3,121 |
package ru.medisov.home_finance.common.model;
public interface SimpleModel<T> {
T setId(Long Id);
Long getId();
T setName(String name);
String getName();
}
|
3e075e88d39c804ac0c84d9bc48f6ba5c78bcdac
| 50 |
java
|
Java
|
src/com/duiyi/dao/Dao.java
|
que2017/Estore
|
4bfa163fb93b3eeb9d65d97028e8743a6a180a9c
|
[
"Apache-2.0"
] | null | null | null |
src/com/duiyi/dao/Dao.java
|
que2017/Estore
|
4bfa163fb93b3eeb9d65d97028e8743a6a180a9c
|
[
"Apache-2.0"
] | null | null | null |
src/com/duiyi/dao/Dao.java
|
que2017/Estore
|
4bfa163fb93b3eeb9d65d97028e8743a6a180a9c
|
[
"Apache-2.0"
] | null | null | null | 8.333333 | 22 | 0.72 | 3,122 |
package com.duiyi.dao;
public interface Dao {
}
|
3e0760080c4bef96a8710c451f43906248480965
| 3,363 |
java
|
Java
|
ActivityLauncher/src/main/java/com/knziha/polymer/browser/BlockingDlgs.java
|
simonbellu/PolymPic
|
6e809d98b9a571b1833e55dfa5e9e4c34d7a727b
|
[
"Apache-2.0"
] | 23 |
2020-11-24T08:05:36.000Z
|
2022-03-25T07:46:40.000Z
|
ActivityLauncher/src/main/java/com/knziha/polymer/browser/BlockingDlgs.java
|
simonbellu/PolymPic
|
6e809d98b9a571b1833e55dfa5e9e4c34d7a727b
|
[
"Apache-2.0"
] | 4 |
2020-12-04T09:24:46.000Z
|
2022-02-17T12:13:50.000Z
|
ActivityLauncher/src/main/java/com/knziha/polymer/browser/BlockingDlgs.java
|
simonbellu/PolymPic
|
6e809d98b9a571b1833e55dfa5e9e4c34d7a727b
|
[
"Apache-2.0"
] | 8 |
2020-11-11T12:08:43.000Z
|
2022-03-11T13:37:36.000Z
| 34.670103 | 229 | 0.696699 | 3,123 |
package com.knziha.polymer.browser;
import android.content.DialogInterface;
import android.os.Bundle;
import android.provider.Contacts;
import android.widget.Button;
import androidx.appcompat.app.AlertDialog;
import com.knziha.polymer.BrowserActivity;
import com.knziha.polymer.Utils.CMN;
import com.knziha.polymer.Utils.IU;
import org.xwalk.core.XWalkActivityDelegate;
import org.xwalk.core.XWalkUpdater;
public class BlockingDlgs {
public static void blameNoSpace(BrowserActivity a, Bundle savedInstanceState) {
new AlertDialog.Builder(a)
.setTitle("启动出错")
.setMessage("存储空间已满,无法打开数据库,请清理后重试。")
.setPositiveButton("重试", (dialog, which) -> {
if(a.mXWalkDelegate!=null) {
((XWalkActivityDelegate)a.mXWalkDelegate).onResume();
}
a.further_loading(savedInstanceState);
})
.setCancelable(false)
.show();
}
public static boolean initXWalk(BrowserActivity a, Bundle savedInstanceState) {
if(a.mXWalkDelegate==null) {
Runnable completeCommand = () -> a.further_loading(savedInstanceState);
try {
a.mXWalkDelegate = new XWalkActivityDelegate(a, completeCommand, completeCommand);
((XWalkActivityDelegate)a.mXWalkDelegate).onResume();
return true;
} catch (Exception e) {
CMN.Log(e);
a.setWebType(0);
}
}
return false;
}
public static void blameNoWebView(BrowserActivity a, Bundle savedInstanceState) {
AlertDialog d = new AlertDialog.Builder(a)
.setTitle("启动出错")
.setMessage("无法初始化 WebView,请确保已安装正确的 WebView.apk !")
.setNeutralButton("切换 WEBVIEW 实现", null)
.setPositiveButton("重试", (dialog, which) -> a.further_loading(savedInstanceState))
.setCancelable(false)
.show();
d.getButton(DialogInterface.BUTTON_NEUTRAL).setOnClickListener(v -> {
showSwitchWebViewDlg(a);
});
}
public static void showSwitchWebViewDlg(BrowserActivity a) {
int type = a.getWebType();
DialogInterface.OnClickListener swDecorator = (dialog, which) -> {
CMN.Log("setSingleChoiceItems!!!");
AlertDialog d11 = (AlertDialog) dialog;
Button btn = d11.getButton(DialogInterface.BUTTON_NEUTRAL);
btn.setText(which==0?"安装":which==1?"卸载":"下载");
d11.tag = which;
};
AlertDialog d1 = new AlertDialog.Builder(a)
.setTitle("切换 WEBVIEW 实现")
.setPositiveButton("确认", (dialog, which) -> a.opt.putWebType(a.setWebType(IU.parsint(((AlertDialog)dialog).tag))))
.setNeutralButton("ASD", null)
.setSingleChoiceItems(new String[]{"系统 WebView", "X5 WebView", "CrossWalk"}, type, swDecorator)
.show();
swDecorator.onClick(d1, type);
d1.getButton(DialogInterface.BUTTON_NEUTRAL).setOnClickListener(v1 -> {
int sw = IU.parsint(d1.tag);
if(sw==1) {
// todo 卸载 x5
} else {
//mWebListener.showT("下载完成", "查看", "history");
new AlertDialog.Builder(a)
.setTitle("下载"+" "+(sw==0?"WebView":"CrossWalk"))
.setPositiveButton("取消", (dialog, which) -> { })
.setSingleChoiceItems(new String[]{"前往系统应用市场", "直接下载"}, 0, (dialog, which) -> {
if(which==0) {
new XWalkUpdater(null, a).downloadXWalkApk(sw==0);
} else {
a.showDownloadDialog("https://dl-tc.coolapkmarket.com/down/apk_file/2021/0225/Coolapk-11.0.2-2102251-coolapk-app-sign.apk?t=1614418511&sign=e6fb10501eb137949c3746674b76918b", 0, "application/vnd.android.package-archive");
}
})
.show();
}
});
}
}
|
3e0760309db5dc879baad01ec4fdb00a63d00dbb
| 1,437 |
java
|
Java
|
kie-wb-common-forms/kie-wb-common-forms-core/kie-wb-common-forms-fields/src/test/java/org/kie/workbench/common/forms/fields/shared/fieldTypes/basic/slider/definition/DoubleSliderDefinitionTest.java
|
alepintus/kie-wb-common
|
52f4225b6fa54d04435c8f5f59bee5894af23b7e
|
[
"Apache-2.0"
] | 34 |
2017-05-21T11:28:40.000Z
|
2021-07-03T13:15:03.000Z
|
kie-wb-common-forms/kie-wb-common-forms-core/kie-wb-common-forms-fields/src/test/java/org/kie/workbench/common/forms/fields/shared/fieldTypes/basic/slider/definition/DoubleSliderDefinitionTest.java
|
alepintus/kie-wb-common
|
52f4225b6fa54d04435c8f5f59bee5894af23b7e
|
[
"Apache-2.0"
] | 2,576 |
2017-03-14T00:57:07.000Z
|
2022-03-29T07:52:38.000Z
|
kie-wb-common-forms/kie-wb-common-forms-core/kie-wb-common-forms-fields/src/test/java/org/kie/workbench/common/forms/fields/shared/fieldTypes/basic/slider/definition/DoubleSliderDefinitionTest.java
|
alepintus/kie-wb-common
|
52f4225b6fa54d04435c8f5f59bee5894af23b7e
|
[
"Apache-2.0"
] | 158 |
2017-03-15T08:55:40.000Z
|
2021-11-19T14:07:17.000Z
| 35.925 | 101 | 0.755741 | 3,124 |
/*
* Copyright 2017 Red Hat, Inc. and/or its affiliates.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.kie.workbench.common.forms.fields.shared.fieldTypes.basic.slider.definition;
import org.kie.workbench.common.forms.fields.shared.fieldTypes.AbstractFieldDefinitionTest;
public class DoubleSliderDefinitionTest extends AbstractFieldDefinitionTest<DoubleSliderDefinition> {
@Override
protected DoubleSliderDefinition getEmptyFieldDefinition() {
return new DoubleSliderDefinition();
}
@Override
protected DoubleSliderDefinition getFullFieldDefinition() {
DoubleSliderDefinition doubleSliderDefinition = new DoubleSliderDefinition();
doubleSliderDefinition.setMin(-5.3);
doubleSliderDefinition.setMax(25.8);
doubleSliderDefinition.setStep(1.23);
doubleSliderDefinition.setPrecision(2.0);
return doubleSliderDefinition;
}
}
|
3e07608981a6b611145397307228ffd341daf2ae
| 8,660 |
java
|
Java
|
app/src/main/java/com/st/st25nfc/type5/st25dv/ST25DVChangePwdActivity.java
|
tcrct/nfc_rfid
|
552a344669ae00b82826843bcc3465558c17658d
|
[
"MIT"
] | null | null | null |
app/src/main/java/com/st/st25nfc/type5/st25dv/ST25DVChangePwdActivity.java
|
tcrct/nfc_rfid
|
552a344669ae00b82826843bcc3465558c17658d
|
[
"MIT"
] | null | null | null |
app/src/main/java/com/st/st25nfc/type5/st25dv/ST25DVChangePwdActivity.java
|
tcrct/nfc_rfid
|
552a344669ae00b82826843bcc3465558c17658d
|
[
"MIT"
] | null | null | null | 38.660714 | 175 | 0.677483 | 3,125 |
/*
* @author STMicroelectronics MMY Application team
*
******************************************************************************
* @attention
*
* <h2><center>© COPYRIGHT 2017 STMicroelectronics</center></h2>
*
* Licensed under ST MIX_MYLIBERTY SOFTWARE LICENSE AGREEMENT (the "License");
* You may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.st.com/Mix_MyLiberty
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied,
* AND SPECIFICALLY DISCLAIMING THE IMPLIED WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
* See the License for the specific language governing permissions and
* limitations under the License.
*
******************************************************************************
*/
package com.st.st25nfc.type5.st25dv;
import android.os.Bundle;
import android.os.Handler;
import android.support.design.widget.NavigationView;
import android.support.v4.app.FragmentManager;
import android.support.v4.widget.DrawerLayout;
import android.support.v7.app.ActionBarDrawerToggle;
import android.support.v7.widget.Toolbar;
import android.util.Log;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.widget.Button;
import android.widget.FrameLayout;
import android.widget.RadioButton;
import com.st.st25nfc.R;
import com.st.st25nfc.generic.MainActivity;
import com.st.st25nfc.generic.PwdDialogFragment;
import com.st.st25nfc.generic.ST25Menu;
import com.st.st25nfc.generic.STFragmentActivity;
import com.st.st25nfc.generic.STType5PwdDialogFragment;
import com.st.st25sdk.type5.ST25DVTag;
public class ST25DVChangePwdActivity extends STFragmentActivity implements STType5PwdDialogFragment.STType5PwdDialogListener, NavigationView.OnNavigationItemSelectedListener {
// Set here the Toolbar to use for this activity
private int toolbar_res = R.menu.toolbar_empty;
static final String TAG = "ST25DVChangePwdActivity";
private ST25DVTag myTag;
private Handler mHandler;
FragmentManager mFragmentManager;
STType5PwdDialogFragment.STPwdAction mCurrentAction;
RadioButton mPassword1RadioButton;
RadioButton mPassword2RadioButton;
RadioButton mPassword3RadioButton;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.default_layout);
// Inflate content of FrameLayout
FrameLayout frameLayout=(FrameLayout) findViewById(R.id.frame_content);
View childView = getLayoutInflater().inflate(R.layout.fragment_st25dv_change_password, null);
frameLayout.addView(childView);
myTag = (ST25DVTag) MainActivity.getTag();
mHandler = new Handler();
mFragmentManager = getSupportFragmentManager();
Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer);
ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(
this, drawer, toolbar, R.string.navigation_drawer_open, R.string.navigation_drawer_close);
drawer.setDrawerListener(toggle);
toggle.syncState();
mMenu = ST25Menu.newInstance(super.getTag());
NavigationView navigationView = (NavigationView) findViewById(R.id.navigation_view);
navigationView.setNavigationItemSelectedListener(this);
mMenu.inflateMenu(navigationView);
RadioButton password1RadioButton = (RadioButton) findViewById(R.id.password1RadioButton);
password1RadioButton.setChecked(true);
Button updateTagButton = (Button) findViewById(R.id.updateTagButton);
updateTagButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
enterOldPassword();
}
});
}
@Override
public void onResume() {
super.onResume();
getCurrentMemoryConf();
}
/**
* Get current memory configuration.
*/
private void getCurrentMemoryConf() {
mPassword1RadioButton = (RadioButton) findViewById(R.id.password1RadioButton);
displayAreaRadioButton(true, mPassword1RadioButton);
mPassword1RadioButton.setChecked(true);
mPassword2RadioButton = (RadioButton) findViewById(R.id.password2RadioButton);
displayAreaRadioButton(true, mPassword1RadioButton);
mPassword3RadioButton = (RadioButton) findViewById(R.id.password3RadioButton);
displayAreaRadioButton(true, mPassword1RadioButton);
}
private void displayAreaRadioButton(boolean display, RadioButton rb) {
if (!display) {
rb.setClickable(false);
rb.setTextColor(getResources().getColor(R.color.st_middle_grey));
} else {
rb.setClickable(true);
rb.setTextColor(getResources().getColor(R.color.st_dark_blue));
}
}
@Override
public boolean onCreateOptionsMenu(Menu menu) {
// Inflate the menu; this adds read_list_items to the action bar if it is present.
getMenuInflater().inflate(toolbar_res, menu);
return true;
}
@Override
public boolean onOptionsItemSelected(MenuItem item) {
// Handle action bar item clicks here. The action bar will
// automatically handle clicks on the Home/Up button, so long
// as you specify a parent activity in AndroidManifest.xml.
return super.onOptionsItemSelected(item);
}
private byte getSelectedPassword() {
byte pwd = -1;
if (mPassword1RadioButton.isChecked()) return ST25DVTag.ST25DV_PASSWORD_1;
if (mPassword2RadioButton.isChecked()) return ST25DVTag.ST25DV_PASSWORD_2;
if (mPassword3RadioButton.isChecked()) return ST25DVTag.ST25DV_PASSWORD_3;
return pwd;
}
private String getSelectedMessagePassword() {
String message ="";
if (mPassword1RadioButton.isChecked()) return message = getResources().getString(R.string.password1);
if (mPassword2RadioButton.isChecked()) return message = getResources().getString(R.string.password2);
if (mPassword3RadioButton.isChecked()) return message = getResources().getString(R.string.password3);
return message;
}
private void enterOldPassword() {
new Thread(new Runnable() {
public void run() {
byte passwordNumber = (byte) getSelectedPassword();
String message = "Please enter current " +getSelectedMessagePassword();
Log.v(TAG, "enterOldPassword");
mCurrentAction = STType5PwdDialogFragment.STPwdAction.PRESENT_CURRENT_PWD;
STType5PwdDialogFragment pwdDialogFragment = STType5PwdDialogFragment.newInstance(mCurrentAction, passwordNumber, message);
pwdDialogFragment.show(mFragmentManager, "pwdDialogFragment");
}
}).start();
}
private void enterNewPassword() {
new Thread(new Runnable() {
public void run() {
byte passwordNumber = (byte) getSelectedPassword();
String message = "Please enter new " +getSelectedMessagePassword();
Log.v(TAG, "enterNewPassword");
mCurrentAction = STType5PwdDialogFragment.STPwdAction.ENTER_NEW_PWD;
STType5PwdDialogFragment pwdDialogFragment = STType5PwdDialogFragment.newInstance(mCurrentAction, passwordNumber, message);
pwdDialogFragment.show(mFragmentManager, "pwdDialogFragment");
}
}).start();
}
public void onSTType5PwdDialogFinish(int result) {
Log.v(TAG, "onSTType5PwdDialogFinish. result = " + result);
if (result == PwdDialogFragment.RESULT_OK) {
switch (mCurrentAction) {
case PRESENT_CURRENT_PWD:
// Old password entered successfully
// We can now enter the new password
enterNewPassword();
break;
case ENTER_NEW_PWD:
showToast(R.string.change_pwd_succeeded);
break;
}
} else {
Log.e(TAG, "Action failed! Tag not updated!");
}
}
@Override
public boolean onNavigationItemSelected(MenuItem item) {
return mMenu.selectItem(this, item);
}
}
|
3e0761ee5fe9f050e3f5e8b78ed68700866ae6b7
| 380 |
java
|
Java
|
src/main/java/com/berry/oss/module/mo/MakeUpForLostDataMo.java
|
HarLin97/oss-backend
|
72cde03d17795b32ad2e59e11b03da21cb63ac84
|
[
"MIT"
] | 45 |
2019-06-30T10:08:16.000Z
|
2022-01-25T04:13:03.000Z
|
src/main/java/com/berry/oss/module/mo/MakeUpForLostDataMo.java
|
HarLin97/oss-backend
|
72cde03d17795b32ad2e59e11b03da21cb63ac84
|
[
"MIT"
] | 3 |
2019-12-04T11:01:22.000Z
|
2021-04-27T00:10:43.000Z
|
src/main/java/com/berry/oss/module/mo/MakeUpForLostDataMo.java
|
HarLin97/oss-backend
|
72cde03d17795b32ad2e59e11b03da21cb63ac84
|
[
"MIT"
] | 23 |
2019-11-27T02:00:21.000Z
|
2021-12-22T09:15:39.000Z
| 15.2 | 45 | 0.705263 | 3,126 |
package com.berry.oss.module.mo;
import lombok.Data;
import javax.validation.constraints.NotBlank;
/**
* Created with IntelliJ IDEA.
*
* @author Berry_Cooper.
* @version 1.0
* @date 2020/3/2 21:27
* fileName:MakeUpForLostDataMo
* Use:
*/
@Data
public class MakeUpForLostDataMo {
@NotBlank
private String fileName;
@NotBlank
private String filePath;
}
|
3e07621328c2f2bb9d76762972e089ec51c0db21
| 2,928 |
java
|
Java
|
src/test/java/uk/gov/cslearning/record/api/EventRegistrationsControllerTest.java
|
Civil-Service-Human-Resources/lpg-learner-record
|
7fa3ed5dbfc35e08e82578ec0197cfc006ad28f1
|
[
"MIT"
] | null | null | null |
src/test/java/uk/gov/cslearning/record/api/EventRegistrationsControllerTest.java
|
Civil-Service-Human-Resources/lpg-learner-record
|
7fa3ed5dbfc35e08e82578ec0197cfc006ad28f1
|
[
"MIT"
] | 23 |
2018-06-06T15:09:21.000Z
|
2021-10-04T09:53:40.000Z
|
src/test/java/uk/gov/cslearning/record/api/EventRegistrationsControllerTest.java
|
Civil-Service-Human-Resources/lpg-learner-record
|
7fa3ed5dbfc35e08e82578ec0197cfc006ad28f1
|
[
"MIT"
] | 1 |
2019-01-22T12:38:10.000Z
|
2019-01-22T12:38:10.000Z
| 38.025974 | 90 | 0.670765 | 3,127 |
package uk.gov.cslearning.record.api;
import org.junit.Before;
import org.junit.Test;
import org.mockito.InjectMocks;
import org.mockito.Mock;
import org.springframework.http.MediaType;
import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.request.MockMvcRequestBuilders;
import uk.gov.cslearning.record.repository.CourseRecordRepository;
import static org.mockito.Mockito.when;
import static org.mockito.MockitoAnnotations.initMocks;
import static org.springframework.test.web.servlet.result.MockMvcResultHandlers.print;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.jsonPath;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import static org.springframework.test.web.servlet.setup.MockMvcBuilders.standaloneSetup;
public class EventRegistrationsControllerTest {
private MockMvc mockMvc;
@InjectMocks
private EventRegistrationsController controller;
@Mock
private CourseRecordRepository courseRecordRepository;
@Before
public void setup() {
initMocks(this);
mockMvc = standaloneSetup(controller).build();
}
@Test
public void shouldReturnZeroIfNoRegistrations() throws Exception {
mockMvc.perform(
MockMvcRequestBuilders.get("/registrations/count?eventId=abc")
.accept(MediaType.APPLICATION_JSON))
.andDo(print())
.andExpect(status().isOk())
.andExpect(jsonPath("$[0].eventId").value("abc"))
.andExpect(jsonPath("$[0].value").value(0));
}
@Test
public void shouldReturnCountValue() throws Exception {
when(courseRecordRepository.countRegisteredForEvent("abc")).thenReturn(5);
mockMvc.perform(
MockMvcRequestBuilders.get("/registrations/count?eventId=abc")
.accept(MediaType.APPLICATION_JSON))
.andDo(print())
.andExpect(status().isOk())
.andExpect(jsonPath("$[0].eventId").value("abc"))
.andExpect(jsonPath("$[0].value").value(5));
}
@Test
public void shouldReturnMultipleCountValues() throws Exception {
when(courseRecordRepository.countRegisteredForEvent("abc")).thenReturn(5);
when(courseRecordRepository.countRegisteredForEvent("def")).thenReturn(0);
mockMvc.perform(
MockMvcRequestBuilders.get("/registrations/count?eventId=abc&eventId=def")
.accept(MediaType.APPLICATION_JSON))
.andDo(print())
.andExpect(status().isOk())
.andExpect(jsonPath("$[0].eventId").value("abc"))
.andExpect(jsonPath("$[0].value").value(5))
.andExpect(jsonPath("$[1].eventId").value("def"))
.andExpect(jsonPath("$[1].value").value(0));
}
}
|
3e0762b0a364d891a41f45e8489c71808a654760
| 851 |
java
|
Java
|
gmall-pms/src/main/java/com/ketai/gmall/pms/service/AttrGroupService.java
|
qy83yxy/gmall
|
9e40fd07326b0d8dfba5a47b00173b40affa978d
|
[
"Apache-2.0"
] | null | null | null |
gmall-pms/src/main/java/com/ketai/gmall/pms/service/AttrGroupService.java
|
qy83yxy/gmall
|
9e40fd07326b0d8dfba5a47b00173b40affa978d
|
[
"Apache-2.0"
] | 1 |
2021-04-22T17:06:46.000Z
|
2021-04-22T17:06:46.000Z
|
gmall-pms/src/main/java/com/ketai/gmall/pms/service/AttrGroupService.java
|
qy83yxy/gmall
|
9e40fd07326b0d8dfba5a47b00173b40affa978d
|
[
"Apache-2.0"
] | null | null | null | 20.261905 | 69 | 0.710928 | 3,128 |
package com.ketai.gmall.pms.service;
import com.atguigu.core.bean.PageVo;
import com.atguigu.core.bean.QueryCondition;
import com.baomidou.mybatisplus.extension.service.IService;
import com.ketai.gmall.pms.entity.AttrGroupEntity;
import com.ketai.gmall.pms.vo.ListGroupAndAttrById;
import com.ketai.gmall.pms.vo.ListGroupById;
/**
* 属性分组
*
* @author yuxingyou
* @email [email protected]
* @date 2020-04-14 10:06:35
*/
public interface AttrGroupService extends IService<AttrGroupEntity> {
/**
* 分组查询
*
* @param params
* @return
*/
PageVo queryPage(QueryCondition params);
/**
* 查询属性分组
*
* @param groupById
* @return
*/
PageVo listGroupById(ListGroupById groupById);
/**
* 查询组及组的规格参数
*
* @param attrGroupId
* @return
*/
ListGroupAndAttrById listGroupAndAttrById(Integer attrGroupId);
}
|
3e0762b0b6b01b943ae93d5e150517edf140721d
| 1,531 |
java
|
Java
|
src/jvm/storm/crawler/filter/URLFilter.java
|
skalmadka/web-crawler
|
694b8a8ab7bd80192b020e6a7c821d69e1d62902
|
[
"MIT"
] | 11 |
2015-05-08T14:58:36.000Z
|
2021-04-14T00:03:51.000Z
|
src/jvm/storm/crawler/filter/URLFilter.java
|
skalmadka/web-crawler
|
694b8a8ab7bd80192b020e6a7c821d69e1d62902
|
[
"MIT"
] | 1 |
2015-04-21T02:43:13.000Z
|
2015-04-22T22:13:47.000Z
|
src/jvm/storm/crawler/filter/URLFilter.java
|
skalmadka/web-crawler
|
694b8a8ab7bd80192b020e6a7c821d69e1d62902
|
[
"MIT"
] | 5 |
2015-04-22T21:40:55.000Z
|
2020-02-19T18:09:59.000Z
| 38.275 | 143 | 0.615284 | 3,129 |
package storm.crawler.filter;
import storm.crawler.CrawlerConfig;
import storm.crawler.filter.bloomfilter.RedisBloomFilter;
import storm.trident.operation.BaseFilter;
import storm.trident.operation.TridentOperationContext;
import storm.trident.tuple.TridentTuple;
import java.util.Map;
/**
* Created by Sunil Kalmadka on 4/5/2015.
*/
public class URLFilter extends BaseFilter {
private RedisBloomFilter<String> bloomFilter;
@Override
public void prepare(Map conf, TridentOperationContext context) {
bloomFilter = new RedisBloomFilter<String>(Integer.parseInt(conf.get(CrawlerConfig.BLOOM_FILTER_EXPECTED_ELEMENT_COUNT).toString()),
Double.parseDouble(conf.get(CrawlerConfig.BLOOM_FILTER_DESIRED_FALSE_POSITIVE).toString()),
conf.get(CrawlerConfig.REDIS_HOST_NAME).toString(),
Short.parseShort(conf.get(CrawlerConfig.REDIS_HOST_PORT).toString()),
conf.get(CrawlerConfig.BLOOM_FILTER_NAME).toString()
);
}
@Override
public boolean isKeep(TridentTuple tridentTuple) {
String url = tridentTuple.getString(0);
if (bloomFilter.exists(url)) {
//System.out.println("----- BloomFilter reject (URL exists):" + url);
return false;
}
bloomFilter.add(url);
return true;
}
}
|
3e07645e910c5f5679d77e673b3acfca3c996c96
| 459 |
java
|
Java
|
app/src/main/java/com/rarepep8/coursem8/CourseDetailActivity.java
|
RarePep8/CourseM8
|
e448a56462403a4520059304c0e6a726bc0eab3c
|
[
"MIT"
] | 1 |
2017-10-27T02:03:20.000Z
|
2017-10-27T02:03:20.000Z
|
app/src/main/java/com/rarepep8/coursem8/CourseDetailActivity.java
|
RarePep8/CourseM8
|
e448a56462403a4520059304c0e6a726bc0eab3c
|
[
"MIT"
] | null | null | null |
app/src/main/java/com/rarepep8/coursem8/CourseDetailActivity.java
|
RarePep8/CourseM8
|
e448a56462403a4520059304c0e6a726bc0eab3c
|
[
"MIT"
] | 2 |
2017-10-25T13:18:23.000Z
|
2019-01-11T01:37:20.000Z
| 22.95 | 61 | 0.718954 | 3,130 |
package com.rarepep8.coursem8;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
public class CourseDetailActivity extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_course_detail);
}
@Override
public void onBackPressed(){
super.onBackPressed();
this.finish();
}
}
|
3e07663a839152be1ec6efb304106694e8b00df5
| 1,390 |
java
|
Java
|
src/main/java/com/hedera/hashgraph/sdk/file/FileInfo.java
|
DSMatusevich/hedera-sdk-java
|
76b0605e5a909f1af1fc42ed78b880eef3fee18a
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/com/hedera/hashgraph/sdk/file/FileInfo.java
|
DSMatusevich/hedera-sdk-java
|
76b0605e5a909f1af1fc42ed78b880eef3fee18a
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/com/hedera/hashgraph/sdk/file/FileInfo.java
|
DSMatusevich/hedera-sdk-java
|
76b0605e5a909f1af1fc42ed78b880eef3fee18a
|
[
"Apache-2.0"
] | 1 |
2019-07-12T00:08:47.000Z
|
2019-07-12T00:08:47.000Z
| 33.902439 | 109 | 0.699281 | 3,131 |
package com.hedera.hashgraph.sdk.file;
import com.hedera.hashgraph.proto.FileGetInfoResponse;
import com.hedera.hashgraph.proto.Response;
import com.hedera.hashgraph.sdk.TimestampHelper;
import com.hedera.hashgraph.sdk.crypto.PublicKey;
import java.time.Instant;
import java.util.List;
import java.util.stream.Collectors;
public final class FileInfo {
public final FileId fileId;
public final long size;
public final Instant expirationTime;
public final boolean isDeleted;
public final List<PublicKey> keys;
FileInfo(FileGetInfoResponse.FileInfoOrBuilder info) {
if (!info.hasKeys() || info.getKeys().getKeysList().isEmpty()) {
throw new IllegalArgumentException("`FileGetInfoResponse` missing keys");
}
fileId = new FileId(info.getFileIDOrBuilder());
size = info.getSize();
expirationTime = TimestampHelper.timestampTo(info.getExpirationTime());
isDeleted = info.getDeleted();
keys = info.getKeys()
.getKeysList()
.stream()
.map(PublicKey::fromProtoKey)
.collect(Collectors.toList());
}
static FileInfo fromResponse(Response response) {
if (!response.hasFileGetInfo()) throw new IllegalArgumentException("response was not `fileGetInfo`");
return new FileInfo(response.getFileGetInfo().getFileInfoOrBuilder());
}
}
|
3e0766b002c4a91dce1b59a6a7fc2d9a0ebd2542
| 549 |
java
|
Java
|
mall-tiny-plus/src/main/java/com/macro/mall/tiny/modules/pms/service/impl/PmsBrandServiceImpl.java
|
yItblack/mall-learning
|
2fb2654dd8793959631ebc0497b516fb4d14c85d
|
[
"Apache-2.0"
] | 11,548 |
2019-05-04T08:04:24.000Z
|
2022-03-31T13:26:13.000Z
|
mall-tiny-plus/src/main/java/com/macro/mall/tiny/modules/pms/service/impl/PmsBrandServiceImpl.java
|
yItblack/mall-learning
|
2fb2654dd8793959631ebc0497b516fb4d14c85d
|
[
"Apache-2.0"
] | 109 |
2019-05-29T01:47:50.000Z
|
2022-03-30T06:30:45.000Z
|
mall-tiny-plus/src/main/java/com/macro/mall/tiny/modules/pms/service/impl/PmsBrandServiceImpl.java
|
yItblack/mall-learning
|
2fb2654dd8793959631ebc0497b516fb4d14c85d
|
[
"Apache-2.0"
] | 8,242 |
2019-05-04T14:36:02.000Z
|
2022-03-31T15:35:21.000Z
| 26.142857 | 107 | 0.785064 | 3,132 |
package com.macro.mall.tiny.modules.pms.service.impl;
import com.macro.mall.tiny.modules.pms.model.PmsBrand;
import com.macro.mall.tiny.modules.pms.mapper.PmsBrandMapper;
import com.macro.mall.tiny.modules.pms.service.PmsBrandService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;
/**
* <p>
* 品牌表 服务实现类
* </p>
*
* @author macro
* @since 2020-08-20
*/
@Service
public class PmsBrandServiceImpl extends ServiceImpl<PmsBrandMapper, PmsBrand> implements PmsBrandService {
}
|
3e076706af92e677a3bf3725cd73756604fd850e
| 1,980 |
java
|
Java
|
src/main/java/codechef/GravityGuy.java
|
harishsharma/junk
|
70d92242d18b54bbe2faa0957af88db0addebfed
|
[
"Apache-2.0"
] | 1 |
2021-12-01T21:01:35.000Z
|
2021-12-01T21:01:35.000Z
|
src/main/java/codechef/GravityGuy.java
|
harishsharma/junk
|
70d92242d18b54bbe2faa0957af88db0addebfed
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/codechef/GravityGuy.java
|
harishsharma/junk
|
70d92242d18b54bbe2faa0957af88db0addebfed
|
[
"Apache-2.0"
] | null | null | null | 25.714286 | 64 | 0.40101 | 3,133 |
package codechef;
import java.util.Scanner;
/**
* https://www.codechef.com/AUG15/problems/GRGUY
*
* @author harish.sharma
*
*/
class GravityGuy {
public static void main(String[] arg) {
Scanner in = new Scanner(System.in);
int n = in.nextInt();
for (int i = 0; i < n; i++) {
String line1 = in.next();
char[] chars1 = line1.toCharArray();
String line2 = in.next();
char[] chars2 = line2.toCharArray();
solve(chars1, chars2);
}
in.close();
}
private static void solve(char[] chars1, char[] chars2) {
int len = chars1.length;
for (int i = 0; i < len; i++) {
if (chars1[i] == '#' && chars2[i] == '#') {
System.out.println("No");
return;
}
}
System.out.println("Yes");
int jc1 = 0, jc2 = 0;
if (chars1[0] == '.') {
jc1 = jumpCount(chars1, chars2);
}
if (chars2[0] == '.') {
jc2 = jumpCount(chars2, chars1);
}
int jc = 0;
if (jc1 == 0)
jc = jc2;
else if (jc2 == 0)
jc = jc1;
else {
jc = Math.min(jc1, jc2);
}
System.out.println(jc);
}
private static int jumpCount(char[] chars1, char[] chars2) {
int len = chars1.length;
int jumpCount1 = 0;
boolean sw = true;
for (int i = 1; i < len; i++) {
if (sw) {
if (chars1[i] == '.')
continue;
else if (chars1[i] == '#') {
jumpCount1++;
sw = false;
}
} else {
if (chars2[i] == '.')
continue;
else if (chars2[i] == '#') {
jumpCount1++;
sw = true;
}
}
}
return jumpCount1;
}
}
|
3e076848f124d3550134ae86e4807c9df9e95983
| 3,783 |
java
|
Java
|
micronaut-util/src/main/java/io/micronaut/util/Strings.java
|
hixuym/micronaut-extras
|
a4e0fc6dc0f882dcade98cd5739ae6698d994740
|
[
"Apache-2.0"
] | 2 |
2019-02-21T09:26:21.000Z
|
2019-08-01T10:45:24.000Z
|
micronaut-util/src/main/java/io/micronaut/util/Strings.java
|
hixuym/micronaut-extras
|
a4e0fc6dc0f882dcade98cd5739ae6698d994740
|
[
"Apache-2.0"
] | null | null | null |
micronaut-util/src/main/java/io/micronaut/util/Strings.java
|
hixuym/micronaut-extras
|
a4e0fc6dc0f882dcade98cd5739ae6698d994740
|
[
"Apache-2.0"
] | null | null | null | 37.088235 | 102 | 0.637325 | 3,134 |
/*
* Copyright 2017-2019 original authors
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
package io.micronaut.util;
import javax.annotation.Nullable;
import static java.util.Objects.requireNonNull;
public final class Strings {
private Strings() {
}
/**
* Returns the given string if it is non-null; the empty string otherwise.
*
* @param string the string to test and possibly return
* @return {@code string} itself if it is non-null; {@code ""} if it is null
*/
public static String nullToEmpty(@Nullable String string) {
return (string == null) ? "" : string;
}
/**
* Returns the given string if it is nonempty; {@code null} otherwise.
*
* @param string the string to test and possibly return
* @return {@code string} itself if it is nonempty; {@code null} if it is empty or null
*/
@Nullable
public static String emptyToNull(@Nullable String string) {
return isNullOrEmpty(string) ? null : string;
}
/**
* Returns {@code true} if the given string is null or is the empty string.
*
* <p>Consider normalizing your string references with {@link #nullToEmpty}. If you do, you can
* use {@link String#isEmpty()} instead of this method, and you won't need special null-safe forms
* of methods like {@link String#toUpperCase} either. Or, if you'd like to normalize "in the other
* direction," converting empty strings to {@code null}, you can use {@link #emptyToNull}.
*
* @param string a string reference to check
* @return {@code true} if the string is null or is the empty string
*/
public static boolean isNullOrEmpty(@Nullable String string) {
return string == null || string.isEmpty();
}
/**
* Returns a string consisting of a specific number of concatenated copies of an input string. For
* example, {@code repeat("hey", 3)} returns the string {@code "heyheyhey"}.
*
* @param string any non-null string
* @param count the number of times to repeat it; a nonnegative integer
* @return a string containing {@code string} repeated {@code count} times (the empty string if
* {@code count} is zero)
* @throws IllegalArgumentException if {@code count} is negative
*/
public static String repeat(String string, int count) {
requireNonNull(string);
if (count <= 1) {
if (count < 0) {
throw new IllegalArgumentException("invalid count: " + count);
}
return (count == 0) ? "" : string;
}
// IF YOU MODIFY THE CODE HERE, you must update StringsRepeatBenchmark
final int len = string.length();
final long longSize = (long) len * (long) count;
final int size = (int) longSize;
if (size != longSize) {
throw new ArrayIndexOutOfBoundsException("Required array size too large: " + longSize);
}
final char[] array = new char[size];
string.getChars(0, len, array, 0);
int n;
for (n = len; n < size - n; n <<= 1) {
System.arraycopy(array, 0, array, n, n);
}
System.arraycopy(array, 0, array, n, size - n);
return new String(array);
}
}
|
3e0768ae25ae97c54d20ec2524f20ec9269ccfb8
| 1,145 |
java
|
Java
|
Ghidra/Framework/Docking/src/main/java/docking/DockingCheckBoxMenuItem.java
|
0x6d696368/ghidra
|
91e4fd7fb7e00a970c8f35f05c4590133937e174
|
[
"Apache-2.0"
] | 3 |
2019-11-14T13:11:35.000Z
|
2019-12-02T20:51:49.000Z
|
Ghidra/Framework/Docking/src/main/java/docking/DockingCheckBoxMenuItem.java
|
BStudent/ghidra
|
0cdc722921cef61b7ca1b7236bdc21079fd4c03e
|
[
"Apache-2.0"
] | 3 |
2019-07-17T22:51:04.000Z
|
2019-12-04T05:43:56.000Z
|
Ghidra/Framework/Docking/src/main/java/docking/DockingCheckBoxMenuItem.java
|
BStudent/ghidra
|
0cdc722921cef61b7ca1b7236bdc21079fd4c03e
|
[
"Apache-2.0"
] | 3 |
2019-12-02T13:36:50.000Z
|
2019-12-04T05:40:12.000Z
| 30.945946 | 96 | 0.762445 | 3,135 |
/* ###
* IP: GHIDRA
* REVIEWED: YES
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package docking;
import java.awt.event.KeyEvent;
import javax.swing.JCheckBoxMenuItem;
import javax.swing.KeyStroke;
import docking.menu.DockingCheckboxMenuItemUI;
public class DockingCheckBoxMenuItem extends JCheckBoxMenuItem {
public DockingCheckBoxMenuItem(boolean isSelected) {
setUI(DockingCheckboxMenuItemUI.createUI(this));
setSelected(isSelected);
}
@Override
protected boolean processKeyBinding(KeyStroke ks, KeyEvent e, int condition, boolean pressed) {
return true; // we will take care of the action ourselves
}
}
|
3e076a3dbb712691bff029b782bdf7eacbe5a7da
| 1,370 |
java
|
Java
|
SampleLibSpring/src/com/cwj/genesis/bean_manager/xml/declare/Book.java
|
YannisCheng/NoahArkA
|
44eb8845d8b7272ad01d257b7d1dfc68aa86572a
|
[
"Apache-2.0"
] | null | null | null |
SampleLibSpring/src/com/cwj/genesis/bean_manager/xml/declare/Book.java
|
YannisCheng/NoahArkA
|
44eb8845d8b7272ad01d257b7d1dfc68aa86572a
|
[
"Apache-2.0"
] | null | null | null |
SampleLibSpring/src/com/cwj/genesis/bean_manager/xml/declare/Book.java
|
YannisCheng/NoahArkA
|
44eb8845d8b7272ad01d257b7d1dfc68aa86572a
|
[
"Apache-2.0"
] | null | null | null | 21.375 | 79 | 0.508041 | 3,136 |
package com.cwj.genesis.bean_manager.xml.declare;
/**
* com.cwj.genesis
*
* @author ChengWenjia [email protected]
* @date 2021-05-25 15:53
*/
public class Book {
private String name;
private int price;
private String address;
private String out;
private String out2;
public Book(String address) {
this.address = address;
}
public void setName(String name) {
this.name = name;
}
public void setPrice(int price) {
this.price = price;
}
public void setOut(String out) {
System.out.println("out is : " + out);
}
public void setOut2(String out2) {
this.out2 = out2;
}
public void showMeteData() {
System.out.println("book name is : " + name + ", price is : " + price);
}
public void showAddress() {
System.out.println("Address is : " + address);
}
public void showOut(){
System.out.println("out is : " + out);
}
public void showOut2(){
System.out.println("out2 is : " + out2);
}
/*@Override
public String toString() {
return "Book{" +
"name='" + name + '\'' +
", price=" + price +
", address='" + address + '\'' +
", out='" + out + '\'' +
", out2='" + out2 + '\'' +
'}';
}*/
}
|
3e076a7be0dd5f660a231b89327f53210a4b35e8
| 999 |
java
|
Java
|
src/main/java/slimeknights/tconstruct/tools/modifiers/traits/NecroticModifier.java
|
Snivyer1910/TinkersConstruct
|
4063714f8496b4b233485e475c804133c5085a81
|
[
"MIT"
] | 23 |
2021-04-08T23:31:54.000Z
|
2022-03-18T14:02:31.000Z
|
src/main/java/slimeknights/tconstruct/tools/modifiers/traits/NecroticModifier.java
|
Snivyer1910/TinkersConstruct
|
4063714f8496b4b233485e475c804133c5085a81
|
[
"MIT"
] | 1 |
2021-07-26T21:19:03.000Z
|
2021-07-26T21:19:03.000Z
|
src/main/java/slimeknights/tconstruct/tools/modifiers/traits/NecroticModifier.java
|
Snivyer1910/TinkersConstruct
|
4063714f8496b4b233485e475c804133c5085a81
|
[
"MIT"
] | 5 |
2021-04-07T23:41:31.000Z
|
2021-12-03T05:31:26.000Z
| 37 | 170 | 0.747748 | 3,137 |
package slimeknights.tconstruct.tools.modifiers.traits;
import net.minecraft.entity.LivingEntity;
import net.minecraft.sound.SoundCategory;
import net.minecraft.sound.SoundEvents;
import slimeknights.tconstruct.library.modifiers.Modifier;
import slimeknights.tconstruct.library.tools.nbt.IModifierToolStack;
public class NecroticModifier extends Modifier {
public NecroticModifier() {
super(0x4D4D4D);
}
@Override
public int afterLivingHit(IModifierToolStack tool, int level, LivingEntity attacker, LivingEntity target, float damageDealt, boolean isCritical, boolean fullyCharged) {
if (fullyCharged && damageDealt > 0) {
// every level gives a +10% chance of healing you 10%
if (attacker.getRandom().nextFloat() < level * 0.1) {
attacker.heal(0.1f * damageDealt);
attacker.world.playSound(null, attacker.getX(), attacker.getY(), attacker.getZ(), SoundEvents.ENTITY_ZOMBIE_INFECT, SoundCategory.PLAYERS, 1.0f, 1.0f);
}
}
return 0;
}
}
|
3e076bce686a91972acba1b1685ad08fecafbb5f
| 3,041 |
java
|
Java
|
build/tmp/expandedArchives/forge-1.18.1-39.0.40_mapped_parchment_2021.12.19-1.18.1-sources.jar_8da1e53bade44c6d138d26d6ab1ad1d3/net/minecraft/client/model/ShulkerModel.java
|
LX-s-Team/CookingLevel-Forge
|
065ddf23d2efb4f44e0e494fb3b2cbef47b7cca5
|
[
"MIT"
] | null | null | null |
build/tmp/expandedArchives/forge-1.18.1-39.0.40_mapped_parchment_2021.12.19-1.18.1-sources.jar_8da1e53bade44c6d138d26d6ab1ad1d3/net/minecraft/client/model/ShulkerModel.java
|
LX-s-Team/CookingLevel-Forge
|
065ddf23d2efb4f44e0e494fb3b2cbef47b7cca5
|
[
"MIT"
] | null | null | null |
build/tmp/expandedArchives/forge-1.18.1-39.0.40_mapped_parchment_2021.12.19-1.18.1-sources.jar_8da1e53bade44c6d138d26d6ab1ad1d3/net/minecraft/client/model/ShulkerModel.java
|
LX-s-Team/CookingLevel-Forge
|
065ddf23d2efb4f44e0e494fb3b2cbef47b7cca5
|
[
"MIT"
] | null | null | null | 41.094595 | 172 | 0.690233 | 3,138 |
package net.minecraft.client.model;
import com.google.common.collect.ImmutableList;
import net.minecraft.client.model.geom.ModelPart;
import net.minecraft.client.model.geom.PartPose;
import net.minecraft.client.model.geom.builders.CubeListBuilder;
import net.minecraft.client.model.geom.builders.LayerDefinition;
import net.minecraft.client.model.geom.builders.MeshDefinition;
import net.minecraft.client.model.geom.builders.PartDefinition;
import net.minecraft.client.renderer.RenderType;
import net.minecraft.util.Mth;
import net.minecraft.world.entity.monster.Shulker;
import net.minecraftforge.api.distmarker.Dist;
import net.minecraftforge.api.distmarker.OnlyIn;
@OnlyIn(Dist.CLIENT)
public class ShulkerModel<T extends Shulker> extends ListModel<T> {
private static final String LID = "lid";
private static final String BASE = "base";
private final ModelPart base;
private final ModelPart lid;
private final ModelPart head;
public ShulkerModel(ModelPart pRoot) {
super(RenderType::entityCutoutNoCullZOffset);
this.lid = pRoot.getChild("lid");
this.base = pRoot.getChild("base");
this.head = pRoot.getChild("head");
}
public static LayerDefinition createBodyLayer() {
MeshDefinition meshdefinition = new MeshDefinition();
PartDefinition partdefinition = meshdefinition.getRoot();
partdefinition.addOrReplaceChild("lid", CubeListBuilder.create().texOffs(0, 0).addBox(-8.0F, -16.0F, -8.0F, 16.0F, 12.0F, 16.0F), PartPose.offset(0.0F, 24.0F, 0.0F));
partdefinition.addOrReplaceChild("base", CubeListBuilder.create().texOffs(0, 28).addBox(-8.0F, -8.0F, -8.0F, 16.0F, 8.0F, 16.0F), PartPose.offset(0.0F, 24.0F, 0.0F));
partdefinition.addOrReplaceChild("head", CubeListBuilder.create().texOffs(0, 52).addBox(-3.0F, 0.0F, -3.0F, 6.0F, 6.0F, 6.0F), PartPose.offset(0.0F, 12.0F, 0.0F));
return LayerDefinition.create(meshdefinition, 64, 64);
}
/**
* Sets this entity's model rotation angles
*/
public void setupAnim(T pEntity, float pLimbSwing, float pLimbSwingAmount, float pAgeInTicks, float pNetHeadYaw, float pHeadPitch) {
float f = pAgeInTicks - (float)pEntity.tickCount;
float f1 = (0.5F + pEntity.getClientPeekAmount(f)) * (float)Math.PI;
float f2 = -1.0F + Mth.sin(f1);
float f3 = 0.0F;
if (f1 > (float)Math.PI) {
f3 = Mth.sin(pAgeInTicks * 0.1F) * 0.7F;
}
this.lid.setPos(0.0F, 16.0F + Mth.sin(f1) * 8.0F + f3, 0.0F);
if (pEntity.getClientPeekAmount(f) > 0.3F) {
this.lid.yRot = f2 * f2 * f2 * f2 * (float)Math.PI * 0.125F;
} else {
this.lid.yRot = 0.0F;
}
this.head.xRot = pHeadPitch * ((float)Math.PI / 180F);
this.head.yRot = (pEntity.yHeadRot - 180.0F - pEntity.yBodyRot) * ((float)Math.PI / 180F);
}
public Iterable<ModelPart> parts() {
return ImmutableList.of(this.base, this.lid);
}
public ModelPart getLid() {
return this.lid;
}
public ModelPart getHead() {
return this.head;
}
}
|
3e076c8b9167434c2c3e81356258620871cb1158
| 1,106 |
java
|
Java
|
hl7-messaging/src/main/java/gov/vha/isaac/ochre/services/exception/STSException.java
|
cngshow/isaac
|
27ed40ff1eeb73c83c25fb799b7b172ac928d609
|
[
"Apache-2.0"
] | null | null | null |
hl7-messaging/src/main/java/gov/vha/isaac/ochre/services/exception/STSException.java
|
cngshow/isaac
|
27ed40ff1eeb73c83c25fb799b7b172ac928d609
|
[
"Apache-2.0"
] | null | null | null |
hl7-messaging/src/main/java/gov/vha/isaac/ochre/services/exception/STSException.java
|
cngshow/isaac
|
27ed40ff1eeb73c83c25fb799b7b172ac928d609
|
[
"Apache-2.0"
] | null | null | null | 27.65 | 76 | 0.710669 | 3,139 |
/**
* Copyright Notice
*
* This is a work of the U.S. Government and is not subject to copyright
* protection in the United States. Foreign copyrights may apply.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package gov.vha.isaac.ochre.services.exception;
public class STSException extends Exception
{
public STSException() {
super();
}
public STSException(String message) {
super(message);
}
public STSException(Throwable cause) {
super(cause);
}
public STSException(String message, Throwable cause) {
super(message, cause);
}
}
|
3e076ce4c992f737aecc1a2a69f0e5a5bbefcfb1
| 2,345 |
java
|
Java
|
src/main/java/com/chipkillmar/validatorexample/DemoApplication.java
|
chipkillmar/validator-example
|
bde5f5d10de33a88872e3b7efed5f9d5ad46a3eb
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/com/chipkillmar/validatorexample/DemoApplication.java
|
chipkillmar/validator-example
|
bde5f5d10de33a88872e3b7efed5f9d5ad46a3eb
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/com/chipkillmar/validatorexample/DemoApplication.java
|
chipkillmar/validator-example
|
bde5f5d10de33a88872e3b7efed5f9d5ad46a3eb
|
[
"Apache-2.0"
] | null | null | null | 40.431034 | 120 | 0.76162 | 3,140 |
package com.chipkillmar.validatorexample;
import lombok.Data;
import org.hibernate.validator.HibernateValidatorConfiguration;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;
import org.springframework.validation.beanvalidation.LocalValidatorFactoryBean;
import javax.validation.ClockProvider;
import javax.validation.Configuration;
import java.time.Clock;
/**
* Spring Boot 2 application that demonstrates how to customize the Hibernate Validator. Specifically, this example
* configures a {@link ClockProvider}, and sets the {@code hibernate.validator.temporal_validation_tolerance} property,
* which allows for a margin of error when validating temporal constraints such as
* {@link javax.validation.constraints.Past}, {@link javax.validation.constraints.PastOrPresent},
* {@link javax.validation.constraints.Future}, and {@link javax.validation.constraints.FutureOrPresent}.
*
* @see HibernateValidatorConfiguration#TEMPORAL_VALIDATION_TOLERANCE
* @see <a href="https://docs.jboss.org/hibernate/stable/validator/reference/en-US/html_single/#section-clock-provider">
* 9.2.5. ClockProvider and temporal validation tolerance</a>
*/
@SpringBootApplication
@Data
public class DemoApplication {
/**
* Tolerance for temporal bean validation annotations such as {@link javax.validation.constraints.Past}.
*/
@Value("${hibernate.validator.temporal_validation_tolerance:60000}")
private int temporalValidationTolerance;
@Bean
public LocalValidatorFactoryBean localValidatorFactoryBean() {
return new LocalValidatorFactoryBean() {
@Override
protected void postProcessConfiguration(Configuration<?> configuration) {
configuration.clockProvider(clockProvider());
configuration.addProperty(HibernateValidatorConfiguration.TEMPORAL_VALIDATION_TOLERANCE,
String.valueOf(temporalValidationTolerance));
}
};
}
@Bean
public ClockProvider clockProvider() {
return Clock::systemUTC;
}
public static void main(String[] args) {
SpringApplication.run(DemoApplication.class, args);
}
}
|
3e076debe62303d0e564b35cda0da7729dec8d80
| 925 |
java
|
Java
|
b2/src/main/java/org/oscelot/jshack/security/BbSessionTokenService.java
|
AllTheDucks/jshack
|
6a860cfa088a390c802efce0c099501cf81dceba
|
[
"BSD-3-Clause"
] | 15 |
2015-02-11T06:29:13.000Z
|
2021-04-06T19:19:43.000Z
|
b2/src/main/java/org/oscelot/jshack/security/BbSessionTokenService.java
|
AllTheDucks/jshack
|
6a860cfa088a390c802efce0c099501cf81dceba
|
[
"BSD-3-Clause"
] | 4 |
2017-03-01T05:43:54.000Z
|
2020-06-29T06:24:06.000Z
|
b2/src/main/java/org/oscelot/jshack/security/BbSessionTokenService.java
|
AllTheDucks/jshack
|
6a860cfa088a390c802efce0c099501cf81dceba
|
[
"BSD-3-Clause"
] | 2 |
2018-06-18T14:31:28.000Z
|
2019-02-06T15:26:40.000Z
| 24.342105 | 81 | 0.661622 | 3,141 |
package org.oscelot.jshack.security;
import blackboard.platform.context.Context;
import blackboard.platform.context.ContextManagerFactory;
import blackboard.platform.session.BbSession;
/**
* Created by shane on 17/11/2015.
*/
public class BbSessionTokenService implements TokenService {
@Override
public String generateToken() {
return getSessionId();
}
@Override
public boolean validateToken(String token) {
final String sessionId = getSessionId();
return sessionId != null && sessionId.equals(token);
}
private String getSessionId() {
final Context context = ContextManagerFactory.getInstance().getContext();
if(context == null) {
return null;
}
final BbSession session = context.getSession();
if(session == null) {
return null;
}
return session.getBbSecureSessionIdMd5();
}
}
|
3e076e8857257606ac83ad9bf8340b69f2c7b7fb
| 1,297 |
java
|
Java
|
src/test/java/org/springframework/samples/petclinic/web/CrashControllerTests.java
|
gii-is-psg2/PSG2-2021-G6-62
|
62ced2d3b09bdf1f5ac84a6ebf88fac9eba98f32
|
[
"Apache-2.0"
] | null | null | null |
src/test/java/org/springframework/samples/petclinic/web/CrashControllerTests.java
|
gii-is-psg2/PSG2-2021-G6-62
|
62ced2d3b09bdf1f5ac84a6ebf88fac9eba98f32
|
[
"Apache-2.0"
] | 106 |
2021-03-11T11:13:47.000Z
|
2021-05-31T16:04:37.000Z
|
src/test/java/org/springframework/samples/petclinic/web/CrashControllerTests.java
|
gii-is-psg2/PSG2-2021-G6-62
|
62ced2d3b09bdf1f5ac84a6ebf88fac9eba98f32
|
[
"Apache-2.0"
] | null | null | null | 39.30303 | 114 | 0.812645 | 3,142 |
package org.springframework.samples.petclinic.web;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.autoconfigure.web.servlet.WebMvcTest;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.FilterType;
import org.springframework.samples.petclinic.configuration.SecurityConfiguration;
import org.springframework.security.config.annotation.web.WebSecurityConfigurer;
import org.springframework.security.test.context.support.WithMockUser;
import org.springframework.test.web.servlet.MockMvc;
@WebMvcTest(value = CrashController.class,
excludeFilters = @ComponentScan.Filter(type = FilterType.ASSIGNABLE_TYPE, classes = WebSecurityConfigurer.class),
excludeAutoConfiguration= SecurityConfiguration.class)
class CrashControllerTests {
@Autowired
private MockMvc mockMvc;
@WithMockUser(value = "spring")
@Test
void testProcessCreationFormSuccess() throws Exception {
mockMvc.perform(get("/oups"))
.andExpect(status().isOk());
}
}
|
3e076e8b207ddacf2985df9c4c0df1c3e05aa87b
| 569 |
java
|
Java
|
source/common/src/com/ocs/util/Pair.java
|
amida-tech/indaba
|
c41a237d9420231af7a119fee9ec7e77719accf0
|
[
"Apache-2.0"
] | 3 |
2016-02-25T00:12:36.000Z
|
2016-11-04T21:15:36.000Z
|
source/common/src/com/ocs/util/Pair.java
|
amida-tech/indaba
|
c41a237d9420231af7a119fee9ec7e77719accf0
|
[
"Apache-2.0"
] | null | null | null |
source/common/src/com/ocs/util/Pair.java
|
amida-tech/indaba
|
c41a237d9420231af7a119fee9ec7e77719accf0
|
[
"Apache-2.0"
] | 1 |
2017-08-25T19:12:19.000Z
|
2017-08-25T19:12:19.000Z
| 14.225 | 52 | 0.509666 | 3,143 |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.ocs.util;
/**
*
* @author Jeff Jiang
*/
public class Pair<K1, K2> {
private K1 k1 = null;
private K2 k2 = null;
public Pair() {
}
public Pair(K1 k1, K2 k2) {
this.k1 = k1;
this.k2 = k2;
}
public K1 getK1() {
return k1;
}
public void setK1(K1 k1) {
this.k1 = k1;
}
public K2 getK2() {
return k2;
}
public void setK2(K2 k2) {
this.k2 = k2;
}
}
|
3e076e95345ec60b38c51e263cfeec211d877b85
| 350 |
java
|
Java
|
jhipster/applications/livemap/src/main/java/com/doggynet/livemap/security/AuthoritiesConstants.java
|
LoopSun/doggy-net
|
dd374707be5f34ff112d436510b87a10fe7bb374
|
[
"MIT"
] | 1 |
2018-02-27T01:16:00.000Z
|
2018-02-27T01:16:00.000Z
|
jhipster/applications/livemap/src/main/java/com/doggynet/livemap/security/AuthoritiesConstants.java
|
LoopSun/doggy-net
|
dd374707be5f34ff112d436510b87a10fe7bb374
|
[
"MIT"
] | null | null | null |
jhipster/applications/livemap/src/main/java/com/doggynet/livemap/security/AuthoritiesConstants.java
|
LoopSun/doggy-net
|
dd374707be5f34ff112d436510b87a10fe7bb374
|
[
"MIT"
] | null | null | null | 20.588235 | 60 | 0.722857 | 3,144 |
package com.doggynet.livemap.security;
/**
* Constants for Spring Security authorities.
*/
public final class AuthoritiesConstants {
public static final String ADMIN = "ROLE_ADMIN";
public static final String USER = "ROLE_USER";
public static final String ANONYMOUS = "ROLE_ANONYMOUS";
private AuthoritiesConstants() {
}
}
|
3e076ecc6a45a7a3d2249155e52a4cfe2c7c2c66
| 1,904 |
java
|
Java
|
src/testcases/CWE80_XSS/s01/CWE80_XSS__CWE182_Servlet_getParameter_Servlet_52c.java
|
diktat-static-analysis/juliet-benchmark-java
|
7e55922d154c26ef34ff3327073f030ff7393b2a
|
[
"MIT"
] | null | null | null |
src/testcases/CWE80_XSS/s01/CWE80_XSS__CWE182_Servlet_getParameter_Servlet_52c.java
|
diktat-static-analysis/juliet-benchmark-java
|
7e55922d154c26ef34ff3327073f030ff7393b2a
|
[
"MIT"
] | null | null | null |
src/testcases/CWE80_XSS/s01/CWE80_XSS__CWE182_Servlet_getParameter_Servlet_52c.java
|
diktat-static-analysis/juliet-benchmark-java
|
7e55922d154c26ef34ff3327073f030ff7393b2a
|
[
"MIT"
] | null | null | null | 40.510638 | 217 | 0.706933 | 3,145 |
/* TEMPLATE GENERATED TESTCASE FILE
Filename: CWE80_XSS__CWE182_Servlet_getParameter_Servlet_52c.java
Label Definition File: CWE80_XSS__CWE182_Servlet.label.xml
Template File: sources-sink-52c.tmpl.java
*/
/*
* @description
* CWE: 80 Cross Site Scripting (XSS)
* BadSource: getParameter_Servlet Read data from a querystring using getParameter()
* GoodSource: A hardcoded string
* Sinks:
* BadSink : Display of data in web page after using replaceAll() to remove script tags, which will still allow XSS (CWE 182: Collapse of Data into Unsafe Value)
* Flow Variant: 52 Data flow: data passed as an argument from one method to another to another in three different classes in the same package
*
* */
package testcases.CWE80_XSS.s01;
import testcasesupport.*;
import javax.servlet.http.*;
public class CWE80_XSS__CWE182_Servlet_getParameter_Servlet_52c
{
public void badSink(String data , HttpServletRequest request, HttpServletResponse response) throws Throwable
{
if (data != null)
{
/* POTENTIAL FLAW: Display of data in web page after using replaceAll() to remove script tags, which will still allow XSS with strings like <scr<script>ipt> (CWE 182: Collapse of Data into Unsafe Value) */
response.getWriter().println("<br>bad(): data = " + data.replaceAll("(<script>)", ""));
}
}
/* goodG2B() - use goodsource and badsink */
public void goodG2BSink(String data , HttpServletRequest request, HttpServletResponse response) throws Throwable
{
if (data != null)
{
/* POTENTIAL FLAW: Display of data in web page after using replaceAll() to remove script tags, which will still allow XSS with strings like <scr<script>ipt> (CWE 182: Collapse of Data into Unsafe Value) */
response.getWriter().println("<br>bad(): data = " + data.replaceAll("(<script>)", ""));
}
}
}
|
3e076f5dd82de3f19407dde507801a4e07ca5b80
| 2,977 |
java
|
Java
|
runners/google-cloud-dataflow-java/worker/src/main/java/org/apache/beam/runners/dataflow/worker/util/common/worker/WorkExecutor.java
|
Snowflake-Labs/beam
|
9317462f73cd3aeb42145ba41ba3b1ef0f72674b
|
[
"PSF-2.0",
"Apache-2.0",
"BSD-3-Clause"
] | 5,279 |
2016-12-29T04:00:44.000Z
|
2022-03-31T22:56:45.000Z
|
runners/google-cloud-dataflow-java/worker/src/main/java/org/apache/beam/runners/dataflow/worker/util/common/worker/WorkExecutor.java
|
robinyqiu/beam
|
21ffad3ea0a398376bfa17b746a38db0df97a84a
|
[
"Apache-2.0"
] | 14,149 |
2016-12-28T00:43:50.000Z
|
2022-03-31T23:50:22.000Z
|
runners/google-cloud-dataflow-java/worker/src/main/java/org/apache/beam/runners/dataflow/worker/util/common/worker/WorkExecutor.java
|
robinyqiu/beam
|
21ffad3ea0a398376bfa17b746a38db0df97a84a
|
[
"Apache-2.0"
] | 3,763 |
2016-12-29T04:06:10.000Z
|
2022-03-31T22:25:49.000Z
| 35.023529 | 98 | 0.735976 | 3,146 |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.beam.runners.dataflow.worker.util.common.worker;
import java.util.List;
import org.apache.beam.runners.dataflow.worker.counters.CounterSet;
import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.collect.Lists;
import org.checkerframework.checker.nullness.qual.Nullable;
/** Abstract executor for WorkItem tasks. */
@SuppressWarnings({
"nullness" // TODO(https://issues.apache.org/jira/browse/BEAM-10402)
})
public interface WorkExecutor extends AutoCloseable {
/** Returns the set of output counters for this task. */
CounterSet getOutputCounters();
/** Executes the task. */
public abstract void execute() throws Exception;
/**
* Returns the worker's current progress.
*
* <p>May be called at any time, but generally called concurrently to execute().
*/
default NativeReader.Progress getWorkerProgress() throws Exception {
// By default, return null indicating worker progress not available.
return null;
}
/** See {@link NativeReader.NativeReaderIterator#requestCheckpoint}. */
default NativeReader.@Nullable DynamicSplitResult requestCheckpoint() throws Exception {
// By default, checkpointing does nothing.
return null;
}
/**
* See {@link NativeReader.NativeReaderIterator#requestDynamicSplit}. Makes sense only for tasks
* that read input.
*/
default NativeReader.@Nullable DynamicSplitResult requestDynamicSplit(
NativeReader.DynamicSplitRequest splitRequest) throws Exception {
// By default, dynamic splitting is unsupported.
return null;
}
@Override
default void close() throws Exception {
// By default, nothing to close or shut down.
}
/**
* Requests that the executor abort as soon as possible.
*
* <p>Thread-safe. May be called at any time after execute() begins.
*/
default void abort() {
// By default, does nothing. Expensive operations should override this.
}
/**
* Reports the sink index of any WriteOperation that did not produce output. NOTE this is only
* used for FlumeWriteOperaton for now.
*/
default List<Integer> reportProducedEmptyOutput() {
return Lists.newArrayList();
}
}
|
3e076f847e9025958f6ceb1269cad837c0064b0a
| 677 |
java
|
Java
|
java-project/src/main/java/com/github/mahui53541/graduation/vo/ThanksLetterVO.java
|
mahuiplus/graduation-project
|
88d67e387527c6b846179b6d27b949a42617ad26
|
[
"Unlicense"
] | 1 |
2021-06-17T06:13:47.000Z
|
2021-06-17T06:13:47.000Z
|
java-project/src/main/java/com/github/mahui53541/graduation/vo/ThanksLetterVO.java
|
mahuiplus/graduation-project
|
88d67e387527c6b846179b6d27b949a42617ad26
|
[
"Unlicense"
] | null | null | null |
java-project/src/main/java/com/github/mahui53541/graduation/vo/ThanksLetterVO.java
|
mahuiplus/graduation-project
|
88d67e387527c6b846179b6d27b949a42617ad26
|
[
"Unlicense"
] | null | null | null | 18.805556 | 59 | 0.679468 | 3,147 |
package com.github.mahui53541.graduation.vo;
import com.github.mahui53541.graduation.model.ThanksLetter;
/**
* java类简单作用描述
*
* @Description: java类作用描述
* @Author: MaHui
* @CreateDate: 2018/5/11 12:40
* @Version: 1.0
*/
public class ThanksLetterVO extends ThanksLetter {
private String editorName;
private String thanksName;
public String getEditorName() {
return editorName;
}
public void setEditorName(String editorName) {
this.editorName = editorName;
}
public String getThanksName() {
return thanksName;
}
public void setThanksName(String thanksName) {
this.thanksName = thanksName;
}
}
|
3e076fa254dc6b04eb5debae0e63edd8013c934a
| 10,862 |
java
|
Java
|
sofpro/src/main/java/com/ucap/gecs/component/netdisclosure/SltGecsDisclosureRecord.java
|
roginluo/information-computing-science
|
cfcf34a14bb6a2541cdd1cc2651c6f7a288eb2d7
|
[
"Apache-2.0"
] | null | null | null |
sofpro/src/main/java/com/ucap/gecs/component/netdisclosure/SltGecsDisclosureRecord.java
|
roginluo/information-computing-science
|
cfcf34a14bb6a2541cdd1cc2651c6f7a288eb2d7
|
[
"Apache-2.0"
] | null | null | null |
sofpro/src/main/java/com/ucap/gecs/component/netdisclosure/SltGecsDisclosureRecord.java
|
roginluo/information-computing-science
|
cfcf34a14bb6a2541cdd1cc2651c6f7a288eb2d7
|
[
"Apache-2.0"
] | null | null | null | 58.085561 | 170 | 0.743233 | 3,148 |
// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.kpdus.com/jad.html
// Decompiler options: packimports(3)
// Source File Name: SltGecsDisclosureRecord.java
package com.ucap.gecs.component.netdisclosure;
import com.ucap.gecs.base.ecc.EccClass;
import com.ucap.gecs.base.global.*;
import java.io.PrintStream;
import java.util.ArrayList;
import java.util.StringTokenizer;
import javax.servlet.http.*;
// Referenced classes of package com.ucap.gecs.component.netdisclosure:
// EngGecsDisclosureRecord, ColGecsDisclosureRecords, ClsGecsDisclosureRecord
public class SltGecsDisclosureRecord extends SubHttpServlet
{
public SltGecsDisclosureRecord()
{
engGecsDisclosureRecord = new EngGecsDisclosureRecord();
LISTPAGE = "/gecs/netdisclosure/gecsdisclosurerecord_list.jsp";
EDITPAGE = "/gecs/netdisclosure/gecsdisclosurerecord_edit.jsp";
}
protected void doList(HttpServletRequest request, HttpServletResponse response, HttpSession session)
throws Exception
{
PageManager pageManager = null;
String keyword = request.getParameter("keyword") != null ? request.getParameter("keyword") : "";
pageManager = super.getPageManager(request, response);
com.ucap.gecs.base.global.OrderClass orderClass = getOrderClass(request, response);
GecsConfig gecsConfig = getGecsConfig(request, response, session);
if(Methods.getRequestStr(request, "GETSESSION").equals("1"))
{
pageManager = (PageManager)session.getAttribute("PageManager");
keyword = Methods.getStr((String)session.getAttribute("keyword"));
}
ColGecsDisclosureRecords colGecsDisclosureRecords = new ColGecsDisclosureRecords();
colGecsDisclosureRecords = (ColGecsDisclosureRecords)engGecsDisclosureRecord.getListCollection(keyword, pageManager, orderClass, gecsConfig);
request.setAttribute("ColGecsDisclosureRecords", colGecsDisclosureRecords);
request.setAttribute("PageManager", pageManager);
session.setAttribute("PageManager", pageManager);
request.setAttribute("keyword", keyword);
session.setAttribute("keyword", keyword);
request.setAttribute("OrderClass", orderClass);
go(request, response, session, LISTPAGE);
}
protected void doNew(HttpServletRequest request, HttpServletResponse response, HttpSession session)
throws Exception
{
ClsGecsDisclosureRecord clsGecsDisclosureRecord = new ClsGecsDisclosureRecord();
request.setAttribute("ClsGecsDisclosureRecord", clsGecsDisclosureRecord);
go(request, response, session, EDITPAGE);
}
protected void doEdit(HttpServletRequest request, HttpServletResponse response, HttpSession session)
throws Exception
{
ClsGecsDisclosureRecord tempclsGecsDisclosureRecord = (ClsGecsDisclosureRecord)getEccClass(request, response, session);
ClsGecsDisclosureRecord clsGecsDisclosureRecord = new ClsGecsDisclosureRecord();
String id = tempclsGecsDisclosureRecord.getDisclosurerecord_seq();
clsGecsDisclosureRecord = (ClsGecsDisclosureRecord)engGecsDisclosureRecord.getClass(id);
request.setAttribute("ClsGecsDisclosureRecord", clsGecsDisclosureRecord);
go(request, response, session, EDITPAGE);
}
protected void doAdd(HttpServletRequest request, HttpServletResponse response, HttpSession session)
throws Exception
{
ClsGecsDisclosureRecord clsGecsDisclosureRecord = (ClsGecsDisclosureRecord)getEccClass(request, response, session);
GecsConfig gecsConfig = getGecsConfig(request, response, session);
String tempSystemWebSite = gecsConfig.getGecsSystemWebSite();
String tempSystemDepart = gecsConfig.getGecsSystemDepart();
String tempUserid = gecsConfig.getUserID();
clsGecsDisclosureRecord.setDisclosurerecord_name(tempUserid);
clsGecsDisclosureRecord.setGecs_system_website(tempSystemWebSite);
clsGecsDisclosureRecord.setGecs_system_department(tempSystemDepart);
clsGecsDisclosureRecord.setDisclosurerecord_date(Methods.getSystemDateTime());
String MSG_CODE = "SUCCESS";
boolean flag = true;
flag = engGecsDisclosureRecord.insertItem(clsGecsDisclosureRecord);
String disclosurerecord_accept_name = request.getParameter("disclosurerecord_accept_name") != null ? request.getParameter("disclosurerecord_accept_name") : "";
String disclosurerecord_accept_email = request.getParameter("disclosurerecord_accept_email") != null ? request.getParameter("disclosurerecord_accept_email") : "";
StringTokenizer stringTokenizer_name = new StringTokenizer(disclosurerecord_accept_name, ";");
StringTokenizer stringTokenizer_email = new StringTokenizer(disclosurerecord_accept_email, ";");
String name[] = new String[stringTokenizer_name.countTokens()];
String receiverEmail[] = new String[stringTokenizer_name.countTokens()];
for(int i = 0; stringTokenizer_name.hasMoreElements(); i++)
{
String tempStr = (String)stringTokenizer_name.nextElement();
name[i] = (String)stringTokenizer_name.nextElement();
receiverEmail[i] = (String)stringTokenizer_email.nextElement();
}
SendMail sendMail = new SendMail();
String senderEmail = gecsConfig.getUserID();
String subject = clsGecsDisclosureRecord.getDisclosurerecord_subject();
String content = clsGecsDisclosureRecord.getDisclosurerecord_content();
ArrayList attachfile = new ArrayList();
System.out.println("[\u9359\u6226\u5056\u6D60\u5241\u6B91\u7EFE\u8DE8\u25BC]========================begin=========================");
sendMail.send(request, response, session, senderEmail, receiverEmail, subject, content, attachfile);
String returnurl = "/" + getWebSite(request) + "/SltGecsDisclosure?actiontype=LIST";
gotoMessage(request, response, session, MSG_CODE, returnurl);
}
protected void doUpdate(HttpServletRequest request, HttpServletResponse response, HttpSession session)
throws Exception
{
ClsGecsDisclosureRecord clsGecsDisclosureRecord = (ClsGecsDisclosureRecord)getEccClass(request, response, session);
String id = clsGecsDisclosureRecord.getDisclosurerecord_seq();
String MSG_CODE = "SUCCESS";
boolean flag = true;
flag = engGecsDisclosureRecord.modifyItem(clsGecsDisclosureRecord);
String returnurl = "/" + getWebSite(request) + "/SltGecsDisclosureRecord?actiontype=LIST&GETSESSION=1";
gotoMessage(request, response, session, MSG_CODE, returnurl);
}
protected void doDel(HttpServletRequest request, HttpServletResponse response, HttpSession session)
throws Exception
{
ClsGecsDisclosureRecord clsGecsDisclosureRecord = (ClsGecsDisclosureRecord)getEccClass(request, response, session);
String id = clsGecsDisclosureRecord.getDisclosurerecord_seq();
String MSG_CODE = "SUCCESS";
boolean flag = true;
flag = engGecsDisclosureRecord.deleteItem(id);
String returnurl = "/" + getWebSite(request) + "/SltGecsDisclosureRecord?actiontype=LIST";
gotoMessage(request, response, session, MSG_CODE, returnurl);
}
protected void doMutiDel(HttpServletRequest request, HttpServletResponse response, HttpSession session)
throws Exception
{
ArrayList ids = super.getMutiDelList(request, response, session);
boolean flag = true;
String MSG_CODE = "SUCCESS";
flag = engGecsDisclosureRecord.deleteMutiItem(ids);
String returnurl = "/" + getWebSite(request) + "/SltGecsDisclosureRecord?actiontype=LIST";
gotoMessage(request, response, session, MSG_CODE, returnurl);
}
protected EccClass getEccClass(HttpServletRequest request, HttpServletResponse response, HttpSession session)
throws Exception
{
ClsGecsDisclosureRecord clsGecsDisclosureRecord = new ClsGecsDisclosureRecord();
String disclosurerecord_date = request.getParameter("disclosurerecord_date") != null ? request.getParameter("disclosurerecord_date") : "";
String disclosurerecord_accept_name = request.getParameter("disclosurerecord_accept_name") != null ? request.getParameter("disclosurerecord_accept_name") : "";
String disclosurerecord_subject = request.getParameter("disclosurerecord_subject") != null ? request.getParameter("disclosurerecord_subject") : "";
String disclosurerecord_content = request.getParameter("disclosurerecord_content") != null ? request.getParameter("disclosurerecord_content") : "";
String gecs_system_website = request.getParameter("gecs_system_website") != null ? request.getParameter("gecs_system_website") : "";
String gecs_system_department = request.getParameter("gecs_system_department") != null ? request.getParameter("gecs_system_department") : "";
String disclosurerecord_accept_email = request.getParameter("disclosurerecord_accept_email") != null ? request.getParameter("disclosurerecord_accept_email") : "";
String disclosurerecord_seq = request.getParameter("disclosurerecord_seq") != null ? request.getParameter("disclosurerecord_seq") : "";
String disclosure_seq = request.getParameter("disclosure_seq") != null ? request.getParameter("disclosure_seq") : "";
String disclosurerecord_name = request.getParameter("disclosurerecord_name") != null ? request.getParameter("disclosurerecord_name") : "";
clsGecsDisclosureRecord.setDisclosurerecord_date(disclosurerecord_date);
clsGecsDisclosureRecord.setDisclosurerecord_accept_name(disclosurerecord_accept_name);
clsGecsDisclosureRecord.setDisclosurerecord_subject(disclosurerecord_subject);
clsGecsDisclosureRecord.setDisclosurerecord_content(disclosurerecord_content);
clsGecsDisclosureRecord.setGecs_system_website(gecs_system_website);
clsGecsDisclosureRecord.setGecs_system_department(gecs_system_department);
clsGecsDisclosureRecord.setDisclosurerecord_accept_email(disclosurerecord_accept_email);
clsGecsDisclosureRecord.setDisclosurerecord_seq(disclosurerecord_seq);
clsGecsDisclosureRecord.setDisclosure_seq(disclosure_seq);
clsGecsDisclosureRecord.setDisclosurerecord_name(disclosurerecord_name);
return clsGecsDisclosureRecord;
}
protected void doCustomize(HttpServletRequest request, HttpServletResponse response, HttpSession session, String actiontype)
throws Exception
{
if(actiontype.equals("PASS"))
doPass();
}
public void doPass()
{
}
EngGecsDisclosureRecord engGecsDisclosureRecord;
String LISTPAGE;
String EDITPAGE;
}
|
3e076fa29e848258cd0662a3b9612086eb5ed06d
| 5,302 |
java
|
Java
|
src/main/java/me/drex/itsours/claim/Subzone.java
|
PortableGames/ItsOurs
|
474ebbc73473354c15d813cb2602f47c61d8883e
|
[
"CC0-1.0"
] | null | null | null |
src/main/java/me/drex/itsours/claim/Subzone.java
|
PortableGames/ItsOurs
|
474ebbc73473354c15d813cb2602f47c61d8883e
|
[
"CC0-1.0"
] | 1 |
2021-12-15T23:47:06.000Z
|
2021-12-15T23:47:06.000Z
|
src/main/java/me/drex/itsours/claim/Subzone.java
|
PortableGames/ItsOurs
|
474ebbc73473354c15d813cb2602f47c61d8883e
|
[
"CC0-1.0"
] | 3 |
2020-09-12T19:03:12.000Z
|
2021-12-15T01:53:30.000Z
| 43.105691 | 358 | 0.654847 | 3,149 |
package me.drex.itsours.claim;
import com.mojang.brigadier.exceptions.CommandSyntaxException;
import com.mojang.brigadier.exceptions.SimpleCommandExceptionType;
import it.unimi.dsi.fastutil.objects.Object2IntMap;
import me.drex.itsours.ItsOursMod;
import me.drex.itsours.claim.permission.Permission;
import me.drex.itsours.claim.permission.roles.Role;
import me.drex.itsours.claim.permission.util.context.PermissionContext;
import me.drex.itsours.claim.permission.util.context.Priority;
import net.minecraft.nbt.NbtCompound;
import net.minecraft.server.world.ServerWorld;
import net.minecraft.text.LiteralText;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.Direction;
import java.util.Optional;
import java.util.UUID;
public class Subzone extends AbstractClaim {
final AbstractClaim parent;
public Subzone(String name, UUID owner, BlockPos min, BlockPos max, ServerWorld world, BlockPos tppos, AbstractClaim parent) {
super(name, owner, min, max, world, tppos);
//Make sure the parent isnt also in the subzone list (getDepth() would get an infinite loop)
this.parent = parent;
this.parent.addSubzone(this);
}
public Subzone(NbtCompound tag, AbstractClaim parent) {
super(tag);
this.parent = parent;
}
public AbstractClaim getParent() {
return this.parent;
}
@Override
public String getFullName() {
return parent.getFullName() + "." + getName();
}
@Override
protected PermissionContext getPermissionContext(UUID uuid, Permission permission) {
PermissionContext context = super.getPermissionContext(uuid, permission);
context.combine(parent.getPermissionContext(uuid, permission));
return context;
}
@Override
public Object2IntMap<Role> getRoles(UUID uuid) {
Object2IntMap<Role> roles = parent.getRoles(uuid);
for (Role role : getPermissionManager().getRemovedRoles(uuid)) {
roles.remove(role);
}
for (Object2IntMap.Entry<Role> entry : getPermissionManager().getRoles(uuid).object2IntEntrySet()) {
roles.put(entry.getKey(), entry.getIntValue());
}
return roles;
}
@Override
public boolean getSetting(String setting) {
Optional<Permission> optional = Permission.setting(setting);
if (optional.isPresent()) {
PermissionContext context = this.getPermissionManager().settings.getPermission(this, optional.get(), Priority.SETTING);
if (context.getValue() == Permission.Value.UNSET) {
return parent.getSetting(setting);
} else {
return false;
}
} else {
return false;
}
}
public int getDepth() {
return this.getParent().getDepth() + 1;
}
@Override
public int expand(UUID uuid, Direction direction, int amount) throws CommandSyntaxException {
int previousArea = this.getArea();
this.show(false);
this.expand(direction, amount);
int requiredBlocks = this.getArea() - previousArea;
if (!this.isInside()) {
this.undoExpand(direction, amount);
throw new SimpleCommandExceptionType(new LiteralText("Expansion would result in " + this.getName() + " being outside of " + this.parent.getName())).create();
}
Optional<AbstractClaim> optional = this.intersects();
if (optional.isPresent()) {
this.undoExpand(direction, amount);
throw new SimpleCommandExceptionType(new LiteralText("Expansion would result in hitting " + optional.get())).create();
}
if (this.max.getY() > this.getWorld().getTopY() || this.min.getY() < this.getWorld().getBottomY()) {
this.undoExpand(direction, amount);
throw new SimpleCommandExceptionType(new LiteralText("You can't expand outside of the world!")).create();
}
if (max.getX() < min.getX() || max.getY() < min.getY() || max.getZ() < min.getZ()) {
this.undoExpand(direction, amount);
throw new SimpleCommandExceptionType(new LiteralText("You can't shrink your claim that much")).create();
}
for (Subzone subzone : this.getSubzones()) {
if (!subzone.isInside()) {
this.undoExpand(direction, amount);
throw new SimpleCommandExceptionType(new LiteralText("Shrinking would result in " + subzone.getName() + " being outside of " + this.getName())).create();
}
}
this.show(true);
ItsOursMod.INSTANCE.getClaimList().update();
return requiredBlocks;
}
boolean isInside() {
BlockPos a = min, b = max, c = new BlockPos(max.getX(), min.getY(), min.getZ()), d = new BlockPos(min.getX(), max.getY(), min.getZ()), e = new BlockPos(min.getX(), min.getY(), max.getZ()), f = new BlockPos(max.getX(), max.getY(), min.getZ()), g = new BlockPos(max.getX(), min.getY(), max.getZ()), h = new BlockPos(min.getX(), max.getY(), max.getZ());
return this.parent.contains(a) && this.parent.contains(b) && this.parent.contains(c) && this.parent.contains(d) && this.parent.contains(e) && this.parent.contains(f) && this.parent.contains(g) && this.parent.contains(h);
}
}
|
3e076fb34633fb9d35ceda1042a91db35c2d20f9
| 1,027 |
java
|
Java
|
chapter_003/src/main/java/ru/pravvich/lesson_6/client/MoveFiles.java
|
triodjangopiter/junior
|
40c396684be847c3239fc448f21576ba6c56ca07
|
[
"Apache-2.0"
] | 1 |
2019-01-14T17:25:43.000Z
|
2019-01-14T17:25:43.000Z
|
chapter_003/src/main/java/ru/pravvich/lesson_6/client/MoveFiles.java
|
triodjangopiter/java-from-a-to-z
|
40c396684be847c3239fc448f21576ba6c56ca07
|
[
"Apache-2.0"
] | null | null | null |
chapter_003/src/main/java/ru/pravvich/lesson_6/client/MoveFiles.java
|
triodjangopiter/java-from-a-to-z
|
40c396684be847c3239fc448f21576ba6c56ca07
|
[
"Apache-2.0"
] | 1 |
2016-09-20T09:20:25.000Z
|
2016-09-20T09:20:25.000Z
| 25.675 | 111 | 0.550146 | 3,150 |
package ru.pravvich.lesson_6.client;
import java.io.File;
import java.io.IOException;
import java.nio.file.Files;
import static java.lang.String.format;
class MoveFiles {
static void copy(File source, String target) {
if (source.exists()) {
File dest = new File(target);
try {
if (Files.copy(source.toPath(), dest.toPath()).toFile().exists()) {
System.out.println(format("%s %s\n%s", source.getName(), "Успешно скопирован в:", target));
}
} catch (IOException e) {
e.printStackTrace();
}
} else {
System.err.println("Файл не существует.");
}
}
static void move(File source, String target) {
copy(source, target);
if (source.delete()) {
System.out.println(format("%s %s", source.getAbsolutePath(), "Успешно удален"));
} else {
System.out.println("Не удалось удалить оригинальный файл.");
}
}
}
|
3e076fb9190cfa602f13c937ebc1c7d8ff5ca981
| 405 |
java
|
Java
|
prescricao/src/main/java/br/com/basis/madre/prescricao/repository/search/ViasAdministracaoSearchRepository.java
|
BasisTI/madre
|
b856d26ecbb25b5ab3a3bffe97da0bd09b6985de
|
[
"CECILL-B"
] | 9 |
2019-10-09T15:48:37.000Z
|
2022-01-11T18:14:15.000Z
|
prescricao/src/main/java/br/com/basis/madre/prescricao/repository/search/ViasAdministracaoSearchRepository.java
|
BasisTI/madre
|
b856d26ecbb25b5ab3a3bffe97da0bd09b6985de
|
[
"CECILL-B"
] | 30 |
2020-03-11T12:05:35.000Z
|
2022-03-02T05:42:56.000Z
|
prescricao/src/main/java/br/com/basis/madre/prescricao/repository/search/ViasAdministracaoSearchRepository.java
|
BasisTI/madre
|
b856d26ecbb25b5ab3a3bffe97da0bd09b6985de
|
[
"CECILL-B"
] | 11 |
2020-08-15T15:44:48.000Z
|
2022-02-06T15:33:38.000Z
| 40.5 | 109 | 0.841975 | 3,151 |
package br.com.basis.madre.prescricao.repository.search;
import br.com.basis.madre.prescricao.domain.ViasAdministracao;
import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;
/**
* Spring Data Elasticsearch repository for the {@link ViasAdministracao} entity.
*/
public interface ViasAdministracaoSearchRepository extends ElasticsearchRepository<ViasAdministracao, Long> {
}
|
3e076fcdaba6409e3dbea0fc7e28d416e814b441
| 1,664 |
java
|
Java
|
src/org/openbravo/erpCommon/utility/PropertyConflictException.java
|
eid101/InjazErp
|
6d7c69a9d3a6023e093ab0d7b356983fdee1e4c8
|
[
"Apache-2.0"
] | null | null | null |
src/org/openbravo/erpCommon/utility/PropertyConflictException.java
|
eid101/InjazErp
|
6d7c69a9d3a6023e093ab0d7b356983fdee1e4c8
|
[
"Apache-2.0"
] | null | null | null |
src/org/openbravo/erpCommon/utility/PropertyConflictException.java
|
eid101/InjazErp
|
6d7c69a9d3a6023e093ab0d7b356983fdee1e4c8
|
[
"Apache-2.0"
] | null | null | null | 44.972973 | 96 | 0.686899 | 3,152 |
/*
*************************************************************************
* The contents of this file are subject to the Openbravo Public License
* Version 1.1 (the "License"), being the Mozilla Public License
* Version 1.1 with a permitted attribution clause; you may not use this
* file except in compliance with the License. You may obtain a copy of
* the License at http://www.openbravo.com/legal/license.html
* Software distributed under the License is distributed on an "AS IS"
* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
* License for the specific language governing rights and limitations
* under the License.
* The Original Code is Openbravo ERP.
* The Initial Developer of the Original Code is Openbravo SLU
* All portions are Copyright (C) 2010 Openbravo SLU
* All Rights Reserved.
* Contributor(s): ______________________________________.
************************************************************************
*/
package org.openbravo.erpCommon.utility;
import org.openbravo.erpCommon.businessUtility.Preferences;
/**
* Exception thrown when there are multiple preference values defined for the current visibility
* level.
*
* @see Preferences#getPreferenceValue(String, boolean, org.openbravo.model.ad.system.Client,
* org.openbravo.model.common.enterprise.Organization, org.openbravo.model.ad.access.User,
* org.openbravo.model.ad.access.Role, org.openbravo.model.ad.ui.Window)
* Preferences.getPreferenceValue
*
*/
public class PropertyConflictException extends PropertyException {
private static final long serialVersionUID = 1L;
}
|
3e0770b24821bb2a70174b1b13e5bf01abe53c19
| 199 |
java
|
Java
|
src/main/java/edu/tarleton/welborn/exceptions/PlayerAlreadyExistsInGameException.java
|
ewelborn/web-checkers
|
84197cdcbf9153af599bd015a1e17a84480a2fd6
|
[
"MIT"
] | null | null | null |
src/main/java/edu/tarleton/welborn/exceptions/PlayerAlreadyExistsInGameException.java
|
ewelborn/web-checkers
|
84197cdcbf9153af599bd015a1e17a84480a2fd6
|
[
"MIT"
] | null | null | null |
src/main/java/edu/tarleton/welborn/exceptions/PlayerAlreadyExistsInGameException.java
|
ewelborn/web-checkers
|
84197cdcbf9153af599bd015a1e17a84480a2fd6
|
[
"MIT"
] | null | null | null | 28.428571 | 68 | 0.748744 | 3,153 |
package edu.tarleton.welborn.exceptions;
public class PlayerAlreadyExistsInGameException extends Exception {
public PlayerAlreadyExistsInGameException(String s) {
super(s);
}
}
|
3e0770e63d87d3ca79c5b4ab817e48094ab31efd
| 638 |
java
|
Java
|
schemaOrgDomaConv/src/org/kyojo/schemaorg/m3n4/doma/core/container/ValueMinLengthConverter.java
|
nagaikenshin/schemaOrg
|
4c9d6d098a2741c2dc2a814f1c708ee55c36e9a8
|
[
"Apache-2.0"
] | 1 |
2020-02-18T01:55:36.000Z
|
2020-02-18T01:55:36.000Z
|
schemaOrgDomaConv/src/org/kyojo/schemaorg/m3n4/doma/core/container/ValueMinLengthConverter.java
|
nagaikenshin/schemaOrg
|
4c9d6d098a2741c2dc2a814f1c708ee55c36e9a8
|
[
"Apache-2.0"
] | null | null | null |
schemaOrgDomaConv/src/org/kyojo/schemaorg/m3n4/doma/core/container/ValueMinLengthConverter.java
|
nagaikenshin/schemaOrg
|
4c9d6d098a2741c2dc2a814f1c708ee55c36e9a8
|
[
"Apache-2.0"
] | null | null | null | 26.583333 | 93 | 0.822884 | 3,154 |
package org.kyojo.schemaorg.m3n4.doma.core.container;
import java.math.BigDecimal;
import org.seasar.doma.ExternalDomain;
import org.seasar.doma.jdbc.domain.DomainConverter;
import org.kyojo.schemaorg.m3n4.core.impl.VALUE_MIN_LENGTH;
import org.kyojo.schemaorg.m3n4.core.Container.ValueMinLength;
@ExternalDomain
public class ValueMinLengthConverter implements DomainConverter<ValueMinLength, BigDecimal> {
@Override
public BigDecimal fromDomainToValue(ValueMinLength domain) {
return domain.getNativeValue();
}
@Override
public ValueMinLength fromValueToDomain(BigDecimal value) {
return new VALUE_MIN_LENGTH(value);
}
}
|
3e0771974adccac716dd2d9dad52b14d8e42641d
| 10,825 |
java
|
Java
|
squidlib-util/src/main/java/squidpony/squidmath/DDALine.java
|
aus101/SquidLib
|
27ef390d1631178be377b9ea1a23278bfc702924
|
[
"ECL-2.0",
"Apache-2.0"
] | 60 |
2020-10-23T11:17:50.000Z
|
2022-03-29T12:12:11.000Z
|
squidlib-util/src/main/java/squidpony/squidmath/DDALine.java
|
aus101/SquidLib
|
27ef390d1631178be377b9ea1a23278bfc702924
|
[
"ECL-2.0",
"Apache-2.0"
] | 3 |
2021-11-22T09:04:19.000Z
|
2022-01-27T11:00:39.000Z
|
squidlib-util/src/main/java/squidpony/squidmath/DDALine.java
|
aus101/SquidLib
|
27ef390d1631178be377b9ea1a23278bfc702924
|
[
"ECL-2.0",
"Apache-2.0"
] | 8 |
2021-11-28T06:19:07.000Z
|
2022-03-16T03:28:19.000Z
| 39.797794 | 118 | 0.471686 | 3,155 |
package squidpony.squidmath;
import java.util.ArrayList;
import java.util.List;
/**
* A fixed-point line-drawing algorithm that should have good performance; may be useful for LOS.
* Algorithm is from https://hbfs.wordpress.com/2009/07/28/faster-than-bresenhams-algorithm/
* Created by Tommy Ettinger on 1/10/2016.
*/
public class DDALine {
/**
* Draws a line from (startX, startY) to (endX, endY) using the DDA algorithm. Returns a List of Coord in order.
* @param startX x of starting point
* @param startY y of starting point
* @param endX x of ending point
* @param endY y of ending point
* @return List of Coord, including (startX, startY) and (endX, endY) and all points walked between
*/
public static List<Coord> line(int startX, int startY, int endX, int endY) {
return line(startX, startY, endX, endY, 0x7fff, 0x7fff);
}
/**
* Not intended for external use; prefer the overloads without a modifier argument.
* @param startX x of starting point
* @param startY y of starting point
* @param endX x of ending point
* @param endY y of ending point
* @param modifierX an integer that should typically be one of 0x3fff, 0x7fff, or 0xbfff
* @param modifierY an integer that should typically be one of 0x3fff, 0x7fff, or 0xbfff
* @return List of Coord, including (startX, startY) and (endX, endY) and all points walked between
*/
public static List<Coord> line(int startX, int startY, int endX, int endY, int modifierX, int modifierY) {
int dx = endX - startX, dy = endY - startY, nx = Math.abs(dx), ny = Math.abs(dy),
octant = ((dy < 0) ? 4 : 0) | ((dx < 0) ? 2 : 0) | ((ny > nx) ? 1 : 0), move, frac = 0,
mn = Math.max(nx, ny);
ArrayList<Coord> drawn = new ArrayList<>(mn);
if(mn == 0)
{
drawn.add(Coord.get(startX, startY));
return drawn;
}
if(ny == 0)
{
if(dx > 0) {
for (int x = startX, i = 0; x <= endX; x++, i++) {
drawn.add(Coord.get(x, startY));
}
}
else {
for (int x = startX, i = 0; x >= endX; x--, i++) {
drawn.add(Coord.get(x, startY));
}
}
return drawn;
}
if(nx == 0)
{
if(dy > 0) {
for (int y = startY, i = 0; y <= endY; y++, i++) {
drawn.add(Coord.get(startX, y));
}
}
else {
for (int y = startY, i = 0; y >= endY; y--, i++) {
drawn.add(Coord.get(startX, y));
}
}
return drawn;
}
switch (octant)
{
// x positive, y positive
case 0:
move = (ny << 16)/nx;
for (int primary = startX; primary <= endX; primary++, frac+=move) {
drawn.add(Coord.get(primary, startY + ((frac+modifierY)>>16)));
}
break;
case 1:
move = (nx << 16)/ny;
for (int primary = startY; primary <= endY; primary++, frac+=move) {
drawn.add(Coord.get(startX + ((frac+modifierX)>>16), primary));
}
break;
// x negative, y positive
case 2:
move = (ny << 16)/nx;
for (int primary = startX; primary >= endX; primary--, frac+=move) {
drawn.add(Coord.get(primary, startY + ((frac+modifierY)>>16)));
}
break;
case 3:
move = (nx << 16)/ny;
for (int primary = startY; primary <= endY; primary++, frac+=move) {
drawn.add(Coord.get(startX - ((frac+modifierX)>>16), primary));
}
break;
// x negative, y negative
case 6:
move = (ny << 16)/nx;
for (int primary = startX; primary >= endX; primary--, frac+=move) {
drawn.add(Coord.get(primary, startY - ((frac+modifierY)>>16)));
}
break;
case 7:
move = (nx << 16)/ny;
for (int primary = startY; primary >= endY; primary--, frac+=move) {
drawn.add(Coord.get(startX - ((frac+modifierX)>>16), primary));
}
break;
// x positive, y negative
case 4:
move = (ny << 16)/nx;
for (int primary = startX; primary <= endX; primary++, frac+=move) {
drawn.add(Coord.get(primary, startY - ((frac+modifierY)>>16)));
}
break;
case 5:
move = (nx << 16)/ny;
for (int primary = startY; primary >= endY; primary--, frac+=move) {
drawn.add(Coord.get(startX + ((frac+modifierX)>>16), primary));
}
break;
}
return drawn;
}
/**
* Draws a line from start to end using the DDA algorithm. Returns a List of Coord in order.
* @param start starting point
* @param end ending point
* @return List of Coord, including start and end and all points walked between
*/
public static List<Coord> line(Coord start, Coord end)
{
return line(start.x, start.y, end.x, end.y);
}
/**
* Draws a line from (startX, startY) to (endX, endY) using the DDA algorithm. Returns an array of Coord in order.
* @param startX x of starting point
* @param startY y of starting point
* @param endX x of ending point
* @param endY y of ending point
* @return array of Coord, including (startX, startY) and (endX, endY) and all points walked between
*/
public static Coord[] line_(int startX, int startY, int endX, int endY) {
return line_(startX, startY, endX, endY, 0x7fff, 0x7fff);
}
/**
* Not intended for external use; prefer the overloads without a modifier argument.
* @param startX x of starting point
* @param startY y of starting point
* @param endX x of ending point
* @param endY y of ending point
* @param modifierX an integer that should typically be one of 0x3fff, 0x7fff, or 0xbfff
* @param modifierY an integer that should typically be one of 0x3fff, 0x7fff, or 0xbfff
* @return array of Coord, including (startX, startY) and (endX, endY) and all points walked between
*/
public static Coord[] line_(int startX, int startY, int endX, int endY, int modifierX, int modifierY) {
int dx = endX - startX, dy = endY - startY, nx = Math.abs(dx), ny = Math.abs(dy),
octant = ((dy < 0) ? 4 : 0) | ((dx < 0) ? 2 : 0) | ((ny > nx) ? 1 : 0), move, frac = 0,
mn = Math.max(nx, ny);
if(mn == 0)
{
return new Coord[]{Coord.get(startX, startY)};
}
Coord[] drawn = new Coord[mn + 1];
if(ny == 0)
{
if(dx > 0) {
for (int x = startX, i = 0; x <= endX; x++, i++) {
drawn[i] = Coord.get(x, startY);
}
}
else {
for (int x = startX, i = 0; x >= endX; x--, i++) {
drawn[i] = Coord.get(x, startY);
}
}
return drawn;
}
if(nx == 0)
{
if(dy > 0) {
for (int y = startY, i = 0; y <= endY; y++, i++) {
drawn[i] = Coord.get(startX, y);
}
}
else {
for (int y = startY, i = 0; y >= endY; y--, i++) {
drawn[i] = Coord.get(startX, y);
}
}
return drawn;
}
switch (octant)
{
// x positive, y positive
case 0:
move = (ny << 16)/nx;
for (int i = 0, primary = startX; primary <= endX; primary++, frac+=move, i++) {
drawn[i] = Coord.get(primary, startY + ((frac+modifierY)>>16));
}
break;
case 1:
move = (nx << 16)/ny;
for (int i = 0, primary = startY; primary <= endY; primary++, frac+=move, i++) {
drawn[i] = Coord.get(startX + ((frac+modifierX)>>16), primary);
}
break;
// x negative, y positive
case 2:
move = (ny << 16)/nx;
for (int i = 0, primary = startX; primary >= endX; primary--, frac+=move, i++) {
drawn[i] = Coord.get(primary, startY + ((frac+modifierY)>>16));
}
break;
case 3:
move = (nx << 16)/ny;
for (int i = 0, primary = startY; primary <= endY; primary++, frac+=move, i++) {
drawn[i] = Coord.get(startX - ((frac+modifierX)>>16), primary);
}
break;
// x negative, y negative
case 6:
move = (ny << 16)/nx;
for (int i = 0, primary = startX; primary >= endX; primary--, frac+=move, i++) {
drawn[i] = Coord.get(primary, startY - ((frac+modifierY)>>16));
}
break;
case 7:
move = (nx << 16)/ny;
for (int i = 0, primary = startY; primary >= endY; primary--, frac+=move, i++) {
drawn[i] = Coord.get(startX - ((frac+modifierX)>>16), primary);
}
break;
// x positive, y negative
case 4:
move = (ny << 16)/nx;
for (int i = 0, primary = startX; primary <= endX; primary++, frac+=move, i++) {
drawn[i] = Coord.get(primary, startY - ((frac+modifierY)>>16));
}
break;
case 5:
move = (nx << 16)/ny;
for (int i = 0, primary = startY; primary >= endY; primary--, frac+=move, i++) {
drawn[i] = Coord.get(startX + ((frac+modifierX)>>16), primary);
}
break;
}
return drawn;
}
/**
* Draws a line from start to end using the DDA algorithm. Returns an array of Coord in order.
* @param start starting point
* @param end ending point
* @return array of Coord, including start and end and all points walked between
*/
public static Coord[] line_(Coord start, Coord end)
{
return line_(start.x, start.y, end.x, end.y);
}
}
|
3e077210cc2ad9515cf8ae585a9fc0ad8a6f57a1
| 947,153 |
java
|
Java
|
elasticsearch/f3d63095dbcc985e24162fbac4ee0d6914dc757d/randoop_30/RegressionTest4.java
|
leusonmario/2022PhDThesis
|
22969dccdafbc02f022633e9b4c4346821da1402
|
[
"MIT"
] | null | null | null |
elasticsearch/f3d63095dbcc985e24162fbac4ee0d6914dc757d/randoop_30/RegressionTest4.java
|
leusonmario/2022PhDThesis
|
22969dccdafbc02f022633e9b4c4346821da1402
|
[
"MIT"
] | null | null | null |
elasticsearch/f3d63095dbcc985e24162fbac4ee0d6914dc757d/randoop_30/RegressionTest4.java
|
leusonmario/2022PhDThesis
|
22969dccdafbc02f022633e9b4c4346821da1402
|
[
"MIT"
] | null | null | null | 69.526022 | 578 | 0.71939 | 3,156 |
import org.junit.FixMethodOrder;
import org.junit.Test;
import org.junit.runners.MethodSorters;
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
public class RegressionTest4 {
public static boolean debug = false;
@Test
public void test02001() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02001");
org.junit.Assert.assertEquals(0.0d, (double) 100L, (double) (byte) 100);
}
@Test
public void test02002() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02002");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween((int) '4', 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02003() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02003");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.between(1, (int) (short) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02004() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02004");
org.junit.Assert.assertEquals((float) 0, (float) (short) 0, 100.0f);
}
@Test
public void test02005() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02005");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween(0, (-1));
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02006() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02006");
java.text.Collator collator0 = null;
// The following exception was thrown during execution in test generation
try {
int int3 = org.apache.lucene.util.LuceneTestCase.collate(collator0, "tests.badapples", "tests.monster");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02007() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02007");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.PostingsEnum postingsEnum3 = null;
org.apache.lucene.index.PostingsEnum postingsEnum4 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("", postingsEnum3, postingsEnum4, false);
org.junit.rules.TestRule testRule7 = kuromojiAnalysisTests1.ruleChain;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests8 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.Fields fields11 = null;
org.apache.lucene.index.Fields fields12 = null;
kuromojiAnalysisTests8.assertFieldsEquals("europarl.lines.txt.gz", indexReader10, fields11, fields12, false);
kuromojiAnalysisTests8.ensureCleanedUp();
kuromojiAnalysisTests8.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests8.tearDown();
org.junit.Assert.assertNotEquals("europarl.lines.txt.gz", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests8);
kuromojiAnalysisTests8.tearDown();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.IndexReader indexReader23 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests8.assertStoredFieldsEquals("hi!", indexReader22, indexReader23);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule7);
}
@Test
public void test02008() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02008");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.TestRule testRule9 = kuromojiAnalysisTests0.ruleChain;
org.junit.rules.TestRule testRule10 = kuromojiAnalysisTests0.ruleChain;
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.slow", indexReader12, (int) (short) 1, postingsEnum14, postingsEnum15);
org.junit.rules.TestRule testRule17 = kuromojiAnalysisTests0.ruleChain;
java.nio.file.Path path18 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertPathHasBeenCleared(path18);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule9);
org.junit.Assert.assertNotNull(testRule10);
org.junit.Assert.assertNotNull(testRule17);
}
@Test
public void test02009() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02009");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.Fields fields14 = null;
org.apache.lucene.index.Fields fields15 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.awaitsfix", indexReader13, fields14, fields15, true);
kuromojiAnalysisTests0.tearDown();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testBaseFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02010() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02010");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.PostingsEnum postingsEnum3 = null;
org.apache.lucene.index.PostingsEnum postingsEnum4 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("", postingsEnum3, postingsEnum4, false);
org.junit.rules.TestRule testRule7 = kuromojiAnalysisTests1.ruleChain;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests8 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.Fields fields11 = null;
org.apache.lucene.index.Fields fields12 = null;
kuromojiAnalysisTests8.assertFieldsEquals("europarl.lines.txt.gz", indexReader10, fields11, fields12, false);
kuromojiAnalysisTests8.ensureCleanedUp();
kuromojiAnalysisTests8.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests8.tearDown();
org.junit.Assert.assertNotEquals("europarl.lines.txt.gz", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests8);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests20 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.Fields fields23 = null;
org.apache.lucene.index.Fields fields24 = null;
kuromojiAnalysisTests20.assertFieldsEquals("europarl.lines.txt.gz", indexReader22, fields23, fields24, false);
java.lang.String[] strArray34 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet35 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray34);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests36 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests36.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet35, (java.lang.Object) kuromojiAnalysisTests36);
org.apache.lucene.index.PostingsEnum postingsEnum41 = null;
org.apache.lucene.index.PostingsEnum postingsEnum42 = null;
kuromojiAnalysisTests36.assertDocsEnumEquals("tests.badapples", postingsEnum41, postingsEnum42, true);
org.junit.rules.TestRule testRule45 = kuromojiAnalysisTests36.ruleChain;
org.apache.lucene.index.IndexReader indexReader47 = null;
org.apache.lucene.index.PostingsEnum postingsEnum49 = null;
org.apache.lucene.index.PostingsEnum postingsEnum50 = null;
kuromojiAnalysisTests36.assertDocsSkippingEquals("tests.maxfailures", indexReader47, (int) (byte) 100, postingsEnum49, postingsEnum50, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests53 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader55 = null;
org.apache.lucene.index.Fields fields56 = null;
org.apache.lucene.index.Fields fields57 = null;
kuromojiAnalysisTests53.assertFieldsEquals("europarl.lines.txt.gz", indexReader55, fields56, fields57, false);
kuromojiAnalysisTests53.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain62 = kuromojiAnalysisTests53.failureAndSuccessEvents;
kuromojiAnalysisTests36.failureAndSuccessEvents = ruleChain62;
kuromojiAnalysisTests20.failureAndSuccessEvents = ruleChain62;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests65 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader67 = null;
org.apache.lucene.index.Fields fields68 = null;
org.apache.lucene.index.Fields fields69 = null;
kuromojiAnalysisTests65.assertFieldsEquals("europarl.lines.txt.gz", indexReader67, fields68, fields69, false);
org.apache.lucene.index.IndexReader indexReader73 = null;
org.apache.lucene.index.PostingsEnum postingsEnum75 = null;
org.apache.lucene.index.PostingsEnum postingsEnum76 = null;
kuromojiAnalysisTests65.assertPositionsSkippingEquals("hi!", indexReader73, (int) (byte) 0, postingsEnum75, postingsEnum76);
kuromojiAnalysisTests65.restoreIndexWriterMaxDocs();
org.junit.Assert.assertNotEquals((java.lang.Object) ruleChain62, (java.lang.Object) kuromojiAnalysisTests65);
kuromojiAnalysisTests1.failureAndSuccessEvents = ruleChain62;
java.io.Reader reader81 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertCharFilterEquals(reader81, "tests.monster");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule7);
org.junit.Assert.assertNotNull(strArray34);
org.junit.Assert.assertNotNull(strComparableSet35);
org.junit.Assert.assertNotNull(testRule45);
org.junit.Assert.assertNotNull(ruleChain62);
}
@Test
public void test02011() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02011");
org.junit.Assert.assertNotEquals("tests.maxfailures", 100.0d, (double) (short) 10, (double) 0.0f);
}
@Test
public void test02012() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02012");
org.apache.lucene.document.FieldType fieldType2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newField("random", "tests.monster", fieldType2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02013() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02013");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomAsciiOfLengthBetween((int) (short) 100, (int) (byte) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02014() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02014");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
java.lang.String str13 = kuromojiAnalysisTests0.getTestName();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum18 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("<unknown>", indexReader15, 100, postingsEnum17, postingsEnum18, false);
org.junit.rules.RuleChain ruleChain21 = kuromojiAnalysisTests0.failureAndSuccessEvents;
org.junit.Assert.assertNotNull((java.lang.Object) ruleChain21);
org.junit.Assert.assertEquals("'" + str13 + "' != '" + "<unknown>" + "'", str13, "<unknown>");
org.junit.Assert.assertNotNull(ruleChain21);
}
@Test
public void test02015() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02015");
// The following exception was thrown during execution in test generation
try {
java.lang.String str1 = org.elasticsearch.test.ESTestCase.randomUnicodeOfCodepointLength((int) '4');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02016() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02016");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.slow", indexReader13, (-1), postingsEnum15, postingsEnum16, true);
kuromojiAnalysisTests0.setUp();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testJapaneseStopFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02017() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02017");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests1.setIndexWriterMaxDocs((int) (byte) 10);
kuromojiAnalysisTests1.ensureCleanedUp();
kuromojiAnalysisTests1.ensureCheckIndexPassed();
org.junit.Assert.assertNotNull("tests.weekly", (java.lang.Object) kuromojiAnalysisTests1);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.IndexReader indexReader9 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertDeletedDocsEquals("tests.nightly", indexReader8, indexReader9);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02018() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02018");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween(100, (int) '4');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02019() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02019");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
java.nio.file.Path path15 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertPathHasBeenCleared(path15);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02020() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02020");
org.junit.Assert.assertNotEquals("tests.failfast", (long) (byte) 100, (long) '4');
}
@Test
public void test02021() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02021");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
org.apache.lucene.index.TermsEnum termsEnum12 = null;
org.apache.lucene.index.TermsEnum termsEnum13 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermStatsEquals("", termsEnum12, termsEnum13);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02022() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02022");
java.text.Collator collator0 = null;
// The following exception was thrown during execution in test generation
try {
int int3 = org.apache.lucene.util.LuceneTestCase.collate(collator0, "tests.badapples", "europarl.lines.txt.gz");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02023() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02023");
// The following exception was thrown during execution in test generation
try {
java.lang.String str1 = org.elasticsearch.test.ESTestCase.randomAsciiOfLength((int) (short) 0);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02024() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02024");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("random", indexReader2, fields3, fields4, true);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.Fields fields9 = null;
org.apache.lucene.index.Fields fields10 = null;
kuromojiAnalysisTests0.assertFieldsEquals("enwiki.random.lines.txt", indexReader8, fields9, fields10, false);
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.IndexReader indexReader17 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDeletedDocsEquals("tests.monster", indexReader16, indexReader17);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02025() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02025");
java.util.Random random0 = null;
java.util.Locale locale5 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale7 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale9 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale11 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale13 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray14 = new java.util.Locale[] { locale5, locale7, locale9, locale11, locale13 };
java.util.Set<java.util.Locale> localeSet15 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray14);
java.util.List<java.io.Serializable> serializableList16 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray14);
java.util.Set<java.lang.Cloneable> cloneableSet17 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray14);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray14, (java.lang.Object) (byte) -1);
java.util.Locale locale22 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale24 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale26 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale28 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale30 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray31 = new java.util.Locale[] { locale22, locale24, locale26, locale28, locale30 };
java.util.Set<java.util.Locale> localeSet32 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray31);
java.util.Locale locale35 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale39 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale41 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale43 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray44 = new java.util.Locale[] { locale35, locale37, locale39, locale41, locale43 };
java.util.Set<java.util.Locale> localeSet45 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray44);
java.util.List<java.io.Serializable> serializableList46 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray44);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray31, (java.lang.Object[]) localeArray44);
java.util.Locale locale50 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale52 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale54 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale56 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale58 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray59 = new java.util.Locale[] { locale50, locale52, locale54, locale56, locale58 };
java.util.Set<java.util.Locale> localeSet60 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray59);
java.util.List<java.io.Serializable> serializableList61 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray59);
java.util.Set<java.lang.Cloneable> cloneableSet62 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray59);
org.junit.Assert.assertArrayEquals("tests.slow", (java.lang.Object[]) localeArray44, (java.lang.Object[]) localeArray59);
org.junit.Assert.assertArrayEquals("tests.awaitsfix", (java.lang.Object[]) localeArray14, (java.lang.Object[]) localeArray44);
java.util.Locale locale67 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale69 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale71 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale73 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale75 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray76 = new java.util.Locale[] { locale67, locale69, locale71, locale73, locale75 };
java.util.Set<java.util.Locale> localeSet77 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray76);
java.util.List<java.io.Serializable> serializableList78 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray76);
org.junit.Assert.assertNotNull((java.lang.Object) localeArray76);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray44, (java.lang.Object[]) localeArray76);
org.apache.lucene.document.FieldType fieldType81 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field82 = org.apache.lucene.util.LuceneTestCase.newField(random0, "tests.slow", (java.lang.Object) localeArray76, fieldType81);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(locale5);
org.junit.Assert.assertEquals(locale5.toString(), "");
org.junit.Assert.assertNotNull(locale7);
org.junit.Assert.assertEquals(locale7.toString(), "");
org.junit.Assert.assertNotNull(locale9);
org.junit.Assert.assertEquals(locale9.toString(), "");
org.junit.Assert.assertNotNull(locale11);
org.junit.Assert.assertEquals(locale11.toString(), "");
org.junit.Assert.assertNotNull(locale13);
org.junit.Assert.assertEquals(locale13.toString(), "");
org.junit.Assert.assertNotNull(localeArray14);
org.junit.Assert.assertNotNull(localeSet15);
org.junit.Assert.assertNotNull(serializableList16);
org.junit.Assert.assertNotNull(cloneableSet17);
org.junit.Assert.assertNotNull(locale22);
org.junit.Assert.assertEquals(locale22.toString(), "");
org.junit.Assert.assertNotNull(locale24);
org.junit.Assert.assertEquals(locale24.toString(), "");
org.junit.Assert.assertNotNull(locale26);
org.junit.Assert.assertEquals(locale26.toString(), "");
org.junit.Assert.assertNotNull(locale28);
org.junit.Assert.assertEquals(locale28.toString(), "");
org.junit.Assert.assertNotNull(locale30);
org.junit.Assert.assertEquals(locale30.toString(), "");
org.junit.Assert.assertNotNull(localeArray31);
org.junit.Assert.assertNotNull(localeSet32);
org.junit.Assert.assertNotNull(locale35);
org.junit.Assert.assertEquals(locale35.toString(), "");
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "");
org.junit.Assert.assertNotNull(locale39);
org.junit.Assert.assertEquals(locale39.toString(), "");
org.junit.Assert.assertNotNull(locale41);
org.junit.Assert.assertEquals(locale41.toString(), "");
org.junit.Assert.assertNotNull(locale43);
org.junit.Assert.assertEquals(locale43.toString(), "");
org.junit.Assert.assertNotNull(localeArray44);
org.junit.Assert.assertNotNull(localeSet45);
org.junit.Assert.assertNotNull(serializableList46);
org.junit.Assert.assertNotNull(locale50);
org.junit.Assert.assertEquals(locale50.toString(), "");
org.junit.Assert.assertNotNull(locale52);
org.junit.Assert.assertEquals(locale52.toString(), "");
org.junit.Assert.assertNotNull(locale54);
org.junit.Assert.assertEquals(locale54.toString(), "");
org.junit.Assert.assertNotNull(locale56);
org.junit.Assert.assertEquals(locale56.toString(), "");
org.junit.Assert.assertNotNull(locale58);
org.junit.Assert.assertEquals(locale58.toString(), "");
org.junit.Assert.assertNotNull(localeArray59);
org.junit.Assert.assertNotNull(localeSet60);
org.junit.Assert.assertNotNull(serializableList61);
org.junit.Assert.assertNotNull(cloneableSet62);
org.junit.Assert.assertNotNull(locale67);
org.junit.Assert.assertEquals(locale67.toString(), "");
org.junit.Assert.assertNotNull(locale69);
org.junit.Assert.assertEquals(locale69.toString(), "");
org.junit.Assert.assertNotNull(locale71);
org.junit.Assert.assertEquals(locale71.toString(), "");
org.junit.Assert.assertNotNull(locale73);
org.junit.Assert.assertEquals(locale73.toString(), "");
org.junit.Assert.assertNotNull(locale75);
org.junit.Assert.assertEquals(locale75.toString(), "");
org.junit.Assert.assertNotNull(localeArray76);
org.junit.Assert.assertNotNull(localeSet77);
org.junit.Assert.assertNotNull(serializableList78);
}
@Test
public void test02026() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02026");
org.junit.Assert.assertEquals("tests.maxfailures", (double) (byte) 0, (double) (short) 0, (double) (-1.0f));
}
@Test
public void test02027() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02027");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str10 = kuromojiAnalysisTests0.getTestName();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule12 = kuromojiAnalysisTests0.ruleChain;
org.apache.lucene.index.TermsEnum termsEnum14 = null;
org.apache.lucene.index.TermsEnum termsEnum15 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermStatsEquals("tests.failfast", termsEnum14, termsEnum15);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str10 + "' != '" + "<unknown>" + "'", str10, "<unknown>");
org.junit.Assert.assertNotNull(testRule12);
}
@Test
public void test02028() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02028");
org.junit.Assert.assertNotEquals("", (double) 10.0f, 100.0d, (double) 10);
}
@Test
public void test02029() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02029");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain9 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("<unknown>", postingsEnum12, postingsEnum13, false);
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.IndexReader indexReader18 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDocValuesEquals("tests.nightly", indexReader17, indexReader18);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain9);
}
@Test
public void test02030() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02030");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.Fields fields14 = null;
org.apache.lucene.index.Fields fields15 = null;
kuromojiAnalysisTests1.assertFieldsEquals("enwiki.random.lines.txt", indexReader13, fields14, fields15, false);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests1.ruleChain;
org.junit.Assert.assertNotEquals((java.lang.Object) (-1.0d), (java.lang.Object) kuromojiAnalysisTests1);
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
kuromojiAnalysisTests1.assertDocsSkippingEquals("", indexReader21, (int) '4', postingsEnum23, postingsEnum24, false);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testReadingFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02031() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02031");
// The following exception was thrown during execution in test generation
try {
int int1 = org.elasticsearch.test.ESTestCase.randomInt((-1));
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02032() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02032");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
kuromojiAnalysisTests2.ensureCleanedUp();
kuromojiAnalysisTests2.resetCheckIndexStatus();
kuromojiAnalysisTests2.ensureCleanedUp();
java.lang.String str12 = kuromojiAnalysisTests2.getTestName();
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Fields fields15 = null;
org.apache.lucene.index.Fields fields16 = null;
kuromojiAnalysisTests2.assertFieldsEquals("<unknown>", indexReader14, fields15, fields16, true);
kuromojiAnalysisTests2.ensureAllSearchContextsReleased();
org.junit.Assert.assertNotSame("tests.monster", (java.lang.Object) 10, (java.lang.Object) kuromojiAnalysisTests2);
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.IndexReader indexReader23 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests2.assertDocValuesEquals("tests.monster", indexReader22, indexReader23);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02033() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02033");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "tests.monster", "<unknown>", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02034() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02034");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str10 = kuromojiAnalysisTests0.getTestName();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.Fields fields13 = null;
org.apache.lucene.index.Fields fields14 = null;
kuromojiAnalysisTests0.assertFieldsEquals("<unknown>", indexReader12, fields13, fields14, true);
org.elasticsearch.common.settings.Settings settings17 = null;
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.env.NodeEnvironment nodeEnvironment18 = kuromojiAnalysisTests0.newNodeEnvironment(settings17);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str10 + "' != '" + "<unknown>" + "'", str10, "<unknown>");
}
@Test
public void test02035() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02035");
java.util.Locale locale6 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale8 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale10 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale12 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale14 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray15 = new java.util.Locale[] { locale6, locale8, locale10, locale12, locale14 };
java.util.Set<java.util.Locale> localeSet16 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray15);
java.util.List<java.io.Serializable> serializableList17 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray15);
org.junit.Assert.assertNotSame("", (java.lang.Object) localeArray15, (java.lang.Object) 0.0f);
java.util.Locale locale23 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale25 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale27 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale29 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale31 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray32 = new java.util.Locale[] { locale23, locale25, locale27, locale29, locale31 };
java.util.Set<java.util.Locale> localeSet33 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray32);
java.util.List<java.io.Serializable> serializableList34 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray32);
org.junit.Assert.assertNotSame("", (java.lang.Object) localeArray32, (java.lang.Object) 0.0f);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", (java.lang.Object[]) localeArray15, (java.lang.Object[]) localeArray32);
java.util.Locale locale39 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale41 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale43 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale45 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale47 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray48 = new java.util.Locale[] { locale39, locale41, locale43, locale45, locale47 };
java.util.Set<java.util.Locale> localeSet49 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray48);
org.junit.Assert.assertArrayEquals("tests.nightly", (java.lang.Object[]) localeArray15, (java.lang.Object[]) localeArray48);
java.io.PrintStream printStream51 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.util.LuceneTestCase.dumpArray("", (java.lang.Object[]) localeArray15, printStream51);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(locale6);
org.junit.Assert.assertEquals(locale6.toString(), "");
org.junit.Assert.assertNotNull(locale8);
org.junit.Assert.assertEquals(locale8.toString(), "");
org.junit.Assert.assertNotNull(locale10);
org.junit.Assert.assertEquals(locale10.toString(), "");
org.junit.Assert.assertNotNull(locale12);
org.junit.Assert.assertEquals(locale12.toString(), "");
org.junit.Assert.assertNotNull(locale14);
org.junit.Assert.assertEquals(locale14.toString(), "");
org.junit.Assert.assertNotNull(localeArray15);
org.junit.Assert.assertNotNull(localeSet16);
org.junit.Assert.assertNotNull(serializableList17);
org.junit.Assert.assertNotNull(locale23);
org.junit.Assert.assertEquals(locale23.toString(), "");
org.junit.Assert.assertNotNull(locale25);
org.junit.Assert.assertEquals(locale25.toString(), "");
org.junit.Assert.assertNotNull(locale27);
org.junit.Assert.assertEquals(locale27.toString(), "");
org.junit.Assert.assertNotNull(locale29);
org.junit.Assert.assertEquals(locale29.toString(), "");
org.junit.Assert.assertNotNull(locale31);
org.junit.Assert.assertEquals(locale31.toString(), "");
org.junit.Assert.assertNotNull(localeArray32);
org.junit.Assert.assertNotNull(localeSet33);
org.junit.Assert.assertNotNull(serializableList34);
org.junit.Assert.assertNotNull(locale39);
org.junit.Assert.assertEquals(locale39.toString(), "");
org.junit.Assert.assertNotNull(locale41);
org.junit.Assert.assertEquals(locale41.toString(), "");
org.junit.Assert.assertNotNull(locale43);
org.junit.Assert.assertEquals(locale43.toString(), "");
org.junit.Assert.assertNotNull(locale45);
org.junit.Assert.assertEquals(locale45.toString(), "");
org.junit.Assert.assertNotNull(locale47);
org.junit.Assert.assertEquals(locale47.toString(), "");
org.junit.Assert.assertNotNull(localeArray48);
org.junit.Assert.assertNotNull(localeSet49);
}
@Test
public void test02036() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02036");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
java.lang.String str13 = kuromojiAnalysisTests0.getTestName();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum18 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("<unknown>", indexReader15, 100, postingsEnum17, postingsEnum18, false);
org.apache.lucene.index.IndexableField indexableField22 = null;
org.apache.lucene.index.IndexableField indexableField23 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertStoredFieldEquals("enwiki.random.lines.txt", indexableField22, indexableField23);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str13 + "' != '" + "<unknown>" + "'", str13, "<unknown>");
}
@Test
public void test02037() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02037");
java.util.Locale locale3 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale5 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale7 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale9 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale11 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray12 = new java.util.Locale[] { locale3, locale5, locale7, locale9, locale11 };
java.util.Set<java.util.Locale> localeSet13 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray12);
java.util.List<java.io.Serializable> serializableList14 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray12);
java.util.Set<java.lang.Cloneable> cloneableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray12);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray12, (java.lang.Object) (byte) -1);
java.util.Locale locale20 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale22 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale24 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale26 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale28 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray29 = new java.util.Locale[] { locale20, locale22, locale24, locale26, locale28 };
java.util.Set<java.util.Locale> localeSet30 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray29);
java.util.List<java.io.Serializable> serializableList31 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray29);
java.util.Set<java.lang.Cloneable> cloneableSet32 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray29);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray29, (java.lang.Object) (byte) -1);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray12, (java.lang.Object[]) localeArray29);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests36 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader38 = null;
org.apache.lucene.index.Fields fields39 = null;
org.apache.lucene.index.Fields fields40 = null;
kuromojiAnalysisTests36.assertFieldsEquals("europarl.lines.txt.gz", indexReader38, fields39, fields40, false);
kuromojiAnalysisTests36.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain45 = kuromojiAnalysisTests36.failureAndSuccessEvents;
kuromojiAnalysisTests36.setUp();
org.junit.Assert.assertNotSame("tests.nightly", (java.lang.Object) localeArray12, (java.lang.Object) kuromojiAnalysisTests36);
org.apache.lucene.index.IndexReader indexReader49 = null;
org.apache.lucene.index.PostingsEnum postingsEnum51 = null;
org.apache.lucene.index.PostingsEnum postingsEnum52 = null;
kuromojiAnalysisTests36.assertDocsSkippingEquals("tests.awaitsfix", indexReader49, 10, postingsEnum51, postingsEnum52, true);
org.apache.lucene.index.IndexReader indexReader56 = null;
org.apache.lucene.index.Fields fields57 = null;
org.apache.lucene.index.Fields fields58 = null;
kuromojiAnalysisTests36.assertFieldsEquals("random", indexReader56, fields57, fields58, true);
org.apache.lucene.index.IndexReader indexReader62 = null;
org.apache.lucene.index.IndexReader indexReader63 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests36.assertFieldInfosEquals("hi!", indexReader62, indexReader63);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(locale3);
org.junit.Assert.assertEquals(locale3.toString(), "");
org.junit.Assert.assertNotNull(locale5);
org.junit.Assert.assertEquals(locale5.toString(), "");
org.junit.Assert.assertNotNull(locale7);
org.junit.Assert.assertEquals(locale7.toString(), "");
org.junit.Assert.assertNotNull(locale9);
org.junit.Assert.assertEquals(locale9.toString(), "");
org.junit.Assert.assertNotNull(locale11);
org.junit.Assert.assertEquals(locale11.toString(), "");
org.junit.Assert.assertNotNull(localeArray12);
org.junit.Assert.assertNotNull(localeSet13);
org.junit.Assert.assertNotNull(serializableList14);
org.junit.Assert.assertNotNull(cloneableSet15);
org.junit.Assert.assertNotNull(locale20);
org.junit.Assert.assertEquals(locale20.toString(), "");
org.junit.Assert.assertNotNull(locale22);
org.junit.Assert.assertEquals(locale22.toString(), "");
org.junit.Assert.assertNotNull(locale24);
org.junit.Assert.assertEquals(locale24.toString(), "");
org.junit.Assert.assertNotNull(locale26);
org.junit.Assert.assertEquals(locale26.toString(), "");
org.junit.Assert.assertNotNull(locale28);
org.junit.Assert.assertEquals(locale28.toString(), "");
org.junit.Assert.assertNotNull(localeArray29);
org.junit.Assert.assertNotNull(localeSet30);
org.junit.Assert.assertNotNull(serializableList31);
org.junit.Assert.assertNotNull(cloneableSet32);
org.junit.Assert.assertNotNull(ruleChain45);
}
@Test
public void test02038() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02038");
// The following exception was thrown during execution in test generation
try {
java.lang.String str1 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLength((int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02039() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02039");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomAsciiOfLengthBetween((int) '4', (int) (byte) 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02040() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02040");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.scaledRandomIntBetween(10, (int) (short) 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02041() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02041");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path2 = org.apache.lucene.util.LuceneTestCase.createTempFile("tests.monster", "tests.maxfailures");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02042() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02042");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy2 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy(true, (int) (byte) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02043() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02043");
org.junit.Assert.assertNotEquals((double) (short) -1, (double) 10, (double) 10.0f);
}
@Test
public void test02044() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02044");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path2 = org.apache.lucene.util.LuceneTestCase.createTempFile("tests.weekly", "tests.badapples");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02045() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02045");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.slow", indexReader10, (int) '#', postingsEnum12, postingsEnum13, false);
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.maxfailures", indexReader17, (int) (short) 100, postingsEnum19, postingsEnum20);
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.index.analysis.AnalysisService analysisService22 = kuromojiAnalysisTests0.createAnalysisService();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02046() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02046");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween((int) (short) 1, 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02047() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02047");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str10 = kuromojiAnalysisTests0.getTestName();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule12 = kuromojiAnalysisTests0.ruleChain;
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.tearDown();
org.elasticsearch.common.settings.Settings settings16 = null;
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.env.NodeEnvironment nodeEnvironment17 = kuromojiAnalysisTests0.newNodeEnvironment(settings16);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str10 + "' != '" + "<unknown>" + "'", str10, "<unknown>");
org.junit.Assert.assertNotNull(testRule12);
}
@Test
public void test02048() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02048");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.scaledRandomIntBetween((int) (short) 10, 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02049() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02049");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween(1, 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02050() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02050");
java.util.Locale locale3 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale5 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale7 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale9 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale11 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray12 = new java.util.Locale[] { locale3, locale5, locale7, locale9, locale11 };
java.util.Set<java.util.Locale> localeSet13 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray12);
java.util.Locale locale16 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale18 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale20 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale22 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale24 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray25 = new java.util.Locale[] { locale16, locale18, locale20, locale22, locale24 };
java.util.Set<java.util.Locale> localeSet26 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray25);
java.util.List<java.io.Serializable> serializableList27 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray25);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray12, (java.lang.Object[]) localeArray25);
java.util.Locale locale31 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale33 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale35 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale39 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray40 = new java.util.Locale[] { locale31, locale33, locale35, locale37, locale39 };
java.util.Set<java.util.Locale> localeSet41 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray40);
java.util.List<java.io.Serializable> serializableList42 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray40);
java.util.Set<java.lang.Cloneable> cloneableSet43 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray40);
org.junit.Assert.assertArrayEquals("tests.slow", (java.lang.Object[]) localeArray25, (java.lang.Object[]) localeArray40);
java.io.PrintStream printStream45 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.util.LuceneTestCase.dumpArray("", (java.lang.Object[]) localeArray40, printStream45);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(locale3);
org.junit.Assert.assertEquals(locale3.toString(), "");
org.junit.Assert.assertNotNull(locale5);
org.junit.Assert.assertEquals(locale5.toString(), "");
org.junit.Assert.assertNotNull(locale7);
org.junit.Assert.assertEquals(locale7.toString(), "");
org.junit.Assert.assertNotNull(locale9);
org.junit.Assert.assertEquals(locale9.toString(), "");
org.junit.Assert.assertNotNull(locale11);
org.junit.Assert.assertEquals(locale11.toString(), "");
org.junit.Assert.assertNotNull(localeArray12);
org.junit.Assert.assertNotNull(localeSet13);
org.junit.Assert.assertNotNull(locale16);
org.junit.Assert.assertEquals(locale16.toString(), "");
org.junit.Assert.assertNotNull(locale18);
org.junit.Assert.assertEquals(locale18.toString(), "");
org.junit.Assert.assertNotNull(locale20);
org.junit.Assert.assertEquals(locale20.toString(), "");
org.junit.Assert.assertNotNull(locale22);
org.junit.Assert.assertEquals(locale22.toString(), "");
org.junit.Assert.assertNotNull(locale24);
org.junit.Assert.assertEquals(locale24.toString(), "");
org.junit.Assert.assertNotNull(localeArray25);
org.junit.Assert.assertNotNull(localeSet26);
org.junit.Assert.assertNotNull(serializableList27);
org.junit.Assert.assertNotNull(locale31);
org.junit.Assert.assertEquals(locale31.toString(), "");
org.junit.Assert.assertNotNull(locale33);
org.junit.Assert.assertEquals(locale33.toString(), "");
org.junit.Assert.assertNotNull(locale35);
org.junit.Assert.assertEquals(locale35.toString(), "");
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "");
org.junit.Assert.assertNotNull(locale39);
org.junit.Assert.assertEquals(locale39.toString(), "");
org.junit.Assert.assertNotNull(localeArray40);
org.junit.Assert.assertNotNull(localeSet41);
org.junit.Assert.assertNotNull(serializableList42);
org.junit.Assert.assertNotNull(cloneableSet43);
}
@Test
public void test02051() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02051");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Fields fields17 = null;
org.apache.lucene.index.Fields fields18 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.slow", indexReader16, fields17, fields18, false);
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum25 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("<unknown>", indexReader22, (int) 'a', postingsEnum24, postingsEnum25);
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testBaseFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02052() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02052");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newTextField("enwiki.random.lines.txt", "tests.nightly", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02053() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02053");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.between((-1), 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02054() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02054");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween((int) (byte) 10, (int) (short) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02055() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02055");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (short) 0);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02056() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02056");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.slow", indexReader10, (int) '#', postingsEnum12, postingsEnum13, false);
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.maxfailures", indexReader17, (int) (short) 100, postingsEnum19, postingsEnum20);
org.apache.lucene.index.IndexReader indexReader23 = null;
org.apache.lucene.index.Fields fields24 = null;
org.apache.lucene.index.Fields fields25 = null;
kuromojiAnalysisTests0.assertFieldsEquals("enwiki.random.lines.txt", indexReader23, fields24, fields25, false);
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.Fields fields30 = null;
org.apache.lucene.index.Fields fields31 = null;
kuromojiAnalysisTests0.assertFieldsEquals("enwiki.random.lines.txt", indexReader29, fields30, fields31, true);
java.io.Reader reader34 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertCharFilterEquals(reader34, "tests.maxfailures");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02057() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02057");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str10 = kuromojiAnalysisTests0.getTestName();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.Fields fields13 = null;
org.apache.lucene.index.Fields fields14 = null;
kuromojiAnalysisTests0.assertFieldsEquals("<unknown>", indexReader12, fields13, fields14, true);
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testKuromojiUserDict();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str10 + "' != '" + "<unknown>" + "'", str10, "<unknown>");
}
@Test
public void test02058() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02058");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
kuromojiAnalysisTests1.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.slow", indexReader18, (-1), postingsEnum20, postingsEnum21);
org.apache.lucene.index.IndexReader indexReader24 = null;
org.apache.lucene.index.IndexReader indexReader25 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertDeletedDocsEquals("tests.awaitsfix", indexReader24, indexReader25);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02059() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02059");
java.text.Collator collator0 = null;
// The following exception was thrown during execution in test generation
try {
int int3 = org.apache.lucene.util.LuceneTestCase.collate(collator0, "tests.weekly", "enwiki.random.lines.txt");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02060() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02060");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.setUp();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("", indexReader17, (int) '#', postingsEnum19, postingsEnum20);
kuromojiAnalysisTests1.ensureCleanedUp();
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum25 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("tests.weekly", postingsEnum24, postingsEnum25, false);
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("enwiki.random.lines.txt", postingsEnum29, postingsEnum30, true);
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.index.analysis.AnalysisService analysisService33 = kuromojiAnalysisTests1.createAnalysisService();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02061() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02061");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy1 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy((int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02062() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02062");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween((int) '4', (int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02063() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02063");
org.junit.Assert.assertEquals("<unknown>", 0.0f, (float) ' ', (float) (short) 100);
}
@Test
public void test02064() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02064");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
org.junit.rules.RuleChain ruleChain13 = kuromojiAnalysisTests0.failureAndSuccessEvents;
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.IndexReader indexReader16 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertNormsEquals("tests.weekly", indexReader15, indexReader16);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain13);
}
@Test
public void test02065() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02065");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("tests.nightly", postingsEnum21, postingsEnum22, true);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests25 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.Fields fields28 = null;
org.apache.lucene.index.Fields fields29 = null;
kuromojiAnalysisTests25.assertFieldsEquals("europarl.lines.txt.gz", indexReader27, fields28, fields29, false);
kuromojiAnalysisTests25.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests25.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests25.ensureCleanedUp();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests25);
long[] longArray41 = new long[] { 1 };
long[] longArray43 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray41, longArray43);
long[] longArray47 = new long[] { 1 };
long[] longArray49 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray47, longArray49);
org.junit.Assert.assertArrayEquals("random", longArray43, longArray49);
long[] longArray55 = new long[] { 1 };
long[] longArray57 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray55, longArray57);
long[] longArray62 = new long[] { 1 };
long[] longArray64 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray62, longArray64);
long[] longArray68 = new long[] { 1 };
long[] longArray70 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray68, longArray70);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", longArray64, longArray68);
org.junit.Assert.assertArrayEquals("enwiki.random.lines.txt", longArray55, longArray68);
org.junit.Assert.assertArrayEquals(longArray49, longArray55);
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) longArray55);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests76 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader78 = null;
org.apache.lucene.index.Fields fields79 = null;
org.apache.lucene.index.Fields fields80 = null;
kuromojiAnalysisTests76.assertFieldsEquals("europarl.lines.txt.gz", indexReader78, fields79, fields80, false);
kuromojiAnalysisTests76.assertPathHasBeenCleared("tests.slow");
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests76);
org.apache.lucene.index.IndexReader indexReader87 = null;
org.apache.lucene.index.IndexReader indexReader88 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests76.assertNormsEquals("tests.nightly", indexReader87, indexReader88);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(longArray41);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray41), "[1]");
org.junit.Assert.assertNotNull(longArray43);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray43), "[1]");
org.junit.Assert.assertNotNull(longArray47);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray47), "[1]");
org.junit.Assert.assertNotNull(longArray49);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray49), "[1]");
org.junit.Assert.assertNotNull(longArray55);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray55), "[1]");
org.junit.Assert.assertNotNull(longArray57);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray57), "[1]");
org.junit.Assert.assertNotNull(longArray62);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray62), "[1]");
org.junit.Assert.assertNotNull(longArray64);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray64), "[1]");
org.junit.Assert.assertNotNull(longArray68);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray68), "[1]");
org.junit.Assert.assertNotNull(longArray70);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray70), "[1]");
}
@Test
public void test02066() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02066");
java.util.concurrent.ExecutorService[] executorServiceArray2 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[] executorServiceArray3 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[] executorServiceArray4 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[] executorServiceArray5 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[] executorServiceArray6 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[] executorServiceArray7 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[][] executorServiceArray8 = new java.util.concurrent.ExecutorService[][] { executorServiceArray2, executorServiceArray3, executorServiceArray4, executorServiceArray5, executorServiceArray6, executorServiceArray7 };
java.util.List<java.util.concurrent.ExecutorService[]> executorServiceArrayList9 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 0, executorServiceArray8);
// The following exception was thrown during execution in test generation
try {
java.util.List<java.util.concurrent.ExecutorService[]> executorServiceArrayList10 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) '#', executorServiceArray8);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalArgumentException; message: Can't pick 35 random objects from a list of 6 objects");
} catch (java.lang.IllegalArgumentException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(executorServiceArray2);
org.junit.Assert.assertNotNull(executorServiceArray3);
org.junit.Assert.assertNotNull(executorServiceArray4);
org.junit.Assert.assertNotNull(executorServiceArray5);
org.junit.Assert.assertNotNull(executorServiceArray6);
org.junit.Assert.assertNotNull(executorServiceArray7);
org.junit.Assert.assertNotNull(executorServiceArray8);
org.junit.Assert.assertNotNull(executorServiceArrayList9);
}
@Test
public void test02067() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02067");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.Fields fields23 = null;
org.apache.lucene.index.Fields fields24 = null;
kuromojiAnalysisTests0.assertFieldsEquals("", indexReader22, fields23, fields24, false);
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.Terms terms29 = null;
org.apache.lucene.index.Terms terms30 = null;
kuromojiAnalysisTests0.assertTermsEquals("", indexReader28, terms29, terms30, true);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests34 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader36 = null;
org.apache.lucene.index.Fields fields37 = null;
org.apache.lucene.index.Fields fields38 = null;
kuromojiAnalysisTests34.assertFieldsEquals("europarl.lines.txt.gz", indexReader36, fields37, fields38, false);
kuromojiAnalysisTests34.ensureCleanedUp();
kuromojiAnalysisTests34.resetCheckIndexStatus();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests43 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader45 = null;
org.apache.lucene.index.Fields fields46 = null;
org.apache.lucene.index.Fields fields47 = null;
kuromojiAnalysisTests43.assertFieldsEquals("random", indexReader45, fields46, fields47, true);
org.junit.Assert.assertNotSame("random", (java.lang.Object) kuromojiAnalysisTests34, (java.lang.Object) fields46);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) fields46);
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader54 = null;
org.apache.lucene.index.IndexReader indexReader55 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertStoredFieldsEquals("tests.slow", indexReader54, indexReader55);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02068() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02068");
java.lang.String[] strArray8 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet9 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray8);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests10 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests10.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet9, (java.lang.Object) kuromojiAnalysisTests10);
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
kuromojiAnalysisTests10.assertDocsEnumEquals("tests.badapples", postingsEnum15, postingsEnum16, true);
org.junit.rules.TestRule testRule19 = kuromojiAnalysisTests10.ruleChain;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests20 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests20.assertDocsEnumEquals("", postingsEnum22, postingsEnum23, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests26 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.Fields fields29 = null;
org.apache.lucene.index.Fields fields30 = null;
kuromojiAnalysisTests26.assertFieldsEquals("europarl.lines.txt.gz", indexReader28, fields29, fields30, false);
kuromojiAnalysisTests26.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain35 = kuromojiAnalysisTests26.failureAndSuccessEvents;
kuromojiAnalysisTests26.resetCheckIndexStatus();
org.apache.lucene.index.IndexReader indexReader38 = null;
org.apache.lucene.index.Fields fields39 = null;
org.apache.lucene.index.Fields fields40 = null;
kuromojiAnalysisTests26.assertFieldsEquals("enwiki.random.lines.txt", indexReader38, fields39, fields40, false);
kuromojiAnalysisTests26.setIndexWriterMaxDocs((int) (byte) 0);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests45 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader47 = null;
org.apache.lucene.index.Fields fields48 = null;
org.apache.lucene.index.Fields fields49 = null;
kuromojiAnalysisTests45.assertFieldsEquals("europarl.lines.txt.gz", indexReader47, fields48, fields49, false);
kuromojiAnalysisTests45.ensureCleanedUp();
kuromojiAnalysisTests45.resetCheckIndexStatus();
kuromojiAnalysisTests45.ensureCleanedUp();
kuromojiAnalysisTests45.ensureCheckIndexPassed();
kuromojiAnalysisTests45.restoreIndexWriterMaxDocs();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests57 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader59 = null;
org.apache.lucene.index.Fields fields60 = null;
org.apache.lucene.index.Fields fields61 = null;
kuromojiAnalysisTests57.assertFieldsEquals("europarl.lines.txt.gz", indexReader59, fields60, fields61, false);
kuromojiAnalysisTests57.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain66 = kuromojiAnalysisTests57.failureAndSuccessEvents;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain66;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain66;
kuromojiAnalysisTests45.failureAndSuccessEvents = ruleChain66;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain66;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain66;
kuromojiAnalysisTests26.failureAndSuccessEvents = ruleChain66;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain66;
kuromojiAnalysisTests20.failureAndSuccessEvents = ruleChain66;
org.junit.Assert.assertNotEquals("enwiki.random.lines.txt", (java.lang.Object) testRule19, (java.lang.Object) ruleChain66);
org.junit.Assert.assertNotNull((java.lang.Object) testRule19);
org.junit.Assert.assertNotNull(strArray8);
org.junit.Assert.assertNotNull(strComparableSet9);
org.junit.Assert.assertNotNull(testRule19);
org.junit.Assert.assertNotNull(ruleChain35);
org.junit.Assert.assertNotNull(ruleChain66);
}
@Test
public void test02069() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02069");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.resetCheckIndexStatus();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testIterationMarkCharFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02070() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02070");
java.text.Collator collator0 = null;
// The following exception was thrown during execution in test generation
try {
int int3 = org.apache.lucene.util.LuceneTestCase.collate(collator0, "europarl.lines.txt.gz", "random");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02071() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02071");
// The following exception was thrown during execution in test generation
try {
java.lang.String str1 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfLength((int) '4');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02072() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02072");
org.apache.lucene.document.FieldType fieldType2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newField("europarl.lines.txt.gz", "hi!", fieldType2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02073() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02073");
long[] longArray3 = new long[] { 1 };
long[] longArray5 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray3, longArray5);
long[] longArray9 = new long[] { 1 };
long[] longArray11 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray9, longArray11);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", longArray5, longArray9);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests14 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Fields fields17 = null;
org.apache.lucene.index.Fields fields18 = null;
kuromojiAnalysisTests14.assertFieldsEquals("europarl.lines.txt.gz", indexReader16, fields17, fields18, false);
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum25 = null;
kuromojiAnalysisTests14.assertPositionsSkippingEquals("hi!", indexReader22, (int) (byte) 0, postingsEnum24, postingsEnum25);
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.Terms terms29 = null;
org.apache.lucene.index.Terms terms30 = null;
kuromojiAnalysisTests14.assertTermsEquals("random", indexReader28, terms29, terms30, true);
kuromojiAnalysisTests14.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum35 = null;
org.apache.lucene.index.PostingsEnum postingsEnum36 = null;
kuromojiAnalysisTests14.assertDocsEnumEquals("tests.nightly", postingsEnum35, postingsEnum36, true);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests39 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader41 = null;
org.apache.lucene.index.Fields fields42 = null;
org.apache.lucene.index.Fields fields43 = null;
kuromojiAnalysisTests39.assertFieldsEquals("europarl.lines.txt.gz", indexReader41, fields42, fields43, false);
kuromojiAnalysisTests39.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests39.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests39.ensureCleanedUp();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests14, (java.lang.Object) kuromojiAnalysisTests39);
long[] longArray55 = new long[] { 1 };
long[] longArray57 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray55, longArray57);
long[] longArray61 = new long[] { 1 };
long[] longArray63 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray61, longArray63);
org.junit.Assert.assertArrayEquals("random", longArray57, longArray63);
long[] longArray69 = new long[] { 1 };
long[] longArray71 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray69, longArray71);
long[] longArray76 = new long[] { 1 };
long[] longArray78 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray76, longArray78);
long[] longArray82 = new long[] { 1 };
long[] longArray84 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray82, longArray84);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", longArray78, longArray82);
org.junit.Assert.assertArrayEquals("enwiki.random.lines.txt", longArray69, longArray82);
org.junit.Assert.assertArrayEquals(longArray63, longArray69);
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests14, (java.lang.Object) longArray69);
org.junit.Assert.assertArrayEquals(longArray9, longArray69);
org.junit.Assert.assertNotNull(longArray3);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray3), "[1]");
org.junit.Assert.assertNotNull(longArray5);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray5), "[1]");
org.junit.Assert.assertNotNull(longArray9);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray9), "[1]");
org.junit.Assert.assertNotNull(longArray11);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray11), "[1]");
org.junit.Assert.assertNotNull(longArray55);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray55), "[1]");
org.junit.Assert.assertNotNull(longArray57);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray57), "[1]");
org.junit.Assert.assertNotNull(longArray61);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray61), "[1]");
org.junit.Assert.assertNotNull(longArray63);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray63), "[1]");
org.junit.Assert.assertNotNull(longArray69);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray69), "[1]");
org.junit.Assert.assertNotNull(longArray71);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray71), "[1]");
org.junit.Assert.assertNotNull(longArray76);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray76), "[1]");
org.junit.Assert.assertNotNull(longArray78);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray78), "[1]");
org.junit.Assert.assertNotNull(longArray82);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray82), "[1]");
org.junit.Assert.assertNotNull(longArray84);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray84), "[1]");
}
@Test
public void test02074() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02074");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain10;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests12 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Fields fields15 = null;
org.apache.lucene.index.Fields fields16 = null;
kuromojiAnalysisTests12.assertFieldsEquals("europarl.lines.txt.gz", indexReader14, fields15, fields16, false);
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests12.assertPositionsSkippingEquals("hi!", indexReader20, (int) (byte) 0, postingsEnum22, postingsEnum23);
java.lang.String str25 = kuromojiAnalysisTests12.getTestName();
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests12.assertDocsSkippingEquals("<unknown>", indexReader27, 100, postingsEnum29, postingsEnum30, false);
org.junit.rules.RuleChain ruleChain33 = kuromojiAnalysisTests12.failureAndSuccessEvents;
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) ruleChain10, (java.lang.Object) kuromojiAnalysisTests12);
org.apache.lucene.index.IndexReader indexReader36 = null;
org.apache.lucene.index.IndexReader indexReader37 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests12.assertTermVectorsEquals("random", indexReader36, indexReader37);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str25 + "' != '" + "<unknown>" + "'", str25, "<unknown>");
org.junit.Assert.assertNotNull(ruleChain33);
}
@Test
public void test02075() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02075");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests9.assertDocsEnumEquals("tests.badapples", postingsEnum14, postingsEnum15, true);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests9.ruleChain;
kuromojiAnalysisTests9.setUp();
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.Terms terms22 = null;
org.apache.lucene.index.Terms terms23 = null;
kuromojiAnalysisTests9.assertTermsEquals("tests.slow", indexReader21, terms22, terms23, false);
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (short) 1);
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.IndexReader indexReader30 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests9.assertStoredFieldsEquals("random", indexReader29, indexReader30);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02076() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02076");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfCodepointLengthBetween((int) (short) 100, (int) (byte) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02077() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02077");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.Fields fields20 = null;
org.apache.lucene.index.Fields fields21 = null;
kuromojiAnalysisTests0.assertFieldsEquals("enwiki.random.lines.txt", indexReader19, fields20, fields21, false);
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum28 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.weekly", indexReader25, (int) (byte) 0, postingsEnum27, postingsEnum28, true);
org.apache.lucene.index.IndexReader indexReader32 = null;
org.apache.lucene.index.IndexReader indexReader33 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertStoredFieldsEquals("europarl.lines.txt.gz", indexReader32, indexReader33);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02078() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02078");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.PostingsEnum postingsEnum4 = null;
org.apache.lucene.index.PostingsEnum postingsEnum5 = null;
kuromojiAnalysisTests2.assertDocsEnumEquals("", postingsEnum4, postingsEnum5, false);
org.junit.rules.TestRule testRule8 = kuromojiAnalysisTests2.ruleChain;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.Fields fields12 = null;
org.apache.lucene.index.Fields fields13 = null;
kuromojiAnalysisTests9.assertFieldsEquals("europarl.lines.txt.gz", indexReader11, fields12, fields13, false);
kuromojiAnalysisTests9.ensureCleanedUp();
kuromojiAnalysisTests9.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests9.tearDown();
org.junit.Assert.assertNotEquals("europarl.lines.txt.gz", (java.lang.Object) kuromojiAnalysisTests2, (java.lang.Object) kuromojiAnalysisTests9);
org.junit.Assert.assertNotNull("europarl.lines.txt.gz", (java.lang.Object) kuromojiAnalysisTests2);
java.io.Reader reader22 = null;
// The following exception was thrown during execution in test generation
try {
java.lang.String str23 = kuromojiAnalysisTests2.readFully(reader22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule8);
}
@Test
public void test02079() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02079");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain9 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.elasticsearch.common.settings.Settings settings12 = null;
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.env.NodeEnvironment nodeEnvironment13 = kuromojiAnalysisTests0.newNodeEnvironment(settings12);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain9);
}
@Test
public void test02080() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02080");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests11 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.Fields fields14 = null;
org.apache.lucene.index.Fields fields15 = null;
kuromojiAnalysisTests11.assertFieldsEquals("europarl.lines.txt.gz", indexReader13, fields14, fields15, false);
kuromojiAnalysisTests11.ensureCleanedUp();
kuromojiAnalysisTests11.resetCheckIndexStatus();
org.junit.rules.TestRule testRule20 = kuromojiAnalysisTests11.ruleChain;
org.junit.Assert.assertNotSame("hi!", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) testRule20);
kuromojiAnalysisTests1.resetCheckIndexStatus();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testBaseFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertNotNull(testRule20);
}
@Test
public void test02081() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02081");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
java.lang.String[] strArray14 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray14);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests16.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet15, (java.lang.Object) kuromojiAnalysisTests16);
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests16.assertDocsEnumEquals("tests.badapples", postingsEnum21, postingsEnum22, true);
org.junit.rules.TestRule testRule25 = kuromojiAnalysisTests16.ruleChain;
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests16.assertDocsSkippingEquals("tests.maxfailures", indexReader27, (int) (byte) 100, postingsEnum29, postingsEnum30, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests33 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader35 = null;
org.apache.lucene.index.Fields fields36 = null;
org.apache.lucene.index.Fields fields37 = null;
kuromojiAnalysisTests33.assertFieldsEquals("europarl.lines.txt.gz", indexReader35, fields36, fields37, false);
kuromojiAnalysisTests33.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain42 = kuromojiAnalysisTests33.failureAndSuccessEvents;
kuromojiAnalysisTests16.failureAndSuccessEvents = ruleChain42;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain42;
org.apache.lucene.index.PostingsEnum postingsEnum46 = null;
org.apache.lucene.index.PostingsEnum postingsEnum47 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("<unknown>", postingsEnum46, postingsEnum47, true);
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (short) 10);
java.io.Reader reader52 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertCharFilterEquals(reader52, "europarl.lines.txt.gz");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray14);
org.junit.Assert.assertNotNull(strComparableSet15);
org.junit.Assert.assertNotNull(testRule25);
org.junit.Assert.assertNotNull(ruleChain42);
}
@Test
public void test02082() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02082");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newTextField(random0, "tests.maxfailures", "tests.slow", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02083() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02083");
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray3 = org.elasticsearch.test.ESTestCase.generateRandomStringArray(10, 0, true);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02084() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02084");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.setUp();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.IndexReader indexReader18 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertFieldInfosEquals("", indexReader17, indexReader18);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02085() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02085");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
java.lang.String[] strArray14 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray14);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests16.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet15, (java.lang.Object) kuromojiAnalysisTests16);
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests16.assertDocsEnumEquals("tests.badapples", postingsEnum21, postingsEnum22, true);
org.junit.rules.TestRule testRule25 = kuromojiAnalysisTests16.ruleChain;
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests16.assertDocsSkippingEquals("tests.maxfailures", indexReader27, (int) (byte) 100, postingsEnum29, postingsEnum30, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests33 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader35 = null;
org.apache.lucene.index.Fields fields36 = null;
org.apache.lucene.index.Fields fields37 = null;
kuromojiAnalysisTests33.assertFieldsEquals("europarl.lines.txt.gz", indexReader35, fields36, fields37, false);
kuromojiAnalysisTests33.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain42 = kuromojiAnalysisTests33.failureAndSuccessEvents;
kuromojiAnalysisTests16.failureAndSuccessEvents = ruleChain42;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain42;
org.apache.lucene.index.PostingsEnum postingsEnum46 = null;
org.apache.lucene.index.PostingsEnum postingsEnum47 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("<unknown>", postingsEnum46, postingsEnum47, true);
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader52 = null;
org.apache.lucene.index.Fields fields53 = null;
org.apache.lucene.index.Fields fields54 = null;
kuromojiAnalysisTests0.assertFieldsEquals("<unknown>", indexReader52, fields53, fields54, true);
org.apache.lucene.index.IndexReader indexReader58 = null;
org.apache.lucene.index.TermsEnum termsEnum59 = null;
org.apache.lucene.index.TermsEnum termsEnum60 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("tests.badapples", indexReader58, termsEnum59, termsEnum60, false);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray14);
org.junit.Assert.assertNotNull(strComparableSet15);
org.junit.Assert.assertNotNull(testRule25);
org.junit.Assert.assertNotNull(ruleChain42);
}
@Test
public void test02086() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02086");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("", indexReader11, (int) (byte) 0, postingsEnum13, postingsEnum14);
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testKuromojiEmptyUserDict();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02087() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02087");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain9 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.Fields fields13 = null;
org.apache.lucene.index.Fields fields14 = null;
kuromojiAnalysisTests0.assertFieldsEquals("enwiki.random.lines.txt", indexReader12, fields13, fields14, false);
org.junit.rules.TestRule testRule17 = kuromojiAnalysisTests0.ruleChain;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain9);
org.junit.Assert.assertNotNull(testRule17);
}
@Test
public void test02088() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02088");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path2 = org.apache.lucene.util.LuceneTestCase.createTempFile("tests.slow", "hi!");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02089() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02089");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
kuromojiAnalysisTests2.assertPositionsSkippingEquals("tests.failfast", indexReader10, 1, postingsEnum12, postingsEnum13);
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Fields fields17 = null;
org.apache.lucene.index.Fields fields18 = null;
kuromojiAnalysisTests2.assertFieldsEquals("tests.slow", indexReader16, fields17, fields18, true);
org.junit.Assert.assertNotEquals("tests.awaitsfix", (java.lang.Object) (byte) 1, (java.lang.Object) "tests.slow");
}
@Test
public void test02090() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02090");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("random", indexReader3, fields4, fields5, true);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.Fields fields10 = null;
org.apache.lucene.index.Fields fields11 = null;
kuromojiAnalysisTests1.assertFieldsEquals("enwiki.random.lines.txt", indexReader9, fields10, fields11, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests14 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Fields fields17 = null;
org.apache.lucene.index.Fields fields18 = null;
kuromojiAnalysisTests14.assertFieldsEquals("europarl.lines.txt.gz", indexReader16, fields17, fields18, false);
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum25 = null;
kuromojiAnalysisTests14.assertPositionsSkippingEquals("hi!", indexReader22, (int) (byte) 0, postingsEnum24, postingsEnum25);
kuromojiAnalysisTests14.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests14.resetCheckIndexStatus();
org.junit.Assert.assertNotEquals("tests.badapples", (java.lang.Object) "enwiki.random.lines.txt", (java.lang.Object) kuromojiAnalysisTests14);
org.apache.lucene.index.IndexReader indexReader31 = null;
org.apache.lucene.index.TermsEnum termsEnum32 = null;
org.apache.lucene.index.TermsEnum termsEnum33 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests14.assertTermsEnumEquals("hi!", indexReader31, termsEnum32, termsEnum33, true);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02091() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02091");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("random", indexReader9, (int) '4', postingsEnum11, postingsEnum12);
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Terms terms16 = null;
org.apache.lucene.index.Terms terms17 = null;
kuromojiAnalysisTests0.assertTermsEquals("tests.weekly", indexReader15, terms16, terms17, true);
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray20 = kuromojiAnalysisTests0.tmpPaths();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02092() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02092");
org.junit.Assert.assertNotNull("enwiki.random.lines.txt", (java.lang.Object) (byte) -1);
}
@Test
public void test02093() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02093");
java.util.Random random0 = null;
java.lang.String[] strArray3 = new java.lang.String[] { "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet4 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray3);
org.apache.lucene.document.FieldType fieldType5 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field6 = org.apache.lucene.util.LuceneTestCase.newField(random0, "enwiki.random.lines.txt", (java.lang.Object) strArray3, fieldType5);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray3);
org.junit.Assert.assertNotNull(strComparableSet4);
}
@Test
public void test02094() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02094");
java.util.Random random0 = null;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
kuromojiAnalysisTests2.assertPositionsSkippingEquals("hi!", indexReader10, (int) (byte) 0, postingsEnum12, postingsEnum13);
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Terms terms17 = null;
org.apache.lucene.index.Terms terms18 = null;
kuromojiAnalysisTests2.assertTermsEquals("random", indexReader16, terms17, terms18, true);
kuromojiAnalysisTests2.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
kuromojiAnalysisTests2.assertDocsEnumEquals("tests.nightly", postingsEnum23, postingsEnum24, true);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests27 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.Fields fields30 = null;
org.apache.lucene.index.Fields fields31 = null;
kuromojiAnalysisTests27.assertFieldsEquals("europarl.lines.txt.gz", indexReader29, fields30, fields31, false);
kuromojiAnalysisTests27.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests27.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests27.ensureCleanedUp();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests2, (java.lang.Object) kuromojiAnalysisTests27);
org.junit.Assert.assertNotNull((java.lang.Object) kuromojiAnalysisTests2);
org.apache.lucene.document.FieldType fieldType41 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field42 = org.apache.lucene.util.LuceneTestCase.newField(random0, "", (java.lang.Object) kuromojiAnalysisTests2, fieldType41);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02095() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02095");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("random", indexReader9, (int) '4', postingsEnum11, postingsEnum12);
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum18 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.maxfailures", indexReader15, 10, postingsEnum17, postingsEnum18);
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.IndexReader indexReader22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermVectorsEquals("tests.monster", indexReader21, indexReader22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02096() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02096");
float[][] floatArray1 = new float[][] {};
// The following exception was thrown during execution in test generation
try {
java.util.List<float[]> floatArrayList2 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) 'a', floatArray1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalArgumentException; message: Can't pick 97 random objects from a list of 0 objects");
} catch (java.lang.IllegalArgumentException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(floatArray1);
}
@Test
public void test02097() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02097");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween((int) (byte) 10, (int) (byte) 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02098() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02098");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.Terms terms11 = null;
org.apache.lucene.index.Terms terms12 = null;
kuromojiAnalysisTests0.assertTermsEquals("", indexReader10, terms11, terms12, false);
kuromojiAnalysisTests0.ensureCheckIndexPassed();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.IndexReader indexReader18 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderStatisticsEquals("tests.maxfailures", indexReader17, indexReader18);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02099() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02099");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.Fields fields14 = null;
org.apache.lucene.index.Fields fields15 = null;
kuromojiAnalysisTests1.assertFieldsEquals("enwiki.random.lines.txt", indexReader13, fields14, fields15, false);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests1.ruleChain;
org.junit.Assert.assertNotEquals((java.lang.Object) (-1.0d), (java.lang.Object) kuromojiAnalysisTests1);
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.maxfailures", indexReader21, 0, postingsEnum23, postingsEnum24);
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.IndexReader indexReader28 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertDocValuesEquals("hi!", indexReader27, indexReader28);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02100() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02100");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule9 = kuromojiAnalysisTests0.ruleChain;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests11 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.Fields fields14 = null;
org.apache.lucene.index.Fields fields15 = null;
kuromojiAnalysisTests11.assertFieldsEquals("europarl.lines.txt.gz", indexReader13, fields14, fields15, false);
kuromojiAnalysisTests11.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain20 = kuromojiAnalysisTests11.failureAndSuccessEvents;
kuromojiAnalysisTests11.resetCheckIndexStatus();
java.lang.String str22 = kuromojiAnalysisTests11.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests11);
kuromojiAnalysisTests11.tearDown();
kuromojiAnalysisTests11.overrideTestDefaultQueryCache();
org.junit.rules.RuleChain ruleChain26 = kuromojiAnalysisTests11.failureAndSuccessEvents;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain26;
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.env.NodeEnvironment nodeEnvironment29 = kuromojiAnalysisTests0.newNodeEnvironment();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule9);
org.junit.Assert.assertNotNull(ruleChain20);
org.junit.Assert.assertEquals("'" + str22 + "' != '" + "<unknown>" + "'", str22, "<unknown>");
org.junit.Assert.assertNotNull(ruleChain26);
}
@Test
public void test02101() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02101");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain9 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("enwiki.random.lines.txt", indexReader12, 100, postingsEnum14, postingsEnum15, false);
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.Fields fields20 = null;
org.apache.lucene.index.Fields fields21 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.monster", indexReader19, fields20, fields21, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests24 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader26 = null;
org.apache.lucene.index.Fields fields27 = null;
org.apache.lucene.index.Fields fields28 = null;
kuromojiAnalysisTests24.assertFieldsEquals("europarl.lines.txt.gz", indexReader26, fields27, fields28, false);
kuromojiAnalysisTests24.ensureCleanedUp();
kuromojiAnalysisTests24.resetCheckIndexStatus();
kuromojiAnalysisTests24.setIndexWriterMaxDocs((int) (byte) 0);
org.junit.rules.RuleChain ruleChain35 = kuromojiAnalysisTests24.failureAndSuccessEvents;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain35;
org.apache.lucene.index.IndexReader indexReader38 = null;
org.apache.lucene.index.IndexReader indexReader39 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderEquals("tests.monster", indexReader38, indexReader39);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain9);
org.junit.Assert.assertNotNull(ruleChain35);
}
@Test
public void test02102() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02102");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newTextField(random0, "", "tests.maxfailures", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02103() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02103");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfCodepointLengthBetween((int) (short) 100, (int) (short) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02104() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02104");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.Fields fields23 = null;
org.apache.lucene.index.Fields fields24 = null;
kuromojiAnalysisTests0.assertFieldsEquals("", indexReader22, fields23, fields24, false);
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.Terms terms29 = null;
org.apache.lucene.index.Terms terms30 = null;
kuromojiAnalysisTests0.assertTermsEquals("", indexReader28, terms29, terms30, true);
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (byte) 100);
org.apache.lucene.index.IndexReader indexReader36 = null;
org.apache.lucene.index.IndexReader indexReader37 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderStatisticsEquals("random", indexReader36, indexReader37);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02105() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02105");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfLengthBetween((int) ' ', (int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02106() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02106");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newTextField("tests.badapples", "tests.maxfailures", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02107() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02107");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.IndexReader indexReader26 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertFieldInfosEquals("tests.weekly", indexReader25, indexReader26);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02108() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02108");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.Terms terms11 = null;
org.apache.lucene.index.Terms terms12 = null;
kuromojiAnalysisTests0.assertTermsEquals("", indexReader10, terms11, terms12, false);
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.IndexReader indexReader21 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDocValuesEquals("europarl.lines.txt.gz", indexReader20, indexReader21);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02109() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02109");
org.junit.Assert.assertEquals(100.0f, 100.0f, 1.0f);
}
@Test
public void test02110() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02110");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.TermsEnum termsEnum14 = null;
org.apache.lucene.index.TermsEnum termsEnum15 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("", indexReader13, termsEnum14, termsEnum15, true);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02111() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02111");
double[] doubleArray6 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray11 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray6, doubleArray11, (double) (byte) 100);
double[] doubleArray20 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray25 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray20, doubleArray25, (double) (byte) 100);
double[] doubleArray33 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray38 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray33, doubleArray38, (double) (byte) 100);
org.junit.Assert.assertArrayEquals("", doubleArray20, doubleArray33, (double) 0);
org.junit.Assert.assertArrayEquals(doubleArray6, doubleArray20, (-1.0d));
java.lang.Class<?> wildcardClass45 = doubleArray6.getClass();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests46 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader48 = null;
org.apache.lucene.index.Fields fields49 = null;
org.apache.lucene.index.Fields fields50 = null;
kuromojiAnalysisTests46.assertFieldsEquals("europarl.lines.txt.gz", indexReader48, fields49, fields50, false);
kuromojiAnalysisTests46.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain55 = kuromojiAnalysisTests46.failureAndSuccessEvents;
kuromojiAnalysisTests46.resetCheckIndexStatus();
java.lang.String str57 = kuromojiAnalysisTests46.getTestName();
kuromojiAnalysisTests46.setUp();
org.junit.Assert.assertNotEquals("enwiki.random.lines.txt", (java.lang.Object) wildcardClass45, (java.lang.Object) kuromojiAnalysisTests46);
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.index.analysis.AnalysisService analysisService60 = kuromojiAnalysisTests46.createAnalysisService();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(doubleArray6);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray6), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray11);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray11), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(doubleArray20);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray20), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray25);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray25), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(doubleArray33);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray33), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray38);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray38), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(wildcardClass45);
org.junit.Assert.assertNotNull(ruleChain55);
org.junit.Assert.assertEquals("'" + str57 + "' != '" + "<unknown>" + "'", str57, "<unknown>");
}
@Test
public void test02112() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02112");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomAsciiOfLengthBetween((int) '4', (int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02113() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02113");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
kuromojiAnalysisTests0.ensureCleanedUp();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.Fields fields19 = null;
org.apache.lucene.index.Fields fields20 = null;
kuromojiAnalysisTests16.assertFieldsEquals("europarl.lines.txt.gz", indexReader18, fields19, fields20, false);
kuromojiAnalysisTests16.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain25 = kuromojiAnalysisTests16.failureAndSuccessEvents;
kuromojiAnalysisTests16.setUp();
java.util.Locale locale29 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale31 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale33 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale35 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray38 = new java.util.Locale[] { locale29, locale31, locale33, locale35, locale37 };
java.util.Set<java.util.Locale> localeSet39 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray38);
java.util.Locale locale42 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale44 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale46 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale48 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale50 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray51 = new java.util.Locale[] { locale42, locale44, locale46, locale48, locale50 };
java.util.Set<java.util.Locale> localeSet52 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray51);
java.util.List<java.io.Serializable> serializableList53 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray51);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray38, (java.lang.Object[]) localeArray51);
java.util.Locale locale57 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale59 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale61 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale63 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale65 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray66 = new java.util.Locale[] { locale57, locale59, locale61, locale63, locale65 };
java.util.Set<java.util.Locale> localeSet67 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray66);
java.util.List<java.io.Serializable> serializableList68 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray66);
java.util.Set<java.lang.Cloneable> cloneableSet69 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray66);
org.junit.Assert.assertArrayEquals("tests.slow", (java.lang.Object[]) localeArray51, (java.lang.Object[]) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests16, (java.lang.Object) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests16);
kuromojiAnalysisTests16.ensureCheckIndexPassed();
org.junit.rules.RuleChain ruleChain74 = kuromojiAnalysisTests16.failureAndSuccessEvents;
org.apache.lucene.index.Fields fields76 = null;
org.apache.lucene.index.Fields fields77 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests16.assertFieldStatisticsEquals("tests.awaitsfix", fields76, fields77);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain25);
org.junit.Assert.assertNotNull(locale29);
org.junit.Assert.assertEquals(locale29.toString(), "");
org.junit.Assert.assertNotNull(locale31);
org.junit.Assert.assertEquals(locale31.toString(), "");
org.junit.Assert.assertNotNull(locale33);
org.junit.Assert.assertEquals(locale33.toString(), "");
org.junit.Assert.assertNotNull(locale35);
org.junit.Assert.assertEquals(locale35.toString(), "");
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "");
org.junit.Assert.assertNotNull(localeArray38);
org.junit.Assert.assertNotNull(localeSet39);
org.junit.Assert.assertNotNull(locale42);
org.junit.Assert.assertEquals(locale42.toString(), "");
org.junit.Assert.assertNotNull(locale44);
org.junit.Assert.assertEquals(locale44.toString(), "");
org.junit.Assert.assertNotNull(locale46);
org.junit.Assert.assertEquals(locale46.toString(), "");
org.junit.Assert.assertNotNull(locale48);
org.junit.Assert.assertEquals(locale48.toString(), "");
org.junit.Assert.assertNotNull(locale50);
org.junit.Assert.assertEquals(locale50.toString(), "");
org.junit.Assert.assertNotNull(localeArray51);
org.junit.Assert.assertNotNull(localeSet52);
org.junit.Assert.assertNotNull(serializableList53);
org.junit.Assert.assertNotNull(locale57);
org.junit.Assert.assertEquals(locale57.toString(), "");
org.junit.Assert.assertNotNull(locale59);
org.junit.Assert.assertEquals(locale59.toString(), "");
org.junit.Assert.assertNotNull(locale61);
org.junit.Assert.assertEquals(locale61.toString(), "");
org.junit.Assert.assertNotNull(locale63);
org.junit.Assert.assertEquals(locale63.toString(), "");
org.junit.Assert.assertNotNull(locale65);
org.junit.Assert.assertEquals(locale65.toString(), "");
org.junit.Assert.assertNotNull(localeArray66);
org.junit.Assert.assertNotNull(localeSet67);
org.junit.Assert.assertNotNull(serializableList68);
org.junit.Assert.assertNotNull(cloneableSet69);
org.junit.Assert.assertNotNull(ruleChain74);
}
@Test
public void test02114() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02114");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.TestRule testRule9 = kuromojiAnalysisTests0.ruleChain;
org.junit.rules.TestRule testRule10 = kuromojiAnalysisTests0.ruleChain;
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.slow", indexReader12, (int) (short) 1, postingsEnum14, postingsEnum15);
org.junit.rules.TestRule testRule17 = kuromojiAnalysisTests0.ruleChain;
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.IndexReader indexReader20 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertStoredFieldsEquals("tests.nightly", indexReader19, indexReader20);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule9);
org.junit.Assert.assertNotNull(testRule10);
org.junit.Assert.assertNotNull(testRule17);
}
@Test
public void test02115() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02115");
java.lang.CharSequence[] charSequenceArray0 = null;
// The following exception was thrown during execution in test generation
try {
java.util.Set<java.lang.CharSequence> charSequenceSet1 = org.apache.lucene.util.LuceneTestCase.asSet(charSequenceArray0);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02116() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02116");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "tests.nightly", "enwiki.random.lines.txt", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02117() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02117");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
kuromojiAnalysisTests2.ensureCleanedUp();
kuromojiAnalysisTests2.resetCheckIndexStatus();
kuromojiAnalysisTests2.ensureCleanedUp();
java.lang.String str12 = kuromojiAnalysisTests2.getTestName();
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Fields fields15 = null;
org.apache.lucene.index.Fields fields16 = null;
kuromojiAnalysisTests2.assertFieldsEquals("<unknown>", indexReader14, fields15, fields16, true);
kuromojiAnalysisTests2.ensureAllSearchContextsReleased();
org.junit.Assert.assertNotSame("tests.monster", (java.lang.Object) 10, (java.lang.Object) kuromojiAnalysisTests2);
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.IndexReader indexReader23 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests2.assertDeletedDocsEquals("enwiki.random.lines.txt", indexReader22, indexReader23);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02118() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02118");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfLengthBetween((int) (short) -1, (int) (byte) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02119() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02119");
// The following exception was thrown during execution in test generation
try {
int int1 = org.elasticsearch.test.ESTestCase.randomInt((int) (short) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02120() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02120");
java.lang.Object obj1 = null;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
kuromojiAnalysisTests2.ensureCleanedUp();
kuromojiAnalysisTests2.resetCheckIndexStatus();
kuromojiAnalysisTests2.setIndexWriterMaxDocs((int) (byte) 0);
org.junit.Assert.assertNotEquals("tests.awaitsfix", obj1, (java.lang.Object) kuromojiAnalysisTests2);
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum18 = null;
kuromojiAnalysisTests2.assertPositionsSkippingEquals("tests.nightly", indexReader15, (-1), postingsEnum17, postingsEnum18);
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.IndexReader indexReader22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests2.assertDocValuesEquals("random", indexReader21, indexReader22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02121() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02121");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.Fields fields23 = null;
org.apache.lucene.index.Fields fields24 = null;
kuromojiAnalysisTests0.assertFieldsEquals("", indexReader22, fields23, fields24, false);
kuromojiAnalysisTests0.ensureCheckIndexPassed();
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.IndexReader indexReader30 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDocValuesEquals("tests.failfast", indexReader29, indexReader30);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02122() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02122");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
kuromojiAnalysisTests1.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.TermsEnum termsEnum19 = null;
org.apache.lucene.index.TermsEnum termsEnum20 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertTermsEnumEquals("tests.nightly", indexReader18, termsEnum19, termsEnum20, false);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02123() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02123");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("enwiki.random.lines.txt", indexReader17, (int) ' ', postingsEnum19, postingsEnum20, false);
org.apache.lucene.index.IndexableField indexableField24 = null;
org.apache.lucene.index.IndexableField indexableField25 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertStoredFieldEquals("", indexableField24, indexableField25);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02124() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02124");
java.util.Locale locale3 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale5 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale7 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale9 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale11 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray12 = new java.util.Locale[] { locale3, locale5, locale7, locale9, locale11 };
java.util.Set<java.util.Locale> localeSet13 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray12);
java.util.List<java.io.Serializable> serializableList14 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray12);
java.util.Set<java.lang.Cloneable> cloneableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray12);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray12, (java.lang.Object) (byte) -1);
java.util.Locale locale20 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale22 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale24 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale26 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale28 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray29 = new java.util.Locale[] { locale20, locale22, locale24, locale26, locale28 };
java.util.Set<java.util.Locale> localeSet30 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray29);
java.util.List<java.io.Serializable> serializableList31 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray29);
java.util.Set<java.lang.Cloneable> cloneableSet32 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray29);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray29, (java.lang.Object) (byte) -1);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray12, (java.lang.Object[]) localeArray29);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests36 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader38 = null;
org.apache.lucene.index.Fields fields39 = null;
org.apache.lucene.index.Fields fields40 = null;
kuromojiAnalysisTests36.assertFieldsEquals("europarl.lines.txt.gz", indexReader38, fields39, fields40, false);
kuromojiAnalysisTests36.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain45 = kuromojiAnalysisTests36.failureAndSuccessEvents;
kuromojiAnalysisTests36.setUp();
org.junit.Assert.assertNotSame("tests.nightly", (java.lang.Object) localeArray12, (java.lang.Object) kuromojiAnalysisTests36);
kuromojiAnalysisTests36.setIndexWriterMaxDocs((int) (short) 1);
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray50 = kuromojiAnalysisTests36.tmpPaths();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(locale3);
org.junit.Assert.assertEquals(locale3.toString(), "");
org.junit.Assert.assertNotNull(locale5);
org.junit.Assert.assertEquals(locale5.toString(), "");
org.junit.Assert.assertNotNull(locale7);
org.junit.Assert.assertEquals(locale7.toString(), "");
org.junit.Assert.assertNotNull(locale9);
org.junit.Assert.assertEquals(locale9.toString(), "");
org.junit.Assert.assertNotNull(locale11);
org.junit.Assert.assertEquals(locale11.toString(), "");
org.junit.Assert.assertNotNull(localeArray12);
org.junit.Assert.assertNotNull(localeSet13);
org.junit.Assert.assertNotNull(serializableList14);
org.junit.Assert.assertNotNull(cloneableSet15);
org.junit.Assert.assertNotNull(locale20);
org.junit.Assert.assertEquals(locale20.toString(), "");
org.junit.Assert.assertNotNull(locale22);
org.junit.Assert.assertEquals(locale22.toString(), "");
org.junit.Assert.assertNotNull(locale24);
org.junit.Assert.assertEquals(locale24.toString(), "");
org.junit.Assert.assertNotNull(locale26);
org.junit.Assert.assertEquals(locale26.toString(), "");
org.junit.Assert.assertNotNull(locale28);
org.junit.Assert.assertEquals(locale28.toString(), "");
org.junit.Assert.assertNotNull(localeArray29);
org.junit.Assert.assertNotNull(localeSet30);
org.junit.Assert.assertNotNull(serializableList31);
org.junit.Assert.assertNotNull(cloneableSet32);
org.junit.Assert.assertNotNull(ruleChain45);
}
@Test
public void test02125() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02125");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy2 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy(false, 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02126() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02126");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.tearDown();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.Terms terms12 = null;
org.apache.lucene.index.Terms terms13 = null;
kuromojiAnalysisTests0.assertTermsEquals("tests.weekly", indexReader11, terms12, terms13, true);
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests17 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.Fields fields20 = null;
org.apache.lucene.index.Fields fields21 = null;
kuromojiAnalysisTests17.assertFieldsEquals("europarl.lines.txt.gz", indexReader19, fields20, fields21, false);
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum28 = null;
kuromojiAnalysisTests17.assertPositionsSkippingEquals("hi!", indexReader25, (int) (byte) 0, postingsEnum27, postingsEnum28);
org.apache.lucene.index.IndexReader indexReader31 = null;
org.apache.lucene.index.Terms terms32 = null;
org.apache.lucene.index.Terms terms33 = null;
kuromojiAnalysisTests17.assertTermsEquals("random", indexReader31, terms32, terms33, true);
kuromojiAnalysisTests17.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum38 = null;
org.apache.lucene.index.PostingsEnum postingsEnum39 = null;
kuromojiAnalysisTests17.assertDocsEnumEquals("tests.nightly", postingsEnum38, postingsEnum39, true);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests42 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader44 = null;
org.apache.lucene.index.Fields fields45 = null;
org.apache.lucene.index.Fields fields46 = null;
kuromojiAnalysisTests42.assertFieldsEquals("europarl.lines.txt.gz", indexReader44, fields45, fields46, false);
kuromojiAnalysisTests42.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests42.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests42.ensureCleanedUp();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests17, (java.lang.Object) kuromojiAnalysisTests42);
kuromojiAnalysisTests17.ensureAllSearchContextsReleased();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests56 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader58 = null;
org.apache.lucene.index.Fields fields59 = null;
org.apache.lucene.index.Fields fields60 = null;
kuromojiAnalysisTests56.assertFieldsEquals("europarl.lines.txt.gz", indexReader58, fields59, fields60, false);
kuromojiAnalysisTests56.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain65 = kuromojiAnalysisTests56.failureAndSuccessEvents;
org.junit.rules.RuleChain ruleChain66 = kuromojiAnalysisTests56.failureAndSuccessEvents;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain66;
kuromojiAnalysisTests17.failureAndSuccessEvents = ruleChain66;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain66;
org.apache.lucene.index.IndexReader indexReader71 = null;
org.apache.lucene.index.IndexReader indexReader72 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderEquals("<unknown>", indexReader71, indexReader72);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain65);
org.junit.Assert.assertNotNull(ruleChain66);
}
@Test
public void test02127() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02127");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (byte) 10);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
org.apache.lucene.index.IndexReader indexReader7 = null;
org.apache.lucene.index.IndexReader indexReader8 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderEquals("tests.badapples", indexReader7, indexReader8);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02128() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02128");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("random", indexReader3, fields4, fields5, true);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.Fields fields10 = null;
org.apache.lucene.index.Fields fields11 = null;
kuromojiAnalysisTests1.assertFieldsEquals("enwiki.random.lines.txt", indexReader9, fields10, fields11, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests14 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Fields fields17 = null;
org.apache.lucene.index.Fields fields18 = null;
kuromojiAnalysisTests14.assertFieldsEquals("europarl.lines.txt.gz", indexReader16, fields17, fields18, false);
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum25 = null;
kuromojiAnalysisTests14.assertPositionsSkippingEquals("hi!", indexReader22, (int) (byte) 0, postingsEnum24, postingsEnum25);
kuromojiAnalysisTests14.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests14.resetCheckIndexStatus();
org.junit.Assert.assertNotEquals("tests.badapples", (java.lang.Object) "enwiki.random.lines.txt", (java.lang.Object) kuromojiAnalysisTests14);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests14.testReadingFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02129() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02129");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "tests.monster", "tests.monster", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02130() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02130");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.scaledRandomIntBetween((int) '#', (int) (short) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalArgumentException; message: max must be >= min: 35, -1");
} catch (java.lang.IllegalArgumentException e) {
// Expected exception.
}
}
@Test
public void test02131() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02131");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween((int) ' ', (int) (short) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02132() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02132");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.IndexReader indexReader18 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertTermVectorsEquals("enwiki.random.lines.txt", indexReader17, indexReader18);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02133() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02133");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween((int) '#', 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02134() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02134");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.ensureCleanedUp();
kuromojiAnalysisTests1.resetCheckIndexStatus();
org.junit.rules.TestRule testRule10 = kuromojiAnalysisTests1.ruleChain;
org.junit.Assert.assertNotNull((java.lang.Object) kuromojiAnalysisTests1);
java.util.concurrent.ExecutorService[] executorServiceArray13 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[] executorServiceArray14 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[] executorServiceArray15 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[] executorServiceArray16 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[] executorServiceArray17 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[] executorServiceArray18 = new java.util.concurrent.ExecutorService[] {};
java.util.concurrent.ExecutorService[][] executorServiceArray19 = new java.util.concurrent.ExecutorService[][] { executorServiceArray13, executorServiceArray14, executorServiceArray15, executorServiceArray16, executorServiceArray17, executorServiceArray18 };
java.util.List<java.util.concurrent.ExecutorService[]> executorServiceArrayList20 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 0, executorServiceArray19);
org.junit.Assert.assertNotSame("random", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) executorServiceArray19);
org.apache.lucene.index.IndexReader indexReader23 = null;
org.apache.lucene.index.IndexReader indexReader24 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertDeletedDocsEquals("tests.awaitsfix", indexReader23, indexReader24);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule10);
org.junit.Assert.assertNotNull(executorServiceArray13);
org.junit.Assert.assertNotNull(executorServiceArray14);
org.junit.Assert.assertNotNull(executorServiceArray15);
org.junit.Assert.assertNotNull(executorServiceArray16);
org.junit.Assert.assertNotNull(executorServiceArray17);
org.junit.Assert.assertNotNull(executorServiceArray18);
org.junit.Assert.assertNotNull(executorServiceArray19);
org.junit.Assert.assertNotNull(executorServiceArrayList20);
}
@Test
public void test02135() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02135");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy2 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy(true, (int) (byte) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02136() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02136");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02137() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02137");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
java.lang.String[] strArray14 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray14);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests16.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet15, (java.lang.Object) kuromojiAnalysisTests16);
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests16.assertDocsEnumEquals("tests.badapples", postingsEnum21, postingsEnum22, true);
org.junit.rules.TestRule testRule25 = kuromojiAnalysisTests16.ruleChain;
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests16.assertDocsSkippingEquals("tests.maxfailures", indexReader27, (int) (byte) 100, postingsEnum29, postingsEnum30, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests33 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader35 = null;
org.apache.lucene.index.Fields fields36 = null;
org.apache.lucene.index.Fields fields37 = null;
kuromojiAnalysisTests33.assertFieldsEquals("europarl.lines.txt.gz", indexReader35, fields36, fields37, false);
kuromojiAnalysisTests33.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain42 = kuromojiAnalysisTests33.failureAndSuccessEvents;
kuromojiAnalysisTests16.failureAndSuccessEvents = ruleChain42;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain42;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testBaseFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray14);
org.junit.Assert.assertNotNull(strComparableSet15);
org.junit.Assert.assertNotNull(testRule25);
org.junit.Assert.assertNotNull(ruleChain42);
}
@Test
public void test02138() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02138");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.failfast");
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.slow", indexReader11, (int) (short) 10, postingsEnum13, postingsEnum14);
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.Terms terms18 = null;
org.apache.lucene.index.Terms terms19 = null;
kuromojiAnalysisTests0.assertTermsEquals("tests.failfast", indexReader17, terms18, terms19, false);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testKuromojiEmptyUserDict();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02139() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02139");
java.util.Random random0 = null;
org.apache.lucene.util.BytesRef bytesRef2 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "<unknown>", bytesRef2, store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02140() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02140");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("hi!", indexReader9, (int) (byte) 0, postingsEnum11, postingsEnum12);
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Terms terms16 = null;
org.apache.lucene.index.Terms terms17 = null;
kuromojiAnalysisTests1.assertTermsEquals("random", indexReader15, terms16, terms17, true);
kuromojiAnalysisTests1.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("tests.nightly", postingsEnum22, postingsEnum23, true);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests26 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.Fields fields29 = null;
org.apache.lucene.index.Fields fields30 = null;
kuromojiAnalysisTests26.assertFieldsEquals("europarl.lines.txt.gz", indexReader28, fields29, fields30, false);
kuromojiAnalysisTests26.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain35 = kuromojiAnalysisTests26.failureAndSuccessEvents;
kuromojiAnalysisTests26.ensureAllSearchContextsReleased();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests37 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader39 = null;
org.apache.lucene.index.Fields fields40 = null;
org.apache.lucene.index.Fields fields41 = null;
kuromojiAnalysisTests37.assertFieldsEquals("europarl.lines.txt.gz", indexReader39, fields40, fields41, false);
org.apache.lucene.index.IndexReader indexReader45 = null;
org.apache.lucene.index.PostingsEnum postingsEnum47 = null;
org.apache.lucene.index.PostingsEnum postingsEnum48 = null;
kuromojiAnalysisTests37.assertPositionsSkippingEquals("hi!", indexReader45, (int) (byte) 0, postingsEnum47, postingsEnum48);
kuromojiAnalysisTests37.ensureCheckIndexPassed();
org.elasticsearch.index.analysis.KuromojiAnalysisTests[] kuromojiAnalysisTestsArray51 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests[] { kuromojiAnalysisTests1, kuromojiAnalysisTests26, kuromojiAnalysisTests37 };
java.util.Set<org.elasticsearch.index.analysis.KuromojiAnalysisTests> kuromojiAnalysisTestsSet52 = org.apache.lucene.util.LuceneTestCase.asSet(kuromojiAnalysisTestsArray51);
java.io.PrintStream printStream53 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.util.LuceneTestCase.dumpArray("tests.failfast", (java.lang.Object[]) kuromojiAnalysisTestsArray51, printStream53);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain35);
org.junit.Assert.assertNotNull(kuromojiAnalysisTestsArray51);
org.junit.Assert.assertNotNull(kuromojiAnalysisTestsSet52);
}
@Test
public void test02141() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02141");
long[] longArray4 = new long[] { 1 };
long[] longArray6 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray4, longArray6);
long[] longArray10 = new long[] { 1 };
long[] longArray12 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray10, longArray12);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", longArray6, longArray10);
long[] longArray17 = new long[] { 1 };
long[] longArray19 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray17, longArray19);
org.junit.Assert.assertArrayEquals("hi!", longArray10, longArray17);
long[] longArray25 = new long[] { 1 };
long[] longArray27 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray25, longArray27);
long[] longArray31 = new long[] { 1 };
long[] longArray33 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray31, longArray33);
org.junit.Assert.assertArrayEquals("random", longArray27, longArray33);
org.junit.Assert.assertArrayEquals(longArray17, longArray27);
long[] longArray39 = new long[] { 1 };
long[] longArray41 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray39, longArray41);
long[] longArray47 = new long[] { 1 };
long[] longArray49 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray47, longArray49);
long[] longArray53 = new long[] { 1 };
long[] longArray55 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray53, longArray55);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", longArray49, longArray53);
long[] longArray60 = new long[] { 1 };
long[] longArray62 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray60, longArray62);
org.junit.Assert.assertArrayEquals("hi!", longArray53, longArray60);
org.junit.Assert.assertArrayEquals(longArray41, longArray53);
long[] longArray68 = new long[] { 1 };
long[] longArray70 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray68, longArray70);
long[] longArray76 = new long[] { 1 };
long[] longArray78 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray76, longArray78);
long[] longArray82 = new long[] { 1 };
long[] longArray84 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray82, longArray84);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", longArray78, longArray82);
long[] longArray89 = new long[] { 1 };
long[] longArray91 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray89, longArray91);
org.junit.Assert.assertArrayEquals("hi!", longArray82, longArray89);
org.junit.Assert.assertArrayEquals(longArray70, longArray82);
org.junit.Assert.assertArrayEquals(longArray41, longArray82);
org.junit.Assert.assertArrayEquals(longArray17, longArray82);
org.junit.Assert.assertNotNull(longArray4);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray4), "[1]");
org.junit.Assert.assertNotNull(longArray6);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray6), "[1]");
org.junit.Assert.assertNotNull(longArray10);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray10), "[1]");
org.junit.Assert.assertNotNull(longArray12);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray12), "[1]");
org.junit.Assert.assertNotNull(longArray17);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray17), "[1]");
org.junit.Assert.assertNotNull(longArray19);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray19), "[1]");
org.junit.Assert.assertNotNull(longArray25);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray25), "[1]");
org.junit.Assert.assertNotNull(longArray27);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray27), "[1]");
org.junit.Assert.assertNotNull(longArray31);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray31), "[1]");
org.junit.Assert.assertNotNull(longArray33);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray33), "[1]");
org.junit.Assert.assertNotNull(longArray39);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray39), "[1]");
org.junit.Assert.assertNotNull(longArray41);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray41), "[1]");
org.junit.Assert.assertNotNull(longArray47);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray47), "[1]");
org.junit.Assert.assertNotNull(longArray49);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray49), "[1]");
org.junit.Assert.assertNotNull(longArray53);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray53), "[1]");
org.junit.Assert.assertNotNull(longArray55);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray55), "[1]");
org.junit.Assert.assertNotNull(longArray60);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray60), "[1]");
org.junit.Assert.assertNotNull(longArray62);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray62), "[1]");
org.junit.Assert.assertNotNull(longArray68);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray68), "[1]");
org.junit.Assert.assertNotNull(longArray70);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray70), "[1]");
org.junit.Assert.assertNotNull(longArray76);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray76), "[1]");
org.junit.Assert.assertNotNull(longArray78);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray78), "[1]");
org.junit.Assert.assertNotNull(longArray82);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray82), "[1]");
org.junit.Assert.assertNotNull(longArray84);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray84), "[1]");
org.junit.Assert.assertNotNull(longArray89);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray89), "[1]");
org.junit.Assert.assertNotNull(longArray91);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray91), "[1]");
}
@Test
public void test02142() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02142");
org.junit.Assert.assertEquals("random", (float) (-1L), (float) (short) 0, (float) 100L);
}
@Test
public void test02143() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02143");
long[] longArray3 = new long[] { 1 };
long[] longArray5 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray3, longArray5);
long[] longArray12 = new long[] { 1 };
long[] longArray14 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray12, longArray14);
long[] longArray19 = new long[] { 1 };
long[] longArray21 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray19, longArray21);
long[] longArray25 = new long[] { 1 };
long[] longArray27 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray25, longArray27);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", longArray21, longArray25);
org.junit.Assert.assertArrayEquals("enwiki.random.lines.txt", longArray12, longArray25);
long[] longArray34 = new long[] { 1 };
long[] longArray36 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray34, longArray36);
long[] longArray40 = new long[] { 1 };
long[] longArray42 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray40, longArray42);
org.junit.Assert.assertArrayEquals("random", longArray36, longArray42);
long[] longArray48 = new long[] { 1 };
long[] longArray50 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray48, longArray50);
long[] longArray55 = new long[] { 1 };
long[] longArray57 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray55, longArray57);
long[] longArray61 = new long[] { 1 };
long[] longArray63 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray61, longArray63);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", longArray57, longArray61);
org.junit.Assert.assertArrayEquals("enwiki.random.lines.txt", longArray48, longArray61);
org.junit.Assert.assertArrayEquals(longArray42, longArray48);
org.junit.Assert.assertArrayEquals("tests.slow", longArray12, longArray42);
long[] longArray72 = new long[] { 1 };
long[] longArray74 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray72, longArray74);
long[] longArray79 = new long[] { 1 };
long[] longArray81 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray79, longArray81);
long[] longArray85 = new long[] { 1 };
long[] longArray87 = new long[] { (byte) 1 };
org.junit.Assert.assertArrayEquals("", longArray85, longArray87);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", longArray81, longArray85);
org.junit.Assert.assertArrayEquals("enwiki.random.lines.txt", longArray72, longArray85);
org.junit.Assert.assertArrayEquals("<unknown>", longArray12, longArray85);
org.junit.Assert.assertArrayEquals("tests.monster", longArray3, longArray85);
org.junit.Assert.assertNotNull(longArray3);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray3), "[1]");
org.junit.Assert.assertNotNull(longArray5);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray5), "[1]");
org.junit.Assert.assertNotNull(longArray12);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray12), "[1]");
org.junit.Assert.assertNotNull(longArray14);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray14), "[1]");
org.junit.Assert.assertNotNull(longArray19);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray19), "[1]");
org.junit.Assert.assertNotNull(longArray21);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray21), "[1]");
org.junit.Assert.assertNotNull(longArray25);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray25), "[1]");
org.junit.Assert.assertNotNull(longArray27);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray27), "[1]");
org.junit.Assert.assertNotNull(longArray34);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray34), "[1]");
org.junit.Assert.assertNotNull(longArray36);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray36), "[1]");
org.junit.Assert.assertNotNull(longArray40);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray40), "[1]");
org.junit.Assert.assertNotNull(longArray42);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray42), "[1]");
org.junit.Assert.assertNotNull(longArray48);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray48), "[1]");
org.junit.Assert.assertNotNull(longArray50);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray50), "[1]");
org.junit.Assert.assertNotNull(longArray55);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray55), "[1]");
org.junit.Assert.assertNotNull(longArray57);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray57), "[1]");
org.junit.Assert.assertNotNull(longArray61);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray61), "[1]");
org.junit.Assert.assertNotNull(longArray63);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray63), "[1]");
org.junit.Assert.assertNotNull(longArray72);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray72), "[1]");
org.junit.Assert.assertNotNull(longArray74);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray74), "[1]");
org.junit.Assert.assertNotNull(longArray79);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray79), "[1]");
org.junit.Assert.assertNotNull(longArray81);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray81), "[1]");
org.junit.Assert.assertNotNull(longArray85);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray85), "[1]");
org.junit.Assert.assertNotNull(longArray87);
org.junit.Assert.assertEquals(java.util.Arrays.toString(longArray87), "[1]");
}
@Test
public void test02144() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02144");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests11 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.Fields fields14 = null;
org.apache.lucene.index.Fields fields15 = null;
kuromojiAnalysisTests11.assertFieldsEquals("europarl.lines.txt.gz", indexReader13, fields14, fields15, false);
kuromojiAnalysisTests11.ensureCleanedUp();
kuromojiAnalysisTests11.resetCheckIndexStatus();
org.junit.rules.TestRule testRule20 = kuromojiAnalysisTests11.ruleChain;
org.junit.Assert.assertNotSame("hi!", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) testRule20);
kuromojiAnalysisTests1.setIndexWriterMaxDocs((int) (byte) 0);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testKuromojiUserDict();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertNotNull(testRule20);
}
@Test
public void test02145() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02145");
org.junit.Assert.assertNotEquals("tests.weekly", (double) (short) -1, (double) 0.0f, (double) (short) -1);
}
@Test
public void test02146() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02146");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.TermsEnum termsEnum14 = null;
org.apache.lucene.index.TermsEnum termsEnum15 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermStatsEquals("enwiki.random.lines.txt", termsEnum14, termsEnum15);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02147() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02147");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path2 = org.apache.lucene.util.LuceneTestCase.createTempFile("tests.nightly", "hi!");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02148() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02148");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.setUp();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("", indexReader17, (int) '#', postingsEnum19, postingsEnum20);
org.apache.lucene.index.IndexReader indexReader23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum25 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.weekly", indexReader23, (int) (short) 10, postingsEnum25, postingsEnum26);
java.lang.String str28 = kuromojiAnalysisTests1.getTestName();
org.junit.rules.RuleChain ruleChain29 = null;
kuromojiAnalysisTests1.failureAndSuccessEvents = ruleChain29;
org.apache.lucene.index.IndexReader indexReader32 = null;
org.apache.lucene.index.IndexReader indexReader33 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertTermVectorsEquals("europarl.lines.txt.gz", indexReader32, indexReader33);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
org.junit.Assert.assertEquals("'" + str28 + "' != '" + "<unknown>" + "'", str28, "<unknown>");
}
@Test
public void test02149() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02149");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Fields fields17 = null;
org.apache.lucene.index.Fields fields18 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.slow", indexReader16, fields17, fields18, false);
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("hi!", postingsEnum22, postingsEnum23, true);
org.junit.rules.TestRule testRule26 = kuromojiAnalysisTests0.ruleChain;
org.apache.lucene.index.Terms terms28 = null;
org.apache.lucene.index.Terms terms29 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsStatisticsEquals("tests.maxfailures", terms28, terms29);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule26);
}
@Test
public void test02150() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02150");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("random", indexReader9, (int) '4', postingsEnum11, postingsEnum12);
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum18 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.maxfailures", indexReader15, 10, postingsEnum17, postingsEnum18);
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.index.analysis.AnalysisService analysisService20 = kuromojiAnalysisTests0.createAnalysisService();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02151() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02151");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests9.assertDocsEnumEquals("tests.badapples", postingsEnum14, postingsEnum15, true);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests9.ruleChain;
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests9.assertDocsSkippingEquals("tests.maxfailures", indexReader20, (int) (byte) 100, postingsEnum22, postingsEnum23, false);
kuromojiAnalysisTests9.resetCheckIndexStatus();
kuromojiAnalysisTests9.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.Terms terms30 = null;
org.apache.lucene.index.Terms terms31 = null;
kuromojiAnalysisTests9.assertTermsEquals("hi!", indexReader29, terms30, terms31, false);
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.index.analysis.AnalysisService analysisService34 = kuromojiAnalysisTests9.createAnalysisService();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02152() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02152");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfCodepointLengthBetween((int) 'a', 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02153() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02153");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
java.io.Reader reader10 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertCharFilterEquals(reader10, "");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02154() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02154");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests9.assertDocsEnumEquals("tests.badapples", postingsEnum14, postingsEnum15, true);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests9.ruleChain;
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests9.assertDocsSkippingEquals("tests.maxfailures", indexReader20, (int) (byte) 100, postingsEnum22, postingsEnum23, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests26 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.Fields fields29 = null;
org.apache.lucene.index.Fields fields30 = null;
kuromojiAnalysisTests26.assertFieldsEquals("europarl.lines.txt.gz", indexReader28, fields29, fields30, false);
kuromojiAnalysisTests26.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain35 = kuromojiAnalysisTests26.failureAndSuccessEvents;
kuromojiAnalysisTests9.failureAndSuccessEvents = ruleChain35;
org.apache.lucene.index.IndexableField indexableField38 = null;
org.apache.lucene.index.IndexableField indexableField39 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests9.assertStoredFieldEquals("tests.badapples", indexableField38, indexableField39);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
org.junit.Assert.assertNotNull(testRule18);
org.junit.Assert.assertNotNull(ruleChain35);
}
@Test
public void test02155() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02155");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween((int) '#', 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02156() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02156");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.ensureCleanedUp();
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path11 = kuromojiAnalysisTests0.getDataPath("<unknown>");
org.junit.Assert.fail("Expected exception of type java.lang.RuntimeException; message: resource not found: <unknown>");
} catch (java.lang.RuntimeException e) {
// Expected exception.
}
}
@Test
public void test02157() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02157");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((-1));
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.monster");
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.junit.Assert.assertNotNull((java.lang.Object) kuromojiAnalysisTests0);
org.apache.lucene.index.Fields fields27 = null;
org.apache.lucene.index.Fields fields28 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertFieldStatisticsEquals("tests.failfast", fields27, fields28);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02158() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02158");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.iterations(10, 0);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalArgumentException; message: max must be >= min: 10, 0");
} catch (java.lang.IllegalArgumentException e) {
// Expected exception.
}
}
@Test
public void test02159() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02159");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
kuromojiAnalysisTests1.restoreIndexWriterMaxDocs();
org.junit.rules.TestRule testRule13 = kuromojiAnalysisTests1.ruleChain;
java.util.Locale locale19 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale21 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale23 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale25 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale27 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray28 = new java.util.Locale[] { locale19, locale21, locale23, locale25, locale27 };
java.util.Set<java.util.Locale> localeSet29 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray28);
java.util.List<java.io.Serializable> serializableList30 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray28);
org.junit.Assert.assertNotSame("", (java.lang.Object) localeArray28, (java.lang.Object) 0.0f);
java.util.Locale locale36 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale38 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale40 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale42 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale44 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray45 = new java.util.Locale[] { locale36, locale38, locale40, locale42, locale44 };
java.util.Set<java.util.Locale> localeSet46 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray45);
java.util.List<java.io.Serializable> serializableList47 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray45);
org.junit.Assert.assertNotSame("", (java.lang.Object) localeArray45, (java.lang.Object) 0.0f);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", (java.lang.Object[]) localeArray28, (java.lang.Object[]) localeArray45);
java.util.Locale locale52 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale54 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale56 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale58 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale60 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray61 = new java.util.Locale[] { locale52, locale54, locale56, locale58, locale60 };
java.util.Set<java.util.Locale> localeSet62 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray61);
org.junit.Assert.assertArrayEquals("tests.nightly", (java.lang.Object[]) localeArray28, (java.lang.Object[]) localeArray61);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) localeArray61);
java.io.PrintStream printStream65 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.util.LuceneTestCase.dumpArray("enwiki.random.lines.txt", (java.lang.Object[]) localeArray61, printStream65);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertNotNull(testRule13);
org.junit.Assert.assertNotNull(locale19);
org.junit.Assert.assertEquals(locale19.toString(), "");
org.junit.Assert.assertNotNull(locale21);
org.junit.Assert.assertEquals(locale21.toString(), "");
org.junit.Assert.assertNotNull(locale23);
org.junit.Assert.assertEquals(locale23.toString(), "");
org.junit.Assert.assertNotNull(locale25);
org.junit.Assert.assertEquals(locale25.toString(), "");
org.junit.Assert.assertNotNull(locale27);
org.junit.Assert.assertEquals(locale27.toString(), "");
org.junit.Assert.assertNotNull(localeArray28);
org.junit.Assert.assertNotNull(localeSet29);
org.junit.Assert.assertNotNull(serializableList30);
org.junit.Assert.assertNotNull(locale36);
org.junit.Assert.assertEquals(locale36.toString(), "");
org.junit.Assert.assertNotNull(locale38);
org.junit.Assert.assertEquals(locale38.toString(), "");
org.junit.Assert.assertNotNull(locale40);
org.junit.Assert.assertEquals(locale40.toString(), "");
org.junit.Assert.assertNotNull(locale42);
org.junit.Assert.assertEquals(locale42.toString(), "");
org.junit.Assert.assertNotNull(locale44);
org.junit.Assert.assertEquals(locale44.toString(), "");
org.junit.Assert.assertNotNull(localeArray45);
org.junit.Assert.assertNotNull(localeSet46);
org.junit.Assert.assertNotNull(serializableList47);
org.junit.Assert.assertNotNull(locale52);
org.junit.Assert.assertEquals(locale52.toString(), "");
org.junit.Assert.assertNotNull(locale54);
org.junit.Assert.assertEquals(locale54.toString(), "");
org.junit.Assert.assertNotNull(locale56);
org.junit.Assert.assertEquals(locale56.toString(), "");
org.junit.Assert.assertNotNull(locale58);
org.junit.Assert.assertEquals(locale58.toString(), "");
org.junit.Assert.assertNotNull(locale60);
org.junit.Assert.assertEquals(locale60.toString(), "");
org.junit.Assert.assertNotNull(localeArray61);
org.junit.Assert.assertNotNull(localeSet62);
}
@Test
public void test02160() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02160");
// The following exception was thrown during execution in test generation
try {
int int1 = org.elasticsearch.test.ESTestCase.randomInt((int) ' ');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02161() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02161");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests11 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.Fields fields14 = null;
org.apache.lucene.index.Fields fields15 = null;
kuromojiAnalysisTests11.assertFieldsEquals("europarl.lines.txt.gz", indexReader13, fields14, fields15, false);
kuromojiAnalysisTests11.ensureCleanedUp();
kuromojiAnalysisTests11.resetCheckIndexStatus();
org.junit.rules.TestRule testRule20 = kuromojiAnalysisTests11.ruleChain;
org.junit.Assert.assertNotSame("hi!", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) testRule20);
kuromojiAnalysisTests1.setIndexWriterMaxDocs((int) (byte) 0);
org.junit.rules.TestRule testRule24 = kuromojiAnalysisTests1.ruleChain;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testKuromojiEmptyUserDict();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertNotNull(testRule20);
org.junit.Assert.assertNotNull(testRule24);
}
@Test
public void test02162() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02162");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
java.lang.String str14 = kuromojiAnalysisTests1.getTestName();
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.PostingsEnum postingsEnum18 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.failfast", indexReader16, 0, postingsEnum18, postingsEnum19);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
org.junit.Assert.assertEquals("'" + str14 + "' != '" + "<unknown>" + "'", str14, "<unknown>");
}
@Test
public void test02163() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02163");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests9.assertDocsEnumEquals("tests.badapples", postingsEnum14, postingsEnum15, true);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests9.ruleChain;
kuromojiAnalysisTests9.setUp();
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.Terms terms22 = null;
org.apache.lucene.index.Terms terms23 = null;
kuromojiAnalysisTests9.assertTermsEquals("tests.slow", indexReader21, terms22, terms23, false);
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (short) 1);
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 0);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests9.testReadingFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02164() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02164");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfCodepointLengthBetween(1, (int) (byte) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02165() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02165");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.apache.lucene.index.IndexableField indexableField13 = null;
org.apache.lucene.index.IndexableField indexableField14 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertStoredFieldEquals("tests.weekly", indexableField13, indexableField14);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02166() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02166");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.TermsEnum termsEnum9 = null;
org.apache.lucene.index.TermsEnum termsEnum10 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("tests.failfast", indexReader8, termsEnum9, termsEnum10, true);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02167() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02167");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.index.analysis.AnalysisService analysisService16 = kuromojiAnalysisTests0.createAnalysisService();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02168() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02168");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomAsciiOfLengthBetween((-1), (int) (byte) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02169() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02169");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("random", indexReader2, fields3, fields4, true);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.Fields fields9 = null;
org.apache.lucene.index.Fields fields10 = null;
kuromojiAnalysisTests0.assertFieldsEquals("enwiki.random.lines.txt", indexReader8, fields9, fields10, false);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.IndexReader indexReader15 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderStatisticsEquals("tests.awaitsfix", indexReader14, indexReader15);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02170() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02170");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests9.assertDocsEnumEquals("tests.badapples", postingsEnum14, postingsEnum15, true);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests9.ruleChain;
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests9.assertDocsSkippingEquals("tests.maxfailures", indexReader20, (int) (byte) 100, postingsEnum22, postingsEnum23, false);
kuromojiAnalysisTests9.resetCheckIndexStatus();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests9.testKatakanaStemFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02171() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02171");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
java.lang.Class<?> wildcardClass11 = kuromojiAnalysisTests0.getClass();
org.junit.Assert.assertNotNull(wildcardClass11);
}
@Test
public void test02172() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02172");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newStringField("<unknown>", "tests.monster", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02173() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02173");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween((int) (byte) 1, (int) ' ');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02174() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02174");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween((int) '#', (int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02175() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02175");
org.apache.lucene.search.QueryCachingPolicy queryCachingPolicy0 = org.apache.lucene.util.LuceneTestCase.MAYBE_CACHE_POLICY;
org.apache.lucene.search.QueryCachingPolicy queryCachingPolicy1 = org.apache.lucene.util.LuceneTestCase.MAYBE_CACHE_POLICY;
org.apache.lucene.search.QueryCachingPolicy queryCachingPolicy2 = org.apache.lucene.util.LuceneTestCase.MAYBE_CACHE_POLICY;
org.apache.lucene.search.QueryCachingPolicy queryCachingPolicy3 = org.apache.lucene.util.LuceneTestCase.MAYBE_CACHE_POLICY;
org.apache.lucene.search.QueryCachingPolicy queryCachingPolicy4 = org.apache.lucene.util.LuceneTestCase.MAYBE_CACHE_POLICY;
org.apache.lucene.search.QueryCachingPolicy[] queryCachingPolicyArray5 = new org.apache.lucene.search.QueryCachingPolicy[] { queryCachingPolicy0, queryCachingPolicy1, queryCachingPolicy2, queryCachingPolicy3, queryCachingPolicy4 };
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.search.QueryCachingPolicy queryCachingPolicy6 = org.elasticsearch.test.ESTestCase.randomFrom(queryCachingPolicyArray5);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(queryCachingPolicy0);
org.junit.Assert.assertNotNull(queryCachingPolicy1);
org.junit.Assert.assertNotNull(queryCachingPolicy2);
org.junit.Assert.assertNotNull(queryCachingPolicy3);
org.junit.Assert.assertNotNull(queryCachingPolicy4);
org.junit.Assert.assertNotNull(queryCachingPolicyArray5);
}
@Test
public void test02176() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02176");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.IndexReader indexReader15 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderStatisticsEquals("enwiki.random.lines.txt", indexReader14, indexReader15);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02177() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02177");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.setUp();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("", indexReader17, (int) '#', postingsEnum19, postingsEnum20);
org.apache.lucene.index.IndexReader indexReader23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum25 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.weekly", indexReader23, (int) (short) 10, postingsEnum25, postingsEnum26);
java.lang.String str28 = kuromojiAnalysisTests1.getTestName();
kuromojiAnalysisTests1.ensureCleanedUp();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
org.junit.Assert.assertEquals("'" + str28 + "' != '" + "<unknown>" + "'", str28, "<unknown>");
}
@Test
public void test02178() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02178");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain10;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain10;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests13.assertFieldsEquals("europarl.lines.txt.gz", indexReader15, fields16, fields17, false);
kuromojiAnalysisTests13.ensureCleanedUp();
kuromojiAnalysisTests13.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests13.tearDown();
kuromojiAnalysisTests13.ensureAllSearchContextsReleased();
kuromojiAnalysisTests13.ensureCleanedUp();
org.junit.Assert.assertNotEquals((java.lang.Object) ruleChain10, (java.lang.Object) kuromojiAnalysisTests13);
org.junit.Assert.assertNotNull("<unknown>", (java.lang.Object) kuromojiAnalysisTests13);
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests13.assertDocsEnumEquals("<unknown>", postingsEnum29, postingsEnum30, true);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests13.testKuromojiEmptyUserDict();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
}
@Test
public void test02179() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02179");
// The following exception was thrown during execution in test generation
try {
int int1 = org.apache.lucene.util.LuceneTestCase.atLeast((int) (short) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02180() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02180");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((-1));
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testKatakanaStemFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02181() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02181");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.ensureCleanedUp();
kuromojiAnalysisTests1.resetCheckIndexStatus();
org.junit.rules.TestRule testRule10 = kuromojiAnalysisTests1.ruleChain;
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("enwiki.random.lines.txt", indexReader12, (int) (short) -1, postingsEnum14, postingsEnum15);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests17 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.Fields fields20 = null;
org.apache.lucene.index.Fields fields21 = null;
kuromojiAnalysisTests17.assertFieldsEquals("europarl.lines.txt.gz", indexReader19, fields20, fields21, false);
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum28 = null;
kuromojiAnalysisTests17.assertPositionsSkippingEquals("hi!", indexReader25, (int) (byte) 0, postingsEnum27, postingsEnum28);
org.apache.lucene.index.IndexReader indexReader31 = null;
org.apache.lucene.index.Terms terms32 = null;
org.apache.lucene.index.Terms terms33 = null;
kuromojiAnalysisTests17.assertTermsEquals("random", indexReader31, terms32, terms33, true);
kuromojiAnalysisTests17.setUp();
org.apache.lucene.index.IndexReader indexReader38 = null;
org.apache.lucene.index.PostingsEnum postingsEnum40 = null;
org.apache.lucene.index.PostingsEnum postingsEnum41 = null;
kuromojiAnalysisTests17.assertPositionsSkippingEquals("tests.failfast", indexReader38, (int) '4', postingsEnum40, postingsEnum41);
kuromojiAnalysisTests17.setIndexWriterMaxDocs(100);
org.junit.Assert.assertNotEquals("tests.awaitsfix", (java.lang.Object) "enwiki.random.lines.txt", (java.lang.Object) kuromojiAnalysisTests17);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests17.testBaseFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule10);
}
@Test
public void test02182() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02182");
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray3 = org.elasticsearch.test.ESTestCase.generateRandomStringArray((int) (byte) 10, (int) '#', false);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02183() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02183");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.ensureCheckIndexPassed();
org.junit.rules.TestRule testRule14 = kuromojiAnalysisTests0.ruleChain;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule14);
}
@Test
public void test02184() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02184");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("<unknown>", indexReader14, (int) '#', postingsEnum16, postingsEnum17);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.nightly");
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.IndexReader indexReader23 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDocValuesEquals("tests.failfast", indexReader22, indexReader23);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02185() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02185");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.setUp();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("", indexReader17, (int) '#', postingsEnum19, postingsEnum20);
org.apache.lucene.index.IndexReader indexReader23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum25 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.weekly", indexReader23, (int) (short) 10, postingsEnum25, postingsEnum26);
java.io.Reader reader28 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertCharFilterEquals(reader28, "enwiki.random.lines.txt");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02186() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02186");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Fields fields15 = null;
org.apache.lucene.index.Fields fields16 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.slow", indexReader14, fields15, fields16, true);
org.junit.rules.TestRule testRule19 = kuromojiAnalysisTests0.ruleChain;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testIterationMarkCharFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule19);
}
@Test
public void test02187() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02187");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.ensureCleanedUp();
kuromojiAnalysisTests1.resetCheckIndexStatus();
kuromojiAnalysisTests1.ensureCleanedUp();
kuromojiAnalysisTests1.ensureCheckIndexPassed();
kuromojiAnalysisTests1.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
kuromojiAnalysisTests1.assertDocsSkippingEquals("tests.weekly", indexReader14, (int) (short) 100, postingsEnum16, postingsEnum17, true);
java.lang.Class<?> wildcardClass20 = kuromojiAnalysisTests1.getClass();
java.lang.Object obj21 = null;
org.junit.Assert.assertNotEquals("enwiki.random.lines.txt", (java.lang.Object) kuromojiAnalysisTests1, obj21);
org.junit.Assert.assertNotNull(wildcardClass20);
}
@Test
public void test02188() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02188");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.between((int) '#', (int) (byte) 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02189() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02189");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.failfast", indexReader9, 1, postingsEnum11, postingsEnum12);
kuromojiAnalysisTests1.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests1.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum18 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("tests.nightly", postingsEnum17, postingsEnum18, true);
org.junit.Assert.assertNotSame((java.lang.Object) 100, (java.lang.Object) "tests.nightly");
}
@Test
public void test02190() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02190");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule9 = kuromojiAnalysisTests0.ruleChain;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests10 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.Fields fields13 = null;
org.apache.lucene.index.Fields fields14 = null;
kuromojiAnalysisTests10.assertFieldsEquals("europarl.lines.txt.gz", indexReader12, fields13, fields14, false);
kuromojiAnalysisTests10.ensureCleanedUp();
kuromojiAnalysisTests10.ensureCleanedUp();
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests10);
org.apache.lucene.index.TermsEnum termsEnum21 = null;
org.apache.lucene.index.TermsEnum termsEnum22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermStatsEquals("hi!", termsEnum21, termsEnum22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule9);
}
@Test
public void test02191() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02191");
java.util.Locale locale3 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale5 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale7 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale9 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale11 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray12 = new java.util.Locale[] { locale3, locale5, locale7, locale9, locale11 };
java.util.Set<java.util.Locale> localeSet13 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray12);
java.util.Locale locale16 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale18 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale20 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale22 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale24 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray25 = new java.util.Locale[] { locale16, locale18, locale20, locale22, locale24 };
java.util.Set<java.util.Locale> localeSet26 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray25);
java.util.List<java.io.Serializable> serializableList27 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray25);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray12, (java.lang.Object[]) localeArray25);
java.util.Locale locale31 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale33 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale35 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale39 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray40 = new java.util.Locale[] { locale31, locale33, locale35, locale37, locale39 };
java.util.Set<java.util.Locale> localeSet41 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray40);
java.util.List<java.io.Serializable> serializableList42 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray40);
java.util.Set<java.lang.Cloneable> cloneableSet43 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray40);
org.junit.Assert.assertArrayEquals("tests.slow", (java.lang.Object[]) localeArray25, (java.lang.Object[]) localeArray40);
org.junit.Assert.assertNotSame((java.lang.Object) 0.0f, (java.lang.Object) localeArray40);
java.util.Locale locale48 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale50 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale52 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale54 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale56 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray57 = new java.util.Locale[] { locale48, locale50, locale52, locale54, locale56 };
java.util.Set<java.util.Locale> localeSet58 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray57);
java.util.List<java.io.Serializable> serializableList59 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray57);
java.util.Set<java.lang.Cloneable> cloneableSet60 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray57);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray57, (java.lang.Object) (byte) -1);
java.util.Locale locale65 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale67 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale69 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale71 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale73 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray74 = new java.util.Locale[] { locale65, locale67, locale69, locale71, locale73 };
java.util.Set<java.util.Locale> localeSet75 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray74);
java.util.List<java.io.Serializable> serializableList76 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray74);
java.util.Set<java.lang.Cloneable> cloneableSet77 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray74);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray74, (java.lang.Object) (byte) -1);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray57, (java.lang.Object[]) localeArray74);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray40, (java.lang.Object[]) localeArray74);
java.lang.Class<?> wildcardClass82 = localeArray74.getClass();
org.junit.Assert.assertNotNull(locale3);
org.junit.Assert.assertEquals(locale3.toString(), "");
org.junit.Assert.assertNotNull(locale5);
org.junit.Assert.assertEquals(locale5.toString(), "");
org.junit.Assert.assertNotNull(locale7);
org.junit.Assert.assertEquals(locale7.toString(), "");
org.junit.Assert.assertNotNull(locale9);
org.junit.Assert.assertEquals(locale9.toString(), "");
org.junit.Assert.assertNotNull(locale11);
org.junit.Assert.assertEquals(locale11.toString(), "");
org.junit.Assert.assertNotNull(localeArray12);
org.junit.Assert.assertNotNull(localeSet13);
org.junit.Assert.assertNotNull(locale16);
org.junit.Assert.assertEquals(locale16.toString(), "");
org.junit.Assert.assertNotNull(locale18);
org.junit.Assert.assertEquals(locale18.toString(), "");
org.junit.Assert.assertNotNull(locale20);
org.junit.Assert.assertEquals(locale20.toString(), "");
org.junit.Assert.assertNotNull(locale22);
org.junit.Assert.assertEquals(locale22.toString(), "");
org.junit.Assert.assertNotNull(locale24);
org.junit.Assert.assertEquals(locale24.toString(), "");
org.junit.Assert.assertNotNull(localeArray25);
org.junit.Assert.assertNotNull(localeSet26);
org.junit.Assert.assertNotNull(serializableList27);
org.junit.Assert.assertNotNull(locale31);
org.junit.Assert.assertEquals(locale31.toString(), "");
org.junit.Assert.assertNotNull(locale33);
org.junit.Assert.assertEquals(locale33.toString(), "");
org.junit.Assert.assertNotNull(locale35);
org.junit.Assert.assertEquals(locale35.toString(), "");
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "");
org.junit.Assert.assertNotNull(locale39);
org.junit.Assert.assertEquals(locale39.toString(), "");
org.junit.Assert.assertNotNull(localeArray40);
org.junit.Assert.assertNotNull(localeSet41);
org.junit.Assert.assertNotNull(serializableList42);
org.junit.Assert.assertNotNull(cloneableSet43);
org.junit.Assert.assertNotNull(locale48);
org.junit.Assert.assertEquals(locale48.toString(), "");
org.junit.Assert.assertNotNull(locale50);
org.junit.Assert.assertEquals(locale50.toString(), "");
org.junit.Assert.assertNotNull(locale52);
org.junit.Assert.assertEquals(locale52.toString(), "");
org.junit.Assert.assertNotNull(locale54);
org.junit.Assert.assertEquals(locale54.toString(), "");
org.junit.Assert.assertNotNull(locale56);
org.junit.Assert.assertEquals(locale56.toString(), "");
org.junit.Assert.assertNotNull(localeArray57);
org.junit.Assert.assertNotNull(localeSet58);
org.junit.Assert.assertNotNull(serializableList59);
org.junit.Assert.assertNotNull(cloneableSet60);
org.junit.Assert.assertNotNull(locale65);
org.junit.Assert.assertEquals(locale65.toString(), "");
org.junit.Assert.assertNotNull(locale67);
org.junit.Assert.assertEquals(locale67.toString(), "");
org.junit.Assert.assertNotNull(locale69);
org.junit.Assert.assertEquals(locale69.toString(), "");
org.junit.Assert.assertNotNull(locale71);
org.junit.Assert.assertEquals(locale71.toString(), "");
org.junit.Assert.assertNotNull(locale73);
org.junit.Assert.assertEquals(locale73.toString(), "");
org.junit.Assert.assertNotNull(localeArray74);
org.junit.Assert.assertNotNull(localeSet75);
org.junit.Assert.assertNotNull(serializableList76);
org.junit.Assert.assertNotNull(cloneableSet77);
org.junit.Assert.assertNotNull(wildcardClass82);
}
@Test
public void test02192() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02192");
org.junit.Assert.assertEquals(1L, 1L);
}
@Test
public void test02193() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02193");
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray3 = org.elasticsearch.test.ESTestCase.generateRandomStringArray((-1), (int) ' ', true);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02194() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02194");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween((int) (byte) 0, (int) (byte) 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02195() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02195");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween((int) (short) 10, (int) (byte) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02196() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02196");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newTextField(random0, "tests.awaitsfix", "tests.monster", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02197() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02197");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newTextField(random0, "tests.nightly", "hi!", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02198() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02198");
org.apache.lucene.util.LuceneTestCase.assumeFalse("tests.maxfailures", false);
}
@Test
public void test02199() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02199");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.Terms terms12 = null;
org.apache.lucene.index.Terms terms13 = null;
kuromojiAnalysisTests0.assertTermsEquals("europarl.lines.txt.gz", indexReader11, terms12, terms13, true);
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray16 = kuromojiAnalysisTests0.tmpPaths();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02200() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02200");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newStringField("tests.badapples", "tests.slow", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02201() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02201");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy2 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy(false, (int) (short) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02202() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02202");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader21, (int) '4', postingsEnum23, postingsEnum24);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(100);
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.IndexReader indexReader30 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDocValuesEquals("tests.failfast", indexReader29, indexReader30);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02203() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02203");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.TestRule testRule9 = kuromojiAnalysisTests0.ruleChain;
org.junit.rules.TestRule testRule10 = kuromojiAnalysisTests0.ruleChain;
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.slow", indexReader12, (int) (short) 1, postingsEnum14, postingsEnum15);
org.junit.rules.TestRule testRule17 = kuromojiAnalysisTests0.ruleChain;
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.tearDown();
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.IndexReader indexReader22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertNormsEquals("tests.awaitsfix", indexReader21, indexReader22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule9);
org.junit.Assert.assertNotNull(testRule10);
org.junit.Assert.assertNotNull(testRule17);
}
@Test
public void test02204() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02204");
org.junit.Assert.assertNotEquals((long) (byte) 1, 10L);
}
@Test
public void test02205() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02205");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.tearDown();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02206() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02206");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.setUp();
kuromojiAnalysisTests1.ensureCheckIndexPassed();
java.nio.file.Path path17 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertPathHasBeenCleared(path17);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02207() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02207");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.Terms terms12 = null;
org.apache.lucene.index.Terms terms13 = null;
kuromojiAnalysisTests0.assertTermsEquals("europarl.lines.txt.gz", indexReader11, terms12, terms13, true);
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.IndexReader indexReader18 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDeletedDocsEquals("tests.failfast", indexReader17, indexReader18);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02208() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02208");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.between((int) '#', (int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02209() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02209");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newTextField("tests.nightly", "hi!", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02210() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02210");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.setUp();
kuromojiAnalysisTests1.tearDown();
java.lang.String str16 = kuromojiAnalysisTests1.getTestName();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.IndexReader indexReader19 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertStoredFieldsEquals("tests.maxfailures", indexReader18, indexReader19);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
org.junit.Assert.assertEquals("'" + str16 + "' != '" + "<unknown>" + "'", str16, "<unknown>");
}
@Test
public void test02211() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02211");
org.junit.Assert.assertNotEquals((long) 10, 100L);
}
@Test
public void test02212() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02212");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testKuromojiUserDict();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02213() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02213");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain9 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.assertPathHasBeenCleared("random");
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("tests.failfast", indexReader14, terms15, terms16, true);
org.apache.lucene.index.TermsEnum termsEnum20 = null;
org.apache.lucene.index.TermsEnum termsEnum21 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermStatsEquals("europarl.lines.txt.gz", termsEnum20, termsEnum21);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain9);
}
@Test
public void test02214() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02214");
// The following exception was thrown during execution in test generation
try {
java.lang.String str1 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLength((int) ' ');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02215() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02215");
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray3 = org.elasticsearch.test.ESTestCase.generateRandomStringArray(0, (int) (byte) 10, true);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02216() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02216");
org.junit.Assert.assertEquals("tests.monster", (float) 1, (float) 1L, (float) ' ');
}
@Test
public void test02217() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02217");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
kuromojiAnalysisTests2.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain11 = kuromojiAnalysisTests2.failureAndSuccessEvents;
kuromojiAnalysisTests2.resetCheckIndexStatus();
java.lang.String str13 = kuromojiAnalysisTests2.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests2);
kuromojiAnalysisTests2.tearDown();
kuromojiAnalysisTests2.overrideTestDefaultQueryCache();
org.junit.rules.RuleChain ruleChain17 = kuromojiAnalysisTests2.failureAndSuccessEvents;
kuromojiAnalysisTests2.tearDown();
org.junit.Assert.assertNotNull("hi!", (java.lang.Object) kuromojiAnalysisTests2);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests2.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain11);
org.junit.Assert.assertEquals("'" + str13 + "' != '" + "<unknown>" + "'", str13, "<unknown>");
org.junit.Assert.assertNotNull(ruleChain17);
}
@Test
public void test02218() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02218");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str10 = kuromojiAnalysisTests0.getTestName();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.IndexReader indexReader14 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDeletedDocsEquals("tests.awaitsfix", indexReader13, indexReader14);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str10 + "' != '" + "<unknown>" + "'", str10, "<unknown>");
}
@Test
public void test02219() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02219");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomAsciiOfLengthBetween(100, 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02220() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02220");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "hi!", "random", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02221() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02221");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.scaledRandomIntBetween((int) (byte) 1, (int) '4');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02222() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02222");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
kuromojiAnalysisTests0.ensureCleanedUp();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.Fields fields19 = null;
org.apache.lucene.index.Fields fields20 = null;
kuromojiAnalysisTests16.assertFieldsEquals("europarl.lines.txt.gz", indexReader18, fields19, fields20, false);
kuromojiAnalysisTests16.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain25 = kuromojiAnalysisTests16.failureAndSuccessEvents;
kuromojiAnalysisTests16.setUp();
java.util.Locale locale29 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale31 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale33 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale35 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray38 = new java.util.Locale[] { locale29, locale31, locale33, locale35, locale37 };
java.util.Set<java.util.Locale> localeSet39 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray38);
java.util.Locale locale42 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale44 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale46 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale48 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale50 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray51 = new java.util.Locale[] { locale42, locale44, locale46, locale48, locale50 };
java.util.Set<java.util.Locale> localeSet52 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray51);
java.util.List<java.io.Serializable> serializableList53 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray51);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray38, (java.lang.Object[]) localeArray51);
java.util.Locale locale57 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale59 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale61 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale63 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale65 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray66 = new java.util.Locale[] { locale57, locale59, locale61, locale63, locale65 };
java.util.Set<java.util.Locale> localeSet67 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray66);
java.util.List<java.io.Serializable> serializableList68 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray66);
java.util.Set<java.lang.Cloneable> cloneableSet69 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray66);
org.junit.Assert.assertArrayEquals("tests.slow", (java.lang.Object[]) localeArray51, (java.lang.Object[]) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests16, (java.lang.Object) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests16);
org.apache.lucene.index.Fields fields74 = null;
org.apache.lucene.index.Fields fields75 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertFieldStatisticsEquals("tests.badapples", fields74, fields75);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain25);
org.junit.Assert.assertNotNull(locale29);
org.junit.Assert.assertEquals(locale29.toString(), "");
org.junit.Assert.assertNotNull(locale31);
org.junit.Assert.assertEquals(locale31.toString(), "");
org.junit.Assert.assertNotNull(locale33);
org.junit.Assert.assertEquals(locale33.toString(), "");
org.junit.Assert.assertNotNull(locale35);
org.junit.Assert.assertEquals(locale35.toString(), "");
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "");
org.junit.Assert.assertNotNull(localeArray38);
org.junit.Assert.assertNotNull(localeSet39);
org.junit.Assert.assertNotNull(locale42);
org.junit.Assert.assertEquals(locale42.toString(), "");
org.junit.Assert.assertNotNull(locale44);
org.junit.Assert.assertEquals(locale44.toString(), "");
org.junit.Assert.assertNotNull(locale46);
org.junit.Assert.assertEquals(locale46.toString(), "");
org.junit.Assert.assertNotNull(locale48);
org.junit.Assert.assertEquals(locale48.toString(), "");
org.junit.Assert.assertNotNull(locale50);
org.junit.Assert.assertEquals(locale50.toString(), "");
org.junit.Assert.assertNotNull(localeArray51);
org.junit.Assert.assertNotNull(localeSet52);
org.junit.Assert.assertNotNull(serializableList53);
org.junit.Assert.assertNotNull(locale57);
org.junit.Assert.assertEquals(locale57.toString(), "");
org.junit.Assert.assertNotNull(locale59);
org.junit.Assert.assertEquals(locale59.toString(), "");
org.junit.Assert.assertNotNull(locale61);
org.junit.Assert.assertEquals(locale61.toString(), "");
org.junit.Assert.assertNotNull(locale63);
org.junit.Assert.assertEquals(locale63.toString(), "");
org.junit.Assert.assertNotNull(locale65);
org.junit.Assert.assertEquals(locale65.toString(), "");
org.junit.Assert.assertNotNull(localeArray66);
org.junit.Assert.assertNotNull(localeSet67);
org.junit.Assert.assertNotNull(serializableList68);
org.junit.Assert.assertNotNull(cloneableSet69);
}
@Test
public void test02223() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02223");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
java.lang.String str11 = kuromojiAnalysisTests0.getTestName();
java.lang.String str12 = kuromojiAnalysisTests0.getTestName();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str11 + "' != '" + "<unknown>" + "'", str11, "<unknown>");
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02224() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02224");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween((int) (byte) -1, (-1));
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02225() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02225");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween((int) '4', (int) (byte) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02226() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02226");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.Fields fields14 = null;
org.apache.lucene.index.Fields fields15 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.awaitsfix", indexReader13, fields14, fields15, true);
java.io.Reader reader18 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertCharFilterEquals(reader18, "hi!");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02227() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02227");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.resetCheckIndexStatus();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testKatakanaStemFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02228() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02228");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween((int) (short) 10, (int) (byte) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02229() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02229");
org.junit.Assert.assertNotEquals((long) 0, (long) 1);
}
@Test
public void test02230() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02230");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newStringField("hi!", "tests.nightly", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02231() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02231");
short[] shortArray3 = new short[] { (short) 10 };
short[] shortArray5 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray3, shortArray5);
short[] shortArray9 = new short[] { (short) 10 };
short[] shortArray11 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray9, shortArray11);
org.junit.Assert.assertArrayEquals("tests.badapples", shortArray5, shortArray11);
short[] shortArray16 = new short[] { (short) 10 };
short[] shortArray18 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray16, shortArray18);
org.junit.Assert.assertArrayEquals(shortArray11, shortArray16);
short[] shortArray23 = new short[] { (short) 10 };
short[] shortArray25 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray23, shortArray25);
short[] shortArray30 = new short[] { (short) 10 };
short[] shortArray32 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray30, shortArray32);
short[] shortArray36 = new short[] { (short) 10 };
short[] shortArray38 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray36, shortArray38);
org.junit.Assert.assertArrayEquals("tests.badapples", shortArray32, shortArray38);
org.junit.Assert.assertArrayEquals(shortArray25, shortArray38);
short[] shortArray45 = new short[] { (short) 10 };
short[] shortArray47 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray45, shortArray47);
short[] shortArray51 = new short[] { (short) 10 };
short[] shortArray53 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray51, shortArray53);
org.junit.Assert.assertArrayEquals("tests.badapples", shortArray47, shortArray53);
org.junit.Assert.assertArrayEquals(shortArray25, shortArray53);
short[] shortArray59 = new short[] { (short) 10 };
short[] shortArray61 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray59, shortArray61);
short[] shortArray66 = new short[] { (short) 10 };
short[] shortArray68 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray66, shortArray68);
short[] shortArray72 = new short[] { (short) 10 };
short[] shortArray74 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray72, shortArray74);
org.junit.Assert.assertArrayEquals("tests.badapples", shortArray68, shortArray74);
org.junit.Assert.assertArrayEquals(shortArray61, shortArray74);
short[] shortArray81 = new short[] { (short) 10 };
short[] shortArray83 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray81, shortArray83);
short[] shortArray87 = new short[] { (short) 10 };
short[] shortArray89 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray87, shortArray89);
org.junit.Assert.assertArrayEquals("tests.badapples", shortArray83, shortArray89);
org.junit.Assert.assertArrayEquals(shortArray61, shortArray89);
org.junit.Assert.assertArrayEquals(shortArray25, shortArray61);
org.junit.Assert.assertArrayEquals(shortArray16, shortArray61);
org.junit.Assert.assertNotNull(shortArray3);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray3), "[10]");
org.junit.Assert.assertNotNull(shortArray5);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray5), "[10]");
org.junit.Assert.assertNotNull(shortArray9);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray9), "[10]");
org.junit.Assert.assertNotNull(shortArray11);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray11), "[10]");
org.junit.Assert.assertNotNull(shortArray16);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray16), "[10]");
org.junit.Assert.assertNotNull(shortArray18);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray18), "[10]");
org.junit.Assert.assertNotNull(shortArray23);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray23), "[10]");
org.junit.Assert.assertNotNull(shortArray25);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray25), "[10]");
org.junit.Assert.assertNotNull(shortArray30);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray30), "[10]");
org.junit.Assert.assertNotNull(shortArray32);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray32), "[10]");
org.junit.Assert.assertNotNull(shortArray36);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray36), "[10]");
org.junit.Assert.assertNotNull(shortArray38);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray38), "[10]");
org.junit.Assert.assertNotNull(shortArray45);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray45), "[10]");
org.junit.Assert.assertNotNull(shortArray47);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray47), "[10]");
org.junit.Assert.assertNotNull(shortArray51);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray51), "[10]");
org.junit.Assert.assertNotNull(shortArray53);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray53), "[10]");
org.junit.Assert.assertNotNull(shortArray59);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray59), "[10]");
org.junit.Assert.assertNotNull(shortArray61);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray61), "[10]");
org.junit.Assert.assertNotNull(shortArray66);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray66), "[10]");
org.junit.Assert.assertNotNull(shortArray68);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray68), "[10]");
org.junit.Assert.assertNotNull(shortArray72);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray72), "[10]");
org.junit.Assert.assertNotNull(shortArray74);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray74), "[10]");
org.junit.Assert.assertNotNull(shortArray81);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray81), "[10]");
org.junit.Assert.assertNotNull(shortArray83);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray83), "[10]");
org.junit.Assert.assertNotNull(shortArray87);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray87), "[10]");
org.junit.Assert.assertNotNull(shortArray89);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray89), "[10]");
}
@Test
public void test02232() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02232");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
java.lang.String[] strArray14 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray14);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests16.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet15, (java.lang.Object) kuromojiAnalysisTests16);
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests16.assertDocsEnumEquals("tests.badapples", postingsEnum21, postingsEnum22, true);
org.junit.rules.TestRule testRule25 = kuromojiAnalysisTests16.ruleChain;
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests16.assertDocsSkippingEquals("tests.maxfailures", indexReader27, (int) (byte) 100, postingsEnum29, postingsEnum30, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests33 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader35 = null;
org.apache.lucene.index.Fields fields36 = null;
org.apache.lucene.index.Fields fields37 = null;
kuromojiAnalysisTests33.assertFieldsEquals("europarl.lines.txt.gz", indexReader35, fields36, fields37, false);
kuromojiAnalysisTests33.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain42 = kuromojiAnalysisTests33.failureAndSuccessEvents;
kuromojiAnalysisTests16.failureAndSuccessEvents = ruleChain42;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain42;
org.apache.lucene.index.PostingsEnum postingsEnum46 = null;
org.apache.lucene.index.PostingsEnum postingsEnum47 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("<unknown>", postingsEnum46, postingsEnum47, true);
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader52 = null;
org.apache.lucene.index.IndexReader indexReader53 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermVectorsEquals("tests.badapples", indexReader52, indexReader53);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray14);
org.junit.Assert.assertNotNull(strComparableSet15);
org.junit.Assert.assertNotNull(testRule25);
org.junit.Assert.assertNotNull(ruleChain42);
}
@Test
public void test02233() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02233");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("", indexReader11, (int) (byte) 0, postingsEnum13, postingsEnum14);
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("<unknown>", indexReader18, (int) ' ', postingsEnum20, postingsEnum21, false);
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.IndexReader indexReader26 = null;
org.apache.lucene.index.PostingsEnum postingsEnum28 = null;
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("<unknown>", indexReader26, (int) (byte) 10, postingsEnum28, postingsEnum29, false);
org.apache.lucene.index.IndexReader indexReader33 = null;
org.apache.lucene.index.IndexReader indexReader34 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderEquals("tests.nightly", indexReader33, indexReader34);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02234() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02234");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("hi!", indexReader9, (int) (byte) 0, postingsEnum11, postingsEnum12);
kuromojiAnalysisTests1.ensureCheckIndexPassed();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests15 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.junit.Assert.assertNotSame("tests.slow", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests15);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests15.testReadingFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02235() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02235");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
java.lang.String[] strArray14 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray14);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests16.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet15, (java.lang.Object) kuromojiAnalysisTests16);
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests16.assertDocsEnumEquals("tests.badapples", postingsEnum21, postingsEnum22, true);
org.junit.rules.TestRule testRule25 = kuromojiAnalysisTests16.ruleChain;
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests16.assertDocsSkippingEquals("tests.maxfailures", indexReader27, (int) (byte) 100, postingsEnum29, postingsEnum30, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests33 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader35 = null;
org.apache.lucene.index.Fields fields36 = null;
org.apache.lucene.index.Fields fields37 = null;
kuromojiAnalysisTests33.assertFieldsEquals("europarl.lines.txt.gz", indexReader35, fields36, fields37, false);
kuromojiAnalysisTests33.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain42 = kuromojiAnalysisTests33.failureAndSuccessEvents;
kuromojiAnalysisTests16.failureAndSuccessEvents = ruleChain42;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain42;
org.apache.lucene.index.PostingsEnum postingsEnum46 = null;
org.apache.lucene.index.PostingsEnum postingsEnum47 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("<unknown>", postingsEnum46, postingsEnum47, true);
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (short) 10);
org.apache.lucene.index.IndexReader indexReader53 = null;
org.apache.lucene.index.PostingsEnum postingsEnum55 = null;
org.apache.lucene.index.PostingsEnum postingsEnum56 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.failfast", indexReader53, (int) ' ', postingsEnum55, postingsEnum56, false);
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path60 = kuromojiAnalysisTests0.getDataPath("tests.weekly");
org.junit.Assert.fail("Expected exception of type java.lang.RuntimeException; message: resource not found: tests.weekly");
} catch (java.lang.RuntimeException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray14);
org.junit.Assert.assertNotNull(strComparableSet15);
org.junit.Assert.assertNotNull(testRule25);
org.junit.Assert.assertNotNull(ruleChain42);
}
@Test
public void test02236() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02236");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule9 = kuromojiAnalysisTests0.ruleChain;
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.IndexReader indexReader13 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDocValuesEquals("enwiki.random.lines.txt", indexReader12, indexReader13);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule9);
}
@Test
public void test02237() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02237");
org.junit.Assert.assertNotEquals((long) 10, (long) 0);
}
@Test
public void test02238() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02238");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.Fields fields14 = null;
org.apache.lucene.index.Fields fields15 = null;
kuromojiAnalysisTests1.assertFieldsEquals("enwiki.random.lines.txt", indexReader13, fields14, fields15, false);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests1.ruleChain;
org.junit.Assert.assertNotEquals((java.lang.Object) (-1.0d), (java.lang.Object) kuromojiAnalysisTests1);
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
kuromojiAnalysisTests1.assertDocsSkippingEquals("", indexReader21, (int) '4', postingsEnum23, postingsEnum24, false);
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testKuromojiEmptyUserDict();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02239() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02239");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("tests.nightly", postingsEnum21, postingsEnum22, true);
org.apache.lucene.index.IndexReader indexReader26 = null;
org.apache.lucene.index.TermsEnum termsEnum27 = null;
org.apache.lucene.index.TermsEnum termsEnum28 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("enwiki.random.lines.txt", indexReader26, termsEnum27, termsEnum28, false);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02240() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02240");
float[] floatArray8 = new float[] { (short) 10, (-1.0f), 100.0f, (byte) 0, (short) 100, 1L };
float[] floatArray15 = new float[] { (byte) -1, (short) -1, 100, (byte) -1, '4', (byte) 100 };
org.junit.Assert.assertArrayEquals("tests.awaitsfix", floatArray8, floatArray15, (float) (byte) 100);
float[] floatArray25 = new float[] { (short) 10, (-1.0f), 100.0f, (byte) 0, (short) 100, 1L };
float[] floatArray32 = new float[] { (byte) -1, (short) -1, 100, (byte) -1, '4', (byte) 100 };
org.junit.Assert.assertArrayEquals("tests.awaitsfix", floatArray25, floatArray32, (float) (byte) 100);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", floatArray8, floatArray25, (float) (-1));
float[] floatArray45 = new float[] { (short) 10, (-1.0f), 100.0f, (byte) 0, (short) 100, 1L };
float[] floatArray52 = new float[] { (byte) -1, (short) -1, 100, (byte) -1, '4', (byte) 100 };
org.junit.Assert.assertArrayEquals("tests.awaitsfix", floatArray45, floatArray52, (float) (byte) 100);
float[] floatArray62 = new float[] { (short) 10, (-1.0f), 100.0f, (byte) 0, (short) 100, 1L };
float[] floatArray69 = new float[] { (byte) -1, (short) -1, 100, (byte) -1, '4', (byte) 100 };
org.junit.Assert.assertArrayEquals("tests.awaitsfix", floatArray62, floatArray69, (float) (byte) 100);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", floatArray45, floatArray62, (float) (-1));
org.junit.Assert.assertArrayEquals(floatArray25, floatArray62, (float) 1);
float[] floatArray83 = new float[] { (short) 10, (-1.0f), 100.0f, (byte) 0, (short) 100, 1L };
float[] floatArray90 = new float[] { (byte) -1, (short) -1, 100, (byte) -1, '4', (byte) 100 };
org.junit.Assert.assertArrayEquals("tests.awaitsfix", floatArray83, floatArray90, (float) (byte) 100);
org.junit.Assert.assertArrayEquals(floatArray25, floatArray90, (float) (byte) 100);
org.junit.Assert.assertNotNull(floatArray8);
org.junit.Assert.assertEquals(java.util.Arrays.toString(floatArray8), "[10.0, -1.0, 100.0, 0.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(floatArray15);
org.junit.Assert.assertEquals(java.util.Arrays.toString(floatArray15), "[-1.0, -1.0, 100.0, -1.0, 52.0, 100.0]");
org.junit.Assert.assertNotNull(floatArray25);
org.junit.Assert.assertEquals(java.util.Arrays.toString(floatArray25), "[10.0, -1.0, 100.0, 0.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(floatArray32);
org.junit.Assert.assertEquals(java.util.Arrays.toString(floatArray32), "[-1.0, -1.0, 100.0, -1.0, 52.0, 100.0]");
org.junit.Assert.assertNotNull(floatArray45);
org.junit.Assert.assertEquals(java.util.Arrays.toString(floatArray45), "[10.0, -1.0, 100.0, 0.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(floatArray52);
org.junit.Assert.assertEquals(java.util.Arrays.toString(floatArray52), "[-1.0, -1.0, 100.0, -1.0, 52.0, 100.0]");
org.junit.Assert.assertNotNull(floatArray62);
org.junit.Assert.assertEquals(java.util.Arrays.toString(floatArray62), "[10.0, -1.0, 100.0, 0.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(floatArray69);
org.junit.Assert.assertEquals(java.util.Arrays.toString(floatArray69), "[-1.0, -1.0, 100.0, -1.0, 52.0, 100.0]");
org.junit.Assert.assertNotNull(floatArray83);
org.junit.Assert.assertEquals(java.util.Arrays.toString(floatArray83), "[10.0, -1.0, 100.0, 0.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(floatArray90);
org.junit.Assert.assertEquals(java.util.Arrays.toString(floatArray90), "[-1.0, -1.0, 100.0, -1.0, 52.0, 100.0]");
}
@Test
public void test02241() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02241");
java.text.Collator collator0 = null;
// The following exception was thrown during execution in test generation
try {
int int3 = org.apache.lucene.util.LuceneTestCase.collate(collator0, "random", "tests.maxfailures");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02242() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02242");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.ensureCleanedUp();
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.Terms terms12 = null;
org.apache.lucene.index.Terms terms13 = null;
kuromojiAnalysisTests1.assertTermsEquals("", indexReader11, terms12, terms13, false);
short[] shortArray18 = new short[] { (short) 10 };
short[] shortArray20 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray18, shortArray20);
short[] shortArray25 = new short[] { (short) 10 };
short[] shortArray27 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray25, shortArray27);
short[] shortArray31 = new short[] { (short) 10 };
short[] shortArray33 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray31, shortArray33);
org.junit.Assert.assertArrayEquals("tests.badapples", shortArray27, shortArray33);
org.junit.Assert.assertArrayEquals(shortArray20, shortArray33);
short[] shortArray40 = new short[] { (short) 10 };
short[] shortArray42 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray40, shortArray42);
short[] shortArray46 = new short[] { (short) 10 };
short[] shortArray48 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray46, shortArray48);
org.junit.Assert.assertArrayEquals("tests.badapples", shortArray42, shortArray48);
org.junit.Assert.assertArrayEquals(shortArray20, shortArray48);
short[] shortArray56 = new short[] { (short) 10 };
short[] shortArray58 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray56, shortArray58);
short[] shortArray62 = new short[] { (short) 10 };
short[] shortArray64 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray62, shortArray64);
org.junit.Assert.assertArrayEquals("tests.badapples", shortArray58, shortArray64);
short[] shortArray70 = new short[] { (short) 10 };
short[] shortArray72 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray70, shortArray72);
short[] shortArray76 = new short[] { (short) 10 };
short[] shortArray78 = new short[] { (short) 10 };
org.junit.Assert.assertArrayEquals("tests.maxfailures", shortArray76, shortArray78);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", shortArray72, shortArray78);
org.junit.Assert.assertArrayEquals("tests.badapples", shortArray58, shortArray78);
org.junit.Assert.assertArrayEquals(shortArray20, shortArray78);
org.junit.Assert.assertNotEquals("europarl.lines.txt.gz", (java.lang.Object) terms12, (java.lang.Object) shortArray78);
org.junit.Assert.assertNotNull(shortArray18);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray18), "[10]");
org.junit.Assert.assertNotNull(shortArray20);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray20), "[10]");
org.junit.Assert.assertNotNull(shortArray25);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray25), "[10]");
org.junit.Assert.assertNotNull(shortArray27);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray27), "[10]");
org.junit.Assert.assertNotNull(shortArray31);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray31), "[10]");
org.junit.Assert.assertNotNull(shortArray33);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray33), "[10]");
org.junit.Assert.assertNotNull(shortArray40);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray40), "[10]");
org.junit.Assert.assertNotNull(shortArray42);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray42), "[10]");
org.junit.Assert.assertNotNull(shortArray46);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray46), "[10]");
org.junit.Assert.assertNotNull(shortArray48);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray48), "[10]");
org.junit.Assert.assertNotNull(shortArray56);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray56), "[10]");
org.junit.Assert.assertNotNull(shortArray58);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray58), "[10]");
org.junit.Assert.assertNotNull(shortArray62);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray62), "[10]");
org.junit.Assert.assertNotNull(shortArray64);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray64), "[10]");
org.junit.Assert.assertNotNull(shortArray70);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray70), "[10]");
org.junit.Assert.assertNotNull(shortArray72);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray72), "[10]");
org.junit.Assert.assertNotNull(shortArray76);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray76), "[10]");
org.junit.Assert.assertNotNull(shortArray78);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray78), "[10]");
}
@Test
public void test02243() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02243");
java.lang.Runnable runnable0 = null;
java.util.concurrent.TimeUnit timeUnit2 = null;
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.test.ESTestCase.assertBusy(runnable0, (long) '4', timeUnit2);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02244() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02244");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newTextField("tests.awaitsfix", "tests.monster", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02245() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02245");
java.util.Random random0 = null;
java.lang.Object obj2 = null;
org.apache.lucene.document.FieldType fieldType3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newField(random0, "tests.badapples", obj2, fieldType3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02246() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02246");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain10;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain10;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests13.setIndexWriterMaxDocs((int) (byte) 10);
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.Terms terms18 = null;
org.apache.lucene.index.Terms terms19 = null;
kuromojiAnalysisTests13.assertTermsEquals("tests.weekly", indexReader17, terms18, terms19, true);
kuromojiAnalysisTests13.setIndexWriterMaxDocs((int) '#');
kuromojiAnalysisTests13.overrideTestDefaultQueryCache();
kuromojiAnalysisTests13.ensureCheckIndexPassed();
org.junit.Assert.assertNotSame("tests.weekly", (java.lang.Object) ruleChain10, (java.lang.Object) kuromojiAnalysisTests13);
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.IndexReader indexReader29 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests13.assertNormsEquals("tests.slow", indexReader28, indexReader29);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
}
@Test
public void test02247() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02247");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.Class<?> wildcardClass13 = kuromojiAnalysisTests0.getClass();
org.junit.Assert.assertNotNull(wildcardClass13);
}
@Test
public void test02248() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02248");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Fields fields17 = null;
org.apache.lucene.index.Fields fields18 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.slow", indexReader16, fields17, fields18, false);
kuromojiAnalysisTests0.resetCheckIndexStatus();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testBaseFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02249() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02249");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain9 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
java.lang.String str11 = kuromojiAnalysisTests0.getTestName();
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("europarl.lines.txt.gz", postingsEnum13, postingsEnum14, false);
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.IndexReader indexReader19 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertFieldInfosEquals("hi!", indexReader18, indexReader19);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain9);
org.junit.Assert.assertEquals("'" + str11 + "' != '" + "<unknown>" + "'", str11, "<unknown>");
}
@Test
public void test02250() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02250");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy2 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy(true, 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02251() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02251");
org.junit.Assert.assertNotEquals((long) (short) -1, (long) 1);
}
@Test
public void test02252() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02252");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str10 = kuromojiAnalysisTests0.getTestName();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule12 = kuromojiAnalysisTests0.ruleChain;
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testKatakanaStemFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str10 + "' != '" + "<unknown>" + "'", str10, "<unknown>");
org.junit.Assert.assertNotNull(testRule12);
}
@Test
public void test02253() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02253");
org.junit.Assert.assertTrue("tests.maxfailures", true);
}
@Test
public void test02254() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02254");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
kuromojiAnalysisTests0.ensureCleanedUp();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.Fields fields19 = null;
org.apache.lucene.index.Fields fields20 = null;
kuromojiAnalysisTests16.assertFieldsEquals("europarl.lines.txt.gz", indexReader18, fields19, fields20, false);
kuromojiAnalysisTests16.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain25 = kuromojiAnalysisTests16.failureAndSuccessEvents;
kuromojiAnalysisTests16.setUp();
java.util.Locale locale29 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale31 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale33 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale35 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray38 = new java.util.Locale[] { locale29, locale31, locale33, locale35, locale37 };
java.util.Set<java.util.Locale> localeSet39 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray38);
java.util.Locale locale42 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale44 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale46 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale48 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale50 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray51 = new java.util.Locale[] { locale42, locale44, locale46, locale48, locale50 };
java.util.Set<java.util.Locale> localeSet52 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray51);
java.util.List<java.io.Serializable> serializableList53 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray51);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray38, (java.lang.Object[]) localeArray51);
java.util.Locale locale57 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale59 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale61 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale63 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale65 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray66 = new java.util.Locale[] { locale57, locale59, locale61, locale63, locale65 };
java.util.Set<java.util.Locale> localeSet67 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray66);
java.util.List<java.io.Serializable> serializableList68 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray66);
java.util.Set<java.lang.Cloneable> cloneableSet69 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray66);
org.junit.Assert.assertArrayEquals("tests.slow", (java.lang.Object[]) localeArray51, (java.lang.Object[]) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests16, (java.lang.Object) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests16);
org.apache.lucene.index.IndexReader indexReader74 = null;
org.apache.lucene.index.IndexReader indexReader75 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertNormsEquals("tests.nightly", indexReader74, indexReader75);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain25);
org.junit.Assert.assertNotNull(locale29);
org.junit.Assert.assertEquals(locale29.toString(), "");
org.junit.Assert.assertNotNull(locale31);
org.junit.Assert.assertEquals(locale31.toString(), "");
org.junit.Assert.assertNotNull(locale33);
org.junit.Assert.assertEquals(locale33.toString(), "");
org.junit.Assert.assertNotNull(locale35);
org.junit.Assert.assertEquals(locale35.toString(), "");
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "");
org.junit.Assert.assertNotNull(localeArray38);
org.junit.Assert.assertNotNull(localeSet39);
org.junit.Assert.assertNotNull(locale42);
org.junit.Assert.assertEquals(locale42.toString(), "");
org.junit.Assert.assertNotNull(locale44);
org.junit.Assert.assertEquals(locale44.toString(), "");
org.junit.Assert.assertNotNull(locale46);
org.junit.Assert.assertEquals(locale46.toString(), "");
org.junit.Assert.assertNotNull(locale48);
org.junit.Assert.assertEquals(locale48.toString(), "");
org.junit.Assert.assertNotNull(locale50);
org.junit.Assert.assertEquals(locale50.toString(), "");
org.junit.Assert.assertNotNull(localeArray51);
org.junit.Assert.assertNotNull(localeSet52);
org.junit.Assert.assertNotNull(serializableList53);
org.junit.Assert.assertNotNull(locale57);
org.junit.Assert.assertEquals(locale57.toString(), "");
org.junit.Assert.assertNotNull(locale59);
org.junit.Assert.assertEquals(locale59.toString(), "");
org.junit.Assert.assertNotNull(locale61);
org.junit.Assert.assertEquals(locale61.toString(), "");
org.junit.Assert.assertNotNull(locale63);
org.junit.Assert.assertEquals(locale63.toString(), "");
org.junit.Assert.assertNotNull(locale65);
org.junit.Assert.assertEquals(locale65.toString(), "");
org.junit.Assert.assertNotNull(localeArray66);
org.junit.Assert.assertNotNull(localeSet67);
org.junit.Assert.assertNotNull(serializableList68);
org.junit.Assert.assertNotNull(cloneableSet69);
}
@Test
public void test02255() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02255");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.ensureAllSearchContextsReleased();
org.junit.Assert.assertNotNull("europarl.lines.txt.gz", (java.lang.Object) kuromojiAnalysisTests1);
java.nio.file.Path path13 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertPathHasBeenCleared(path13);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
}
@Test
public void test02256() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02256");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween((int) (byte) 100, (int) (byte) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02257() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02257");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween((-1), (int) (short) 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02258() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02258");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str9 = kuromojiAnalysisTests0.getTestName();
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.ensureCleanedUp();
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray12 = kuromojiAnalysisTests0.tmpPaths();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str9 + "' != '" + "<unknown>" + "'", str9, "<unknown>");
org.junit.Assert.assertNotNull(ruleChain10);
}
@Test
public void test02259() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02259");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("<unknown>", indexReader14, (int) '#', postingsEnum16, postingsEnum17);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.Fields fields23 = null;
org.apache.lucene.index.Fields fields24 = null;
kuromojiAnalysisTests0.assertFieldsEquals("random", indexReader22, fields23, fields24, true);
org.junit.Assert.assertNotNull((java.lang.Object) true);
}
@Test
public void test02260() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02260");
java.util.Locale locale2 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.awaitsfix");
java.util.Locale locale4 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.weekly");
java.util.Locale locale6 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray7 = new java.util.Locale[] { locale2, locale4, locale6 };
java.util.Locale locale9 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.awaitsfix");
java.util.Locale locale11 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.weekly");
java.util.Locale locale13 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray14 = new java.util.Locale[] { locale9, locale11, locale13 };
java.util.Locale locale16 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.awaitsfix");
java.util.Locale locale18 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.weekly");
java.util.Locale locale20 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray21 = new java.util.Locale[] { locale16, locale18, locale20 };
java.util.Locale locale23 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.awaitsfix");
java.util.Locale locale25 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.weekly");
java.util.Locale locale27 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray28 = new java.util.Locale[] { locale23, locale25, locale27 };
java.util.Locale locale30 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.awaitsfix");
java.util.Locale locale32 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.weekly");
java.util.Locale locale34 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray35 = new java.util.Locale[] { locale30, locale32, locale34 };
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.awaitsfix");
java.util.Locale locale39 = org.apache.lucene.util.LuceneTestCase.localeForName("tests.weekly");
java.util.Locale locale41 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray42 = new java.util.Locale[] { locale37, locale39, locale41 };
java.util.Locale[][] localeArray43 = new java.util.Locale[][] { localeArray7, localeArray14, localeArray21, localeArray28, localeArray35, localeArray42 };
java.util.Set<java.util.Locale[]> localeArraySet44 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray43);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests45 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader47 = null;
org.apache.lucene.index.Fields fields48 = null;
org.apache.lucene.index.Fields fields49 = null;
kuromojiAnalysisTests45.assertFieldsEquals("europarl.lines.txt.gz", indexReader47, fields48, fields49, false);
org.apache.lucene.index.IndexReader indexReader53 = null;
org.apache.lucene.index.PostingsEnum postingsEnum55 = null;
org.apache.lucene.index.PostingsEnum postingsEnum56 = null;
kuromojiAnalysisTests45.assertPositionsSkippingEquals("tests.failfast", indexReader53, 1, postingsEnum55, postingsEnum56);
kuromojiAnalysisTests45.setIndexWriterMaxDocs(0);
org.apache.lucene.index.IndexReader indexReader61 = null;
org.apache.lucene.index.Fields fields62 = null;
org.apache.lucene.index.Fields fields63 = null;
kuromojiAnalysisTests45.assertFieldsEquals("tests.slow", indexReader61, fields62, fields63, false);
org.apache.lucene.index.IndexReader indexReader67 = null;
org.apache.lucene.index.PostingsEnum postingsEnum69 = null;
org.apache.lucene.index.PostingsEnum postingsEnum70 = null;
kuromojiAnalysisTests45.assertPositionsSkippingEquals("<unknown>", indexReader67, (int) 'a', postingsEnum69, postingsEnum70);
kuromojiAnalysisTests45.overrideTestDefaultQueryCache();
org.junit.rules.RuleChain ruleChain73 = kuromojiAnalysisTests45.failureAndSuccessEvents;
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray43, (java.lang.Object) ruleChain73);
java.io.PrintStream printStream75 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.util.LuceneTestCase.dumpArray("<unknown>", (java.lang.Object[]) localeArray43, printStream75);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(locale2);
org.junit.Assert.assertEquals(locale2.toString(), "tests.awaitsfix");
org.junit.Assert.assertNotNull(locale4);
org.junit.Assert.assertEquals(locale4.toString(), "tests.weekly");
org.junit.Assert.assertNotNull(locale6);
org.junit.Assert.assertEquals(locale6.toString(), "");
org.junit.Assert.assertNotNull(localeArray7);
org.junit.Assert.assertNotNull(locale9);
org.junit.Assert.assertEquals(locale9.toString(), "tests.awaitsfix");
org.junit.Assert.assertNotNull(locale11);
org.junit.Assert.assertEquals(locale11.toString(), "tests.weekly");
org.junit.Assert.assertNotNull(locale13);
org.junit.Assert.assertEquals(locale13.toString(), "");
org.junit.Assert.assertNotNull(localeArray14);
org.junit.Assert.assertNotNull(locale16);
org.junit.Assert.assertEquals(locale16.toString(), "tests.awaitsfix");
org.junit.Assert.assertNotNull(locale18);
org.junit.Assert.assertEquals(locale18.toString(), "tests.weekly");
org.junit.Assert.assertNotNull(locale20);
org.junit.Assert.assertEquals(locale20.toString(), "");
org.junit.Assert.assertNotNull(localeArray21);
org.junit.Assert.assertNotNull(locale23);
org.junit.Assert.assertEquals(locale23.toString(), "tests.awaitsfix");
org.junit.Assert.assertNotNull(locale25);
org.junit.Assert.assertEquals(locale25.toString(), "tests.weekly");
org.junit.Assert.assertNotNull(locale27);
org.junit.Assert.assertEquals(locale27.toString(), "");
org.junit.Assert.assertNotNull(localeArray28);
org.junit.Assert.assertNotNull(locale30);
org.junit.Assert.assertEquals(locale30.toString(), "tests.awaitsfix");
org.junit.Assert.assertNotNull(locale32);
org.junit.Assert.assertEquals(locale32.toString(), "tests.weekly");
org.junit.Assert.assertNotNull(locale34);
org.junit.Assert.assertEquals(locale34.toString(), "");
org.junit.Assert.assertNotNull(localeArray35);
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "tests.awaitsfix");
org.junit.Assert.assertNotNull(locale39);
org.junit.Assert.assertEquals(locale39.toString(), "tests.weekly");
org.junit.Assert.assertNotNull(locale41);
org.junit.Assert.assertEquals(locale41.toString(), "");
org.junit.Assert.assertNotNull(localeArray42);
org.junit.Assert.assertNotNull(localeArray43);
org.junit.Assert.assertNotNull(localeArraySet44);
org.junit.Assert.assertNotNull(ruleChain73);
}
@Test
public void test02261() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02261");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
java.io.Reader reader16 = null;
// The following exception was thrown during execution in test generation
try {
java.lang.String str17 = kuromojiAnalysisTests0.readFully(reader16);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02262() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02262");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("<unknown>", indexReader14, (int) '#', postingsEnum16, postingsEnum17);
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("random", indexReader21, (int) (byte) -1, postingsEnum23, postingsEnum24);
java.io.Reader reader26 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertCharFilterEquals(reader26, "tests.nightly");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02263() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02263");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.Fields fields21 = null;
org.apache.lucene.index.Fields fields22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertFieldStatisticsEquals("tests.nightly", fields21, fields22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02264() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02264");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Fields fields17 = null;
org.apache.lucene.index.Fields fields18 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.slow", indexReader16, fields17, fields18, false);
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.index.analysis.AnalysisService analysisService21 = kuromojiAnalysisTests0.createAnalysisService();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02265() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02265");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) "tests.awaitsfix");
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
java.io.Reader reader14 = null;
// The following exception was thrown during execution in test generation
try {
java.lang.String str15 = kuromojiAnalysisTests0.readFully(reader14);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02266() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02266");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.slow", indexReader11, (int) (short) -1, postingsEnum13, postingsEnum14, false);
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("", indexReader18, (int) '4', postingsEnum20, postingsEnum21);
org.apache.lucene.index.IndexReader indexReader24 = null;
org.apache.lucene.index.TermsEnum termsEnum25 = null;
org.apache.lucene.index.TermsEnum termsEnum26 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("tests.maxfailures", indexReader24, termsEnum25, termsEnum26, false);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02267() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02267");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween((int) (short) -1, (int) (byte) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02268() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02268");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.ensureAllSearchContextsReleased();
org.junit.Assert.assertNotNull("europarl.lines.txt.gz", (java.lang.Object) kuromojiAnalysisTests1);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Fields fields15 = null;
org.apache.lucene.index.Fields fields16 = null;
kuromojiAnalysisTests1.assertFieldsEquals("", indexReader14, fields15, fields16, false);
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.IndexReader indexReader21 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertStoredFieldsEquals("tests.nightly", indexReader20, indexReader21);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
}
@Test
public void test02269() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02269");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfLengthBetween((int) (byte) 10, 0);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02270() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02270");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests13.assertFieldsEquals("europarl.lines.txt.gz", indexReader15, fields16, fields17, false);
kuromojiAnalysisTests13.ensureCleanedUp();
kuromojiAnalysisTests13.resetCheckIndexStatus();
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
kuromojiAnalysisTests13.assertPositionsSkippingEquals("", indexReader24, (int) (byte) 0, postingsEnum26, postingsEnum27);
org.junit.Assert.assertNotEquals((java.lang.Object) "tests.failfast", (java.lang.Object) kuromojiAnalysisTests13);
kuromojiAnalysisTests13.setUp();
java.lang.String[] strArray38 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet39 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray38);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests40 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests40.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet39, (java.lang.Object) kuromojiAnalysisTests40);
java.lang.String str44 = kuromojiAnalysisTests40.getTestName();
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests13, (java.lang.Object) kuromojiAnalysisTests40);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests13.testIterationMarkCharFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
org.junit.Assert.assertNotNull(strArray38);
org.junit.Assert.assertNotNull(strComparableSet39);
org.junit.Assert.assertEquals("'" + str44 + "' != '" + "<unknown>" + "'", str44, "<unknown>");
}
@Test
public void test02271() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02271");
org.apache.lucene.document.FieldType fieldType2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newField("tests.weekly", "tests.badapples", fieldType2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02272() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02272");
org.junit.Assert.assertNotEquals((long) (short) 1, (long) (byte) 100);
}
@Test
public void test02273() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02273");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween((int) ' ', (int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02274() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02274");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests15 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.Fields fields18 = null;
org.apache.lucene.index.Fields fields19 = null;
kuromojiAnalysisTests15.assertFieldsEquals("europarl.lines.txt.gz", indexReader17, fields18, fields19, false);
kuromojiAnalysisTests15.ensureCleanedUp();
kuromojiAnalysisTests15.overrideTestDefaultQueryCache();
kuromojiAnalysisTests15.restoreIndexWriterMaxDocs();
org.junit.rules.RuleChain ruleChain25 = kuromojiAnalysisTests15.failureAndSuccessEvents;
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests15);
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.IndexReader indexReader29 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests15.assertFieldInfosEquals("<unknown>", indexReader28, indexReader29);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain25);
}
@Test
public void test02275() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02275");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str10 = kuromojiAnalysisTests0.getTestName();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule12 = kuromojiAnalysisTests0.ruleChain;
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.TermsEnum termsEnum19 = null;
org.apache.lucene.index.TermsEnum termsEnum20 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("tests.weekly", indexReader18, termsEnum19, termsEnum20, true);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str10 + "' != '" + "<unknown>" + "'", str10, "<unknown>");
org.junit.Assert.assertNotNull(testRule12);
}
@Test
public void test02276() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02276");
java.text.Collator collator0 = null;
// The following exception was thrown during execution in test generation
try {
int int3 = org.apache.lucene.util.LuceneTestCase.collate(collator0, "tests.weekly", "tests.failfast");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02277() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02277");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
java.lang.String[] strArray14 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray14);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests16.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet15, (java.lang.Object) kuromojiAnalysisTests16);
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests16.assertDocsEnumEquals("tests.badapples", postingsEnum21, postingsEnum22, true);
org.junit.rules.TestRule testRule25 = kuromojiAnalysisTests16.ruleChain;
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests16.assertDocsSkippingEquals("tests.maxfailures", indexReader27, (int) (byte) 100, postingsEnum29, postingsEnum30, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests33 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader35 = null;
org.apache.lucene.index.Fields fields36 = null;
org.apache.lucene.index.Fields fields37 = null;
kuromojiAnalysisTests33.assertFieldsEquals("europarl.lines.txt.gz", indexReader35, fields36, fields37, false);
kuromojiAnalysisTests33.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain42 = kuromojiAnalysisTests33.failureAndSuccessEvents;
kuromojiAnalysisTests16.failureAndSuccessEvents = ruleChain42;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain42;
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testKuromojiUserDict();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray14);
org.junit.Assert.assertNotNull(strComparableSet15);
org.junit.Assert.assertNotNull(testRule25);
org.junit.Assert.assertNotNull(ruleChain42);
}
@Test
public void test02278() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02278");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader21, (int) '4', postingsEnum23, postingsEnum24);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(100);
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.env.NodeEnvironment nodeEnvironment28 = kuromojiAnalysisTests0.newNodeEnvironment();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02279() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02279");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween(1, (int) (short) 0);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02280() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02280");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
java.lang.String str19 = kuromojiAnalysisTests0.getTestName();
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.IndexReader indexReader22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermVectorsEquals("tests.nightly", indexReader21, indexReader22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str19 + "' != '" + "<unknown>" + "'", str19, "<unknown>");
}
@Test
public void test02281() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02281");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests13.assertFieldsEquals("europarl.lines.txt.gz", indexReader15, fields16, fields17, false);
kuromojiAnalysisTests13.ensureCleanedUp();
kuromojiAnalysisTests13.resetCheckIndexStatus();
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
kuromojiAnalysisTests13.assertPositionsSkippingEquals("", indexReader24, (int) (byte) 0, postingsEnum26, postingsEnum27);
org.junit.Assert.assertNotEquals((java.lang.Object) "tests.failfast", (java.lang.Object) kuromojiAnalysisTests13);
kuromojiAnalysisTests13.setUp();
kuromojiAnalysisTests13.overrideTestDefaultQueryCache();
kuromojiAnalysisTests13.resetCheckIndexStatus();
java.io.Reader reader33 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests13.assertCharFilterEquals(reader33, "tests.slow");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
}
@Test
public void test02282() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02282");
org.junit.rules.RuleChain[] ruleChainArray1 = new org.junit.rules.RuleChain[] {};
org.junit.rules.RuleChain[][] ruleChainArray2 = new org.junit.rules.RuleChain[][] { ruleChainArray1 };
java.util.Set<org.junit.rules.RuleChain[]> ruleChainArraySet3 = org.apache.lucene.util.LuceneTestCase.asSet(ruleChainArray2);
// The following exception was thrown during execution in test generation
try {
java.util.List<org.junit.rules.TestRule[]> testRuleArrayList4 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) '4', (org.junit.rules.TestRule[][]) ruleChainArray2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalArgumentException; message: Can't pick 52 random objects from a list of 1 objects");
} catch (java.lang.IllegalArgumentException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChainArray1);
org.junit.Assert.assertNotNull(ruleChainArray2);
org.junit.Assert.assertNotNull(ruleChainArraySet3);
}
@Test
public void test02283() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02283");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path2 = org.apache.lucene.util.LuceneTestCase.createTempFile("tests.maxfailures", "random");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02284() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02284");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str10 = kuromojiAnalysisTests0.getTestName();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule12 = kuromojiAnalysisTests0.ruleChain;
kuromojiAnalysisTests0.setUp();
org.junit.rules.RuleChain ruleChain14 = kuromojiAnalysisTests0.failureAndSuccessEvents;
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.IndexReader indexReader17 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertNormsEquals("tests.nightly", indexReader16, indexReader17);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str10 + "' != '" + "<unknown>" + "'", str10, "<unknown>");
org.junit.Assert.assertNotNull(testRule12);
org.junit.Assert.assertNotNull(ruleChain14);
}
@Test
public void test02285() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02285");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) "tests.awaitsfix");
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("<unknown>", indexReader14, terms15, terms16, true);
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.IndexReader indexReader21 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertNormsEquals("tests.weekly", indexReader20, indexReader21);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02286() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02286");
java.lang.String[] strArray1 = new java.lang.String[] { "tests.failfast" };
java.lang.String[] strArray3 = new java.lang.String[] { "tests.failfast" };
java.lang.String[] strArray5 = new java.lang.String[] { "tests.failfast" };
java.lang.String[][] strArray6 = new java.lang.String[][] { strArray1, strArray3, strArray5 };
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray7 = org.elasticsearch.test.ESTestCase.randomFrom(strArray6);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray1);
org.junit.Assert.assertNotNull(strArray3);
org.junit.Assert.assertNotNull(strArray5);
org.junit.Assert.assertNotNull(strArray6);
}
@Test
public void test02287() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02287");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Fields fields17 = null;
org.apache.lucene.index.Fields fields18 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.slow", indexReader16, fields17, fields18, false);
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.IndexReader indexReader23 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermVectorsEquals("tests.awaitsfix", indexReader22, indexReader23);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02288() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02288");
// The following exception was thrown during execution in test generation
try {
java.lang.String str1 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLength((int) (byte) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02289() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02289");
java.text.Collator collator0 = null;
// The following exception was thrown during execution in test generation
try {
int int3 = org.apache.lucene.util.LuceneTestCase.collate(collator0, "tests.slow", "tests.badapples");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02290() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02290");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.failfast", indexReader9, 1, postingsEnum11, postingsEnum12);
kuromojiAnalysisTests1.restoreIndexWriterMaxDocs();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests15 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.Fields fields18 = null;
org.apache.lucene.index.Fields fields19 = null;
kuromojiAnalysisTests15.assertFieldsEquals("europarl.lines.txt.gz", indexReader17, fields18, fields19, false);
org.apache.lucene.index.IndexReader indexReader23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum25 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
kuromojiAnalysisTests15.assertPositionsSkippingEquals("hi!", indexReader23, (int) (byte) 0, postingsEnum25, postingsEnum26);
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.Terms terms30 = null;
org.apache.lucene.index.Terms terms31 = null;
kuromojiAnalysisTests15.assertTermsEquals("random", indexReader29, terms30, terms31, true);
kuromojiAnalysisTests15.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum36 = null;
org.apache.lucene.index.PostingsEnum postingsEnum37 = null;
kuromojiAnalysisTests15.assertDocsEnumEquals("tests.nightly", postingsEnum36, postingsEnum37, true);
kuromojiAnalysisTests15.tearDown();
java.lang.Object obj41 = null;
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests15, obj41);
kuromojiAnalysisTests15.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests15);
kuromojiAnalysisTests15.assertPathHasBeenCleared("europarl.lines.txt.gz");
org.junit.Assert.assertNotNull("tests.monster", (java.lang.Object) "europarl.lines.txt.gz");
}
@Test
public void test02291() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02291");
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray3 = org.elasticsearch.test.ESTestCase.generateRandomStringArray((int) (byte) 10, (int) 'a', false);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02292() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02292");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.TestRule testRule10 = kuromojiAnalysisTests1.ruleChain;
int[] intArray15 = new int[] { '#' };
int[] intArray17 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray15, intArray17);
int[] intArray20 = new int[] { '#' };
int[] intArray22 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray20, intArray22);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray15, intArray20);
int[] intArray27 = new int[] { '#' };
int[] intArray29 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray27, intArray29);
int[] intArray32 = new int[] { '#' };
int[] intArray34 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray32, intArray34);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray27, intArray32);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", intArray15, intArray32);
int[] intArray41 = new int[] { '#' };
int[] intArray43 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray41, intArray43);
int[] intArray46 = new int[] { '#' };
int[] intArray48 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray46, intArray48);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray41, intArray46);
int[] intArray53 = new int[] { '#' };
int[] intArray55 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray53, intArray55);
int[] intArray58 = new int[] { '#' };
int[] intArray60 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray58, intArray60);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray53, intArray58);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", intArray41, intArray58);
org.junit.Assert.assertArrayEquals("random", intArray32, intArray41);
org.junit.Assert.assertNotSame("tests.maxfailures", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) intArray32);
kuromojiAnalysisTests1.ensureAllSearchContextsReleased();
org.junit.rules.RuleChain ruleChain67 = kuromojiAnalysisTests1.failureAndSuccessEvents;
org.apache.lucene.index.Fields fields69 = null;
org.apache.lucene.index.Fields fields70 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertFieldStatisticsEquals("tests.slow", fields69, fields70);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule10);
org.junit.Assert.assertNotNull(intArray15);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray15), "[35]");
org.junit.Assert.assertNotNull(intArray17);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray17), "[35]");
org.junit.Assert.assertNotNull(intArray20);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray20), "[35]");
org.junit.Assert.assertNotNull(intArray22);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray22), "[35]");
org.junit.Assert.assertNotNull(intArray27);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray27), "[35]");
org.junit.Assert.assertNotNull(intArray29);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray29), "[35]");
org.junit.Assert.assertNotNull(intArray32);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray32), "[35]");
org.junit.Assert.assertNotNull(intArray34);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray34), "[35]");
org.junit.Assert.assertNotNull(intArray41);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray41), "[35]");
org.junit.Assert.assertNotNull(intArray43);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray43), "[35]");
org.junit.Assert.assertNotNull(intArray46);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray46), "[35]");
org.junit.Assert.assertNotNull(intArray48);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray48), "[35]");
org.junit.Assert.assertNotNull(intArray53);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray53), "[35]");
org.junit.Assert.assertNotNull(intArray55);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray55), "[35]");
org.junit.Assert.assertNotNull(intArray58);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray58), "[35]");
org.junit.Assert.assertNotNull(intArray60);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray60), "[35]");
org.junit.Assert.assertNotNull(ruleChain67);
}
@Test
public void test02293() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02293");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
java.lang.String str19 = kuromojiAnalysisTests0.getTestName();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (short) 0);
java.lang.String str22 = kuromojiAnalysisTests0.getTestName();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testIterationMarkCharFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str19 + "' != '" + "<unknown>" + "'", str19, "<unknown>");
org.junit.Assert.assertEquals("'" + str22 + "' != '" + "<unknown>" + "'", str22, "<unknown>");
}
@Test
public void test02294() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02294");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
kuromojiAnalysisTests0.ensureCleanedUp();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.Fields fields19 = null;
org.apache.lucene.index.Fields fields20 = null;
kuromojiAnalysisTests16.assertFieldsEquals("europarl.lines.txt.gz", indexReader18, fields19, fields20, false);
kuromojiAnalysisTests16.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain25 = kuromojiAnalysisTests16.failureAndSuccessEvents;
kuromojiAnalysisTests16.setUp();
java.util.Locale locale29 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale31 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale33 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale35 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray38 = new java.util.Locale[] { locale29, locale31, locale33, locale35, locale37 };
java.util.Set<java.util.Locale> localeSet39 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray38);
java.util.Locale locale42 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale44 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale46 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale48 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale50 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray51 = new java.util.Locale[] { locale42, locale44, locale46, locale48, locale50 };
java.util.Set<java.util.Locale> localeSet52 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray51);
java.util.List<java.io.Serializable> serializableList53 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray51);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray38, (java.lang.Object[]) localeArray51);
java.util.Locale locale57 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale59 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale61 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale63 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale65 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray66 = new java.util.Locale[] { locale57, locale59, locale61, locale63, locale65 };
java.util.Set<java.util.Locale> localeSet67 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray66);
java.util.List<java.io.Serializable> serializableList68 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray66);
java.util.Set<java.lang.Cloneable> cloneableSet69 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray66);
org.junit.Assert.assertArrayEquals("tests.slow", (java.lang.Object[]) localeArray51, (java.lang.Object[]) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests16, (java.lang.Object) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests16);
org.apache.lucene.index.IndexReader indexReader74 = null;
org.apache.lucene.index.IndexReader indexReader75 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests16.assertReaderStatisticsEquals("europarl.lines.txt.gz", indexReader74, indexReader75);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain25);
org.junit.Assert.assertNotNull(locale29);
org.junit.Assert.assertEquals(locale29.toString(), "");
org.junit.Assert.assertNotNull(locale31);
org.junit.Assert.assertEquals(locale31.toString(), "");
org.junit.Assert.assertNotNull(locale33);
org.junit.Assert.assertEquals(locale33.toString(), "");
org.junit.Assert.assertNotNull(locale35);
org.junit.Assert.assertEquals(locale35.toString(), "");
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "");
org.junit.Assert.assertNotNull(localeArray38);
org.junit.Assert.assertNotNull(localeSet39);
org.junit.Assert.assertNotNull(locale42);
org.junit.Assert.assertEquals(locale42.toString(), "");
org.junit.Assert.assertNotNull(locale44);
org.junit.Assert.assertEquals(locale44.toString(), "");
org.junit.Assert.assertNotNull(locale46);
org.junit.Assert.assertEquals(locale46.toString(), "");
org.junit.Assert.assertNotNull(locale48);
org.junit.Assert.assertEquals(locale48.toString(), "");
org.junit.Assert.assertNotNull(locale50);
org.junit.Assert.assertEquals(locale50.toString(), "");
org.junit.Assert.assertNotNull(localeArray51);
org.junit.Assert.assertNotNull(localeSet52);
org.junit.Assert.assertNotNull(serializableList53);
org.junit.Assert.assertNotNull(locale57);
org.junit.Assert.assertEquals(locale57.toString(), "");
org.junit.Assert.assertNotNull(locale59);
org.junit.Assert.assertEquals(locale59.toString(), "");
org.junit.Assert.assertNotNull(locale61);
org.junit.Assert.assertEquals(locale61.toString(), "");
org.junit.Assert.assertNotNull(locale63);
org.junit.Assert.assertEquals(locale63.toString(), "");
org.junit.Assert.assertNotNull(locale65);
org.junit.Assert.assertEquals(locale65.toString(), "");
org.junit.Assert.assertNotNull(localeArray66);
org.junit.Assert.assertNotNull(localeSet67);
org.junit.Assert.assertNotNull(serializableList68);
org.junit.Assert.assertNotNull(cloneableSet69);
}
@Test
public void test02295() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02295");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests12 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Fields fields15 = null;
org.apache.lucene.index.Fields fields16 = null;
kuromojiAnalysisTests12.assertFieldsEquals("europarl.lines.txt.gz", indexReader14, fields15, fields16, false);
kuromojiAnalysisTests12.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain21 = kuromojiAnalysisTests12.failureAndSuccessEvents;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain21;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain21;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain21;
kuromojiAnalysisTests0.tearDown();
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.env.NodeEnvironment nodeEnvironment26 = kuromojiAnalysisTests0.newNodeEnvironment();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain21);
}
@Test
public void test02296() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02296");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.setUp();
kuromojiAnalysisTests1.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("hi!", indexReader18, 1, postingsEnum20, postingsEnum21);
org.junit.Assert.assertNull((java.lang.Object) postingsEnum21);
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02297() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02297");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("random", indexReader2, fields3, fields4, true);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.nightly", indexReader8, (int) (short) 1, postingsEnum10, postingsEnum11, false);
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.weekly", indexReader15, fields16, fields17, false);
org.apache.lucene.index.Terms terms21 = null;
org.apache.lucene.index.Terms terms22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsStatisticsEquals("tests.badapples", terms21, terms22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02298() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02298");
org.apache.lucene.document.FieldType fieldType2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newField("tests.awaitsfix", "tests.awaitsfix", fieldType2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02299() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02299");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy2 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy(false, (int) (short) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02300() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02300");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testJapaneseStopFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02301() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02301");
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray3 = org.elasticsearch.test.ESTestCase.generateRandomStringArray((int) (short) 10, (int) (byte) 0, false);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02302() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02302");
org.junit.Assert.assertNotEquals("tests.slow", (double) '4', (double) (-1), (double) (byte) 0);
}
@Test
public void test02303() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02303");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
java.lang.String[] strArray14 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray14);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests16.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet15, (java.lang.Object) kuromojiAnalysisTests16);
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests16.assertDocsEnumEquals("tests.badapples", postingsEnum21, postingsEnum22, true);
org.junit.rules.TestRule testRule25 = kuromojiAnalysisTests16.ruleChain;
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests16.assertDocsSkippingEquals("tests.maxfailures", indexReader27, (int) (byte) 100, postingsEnum29, postingsEnum30, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests33 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader35 = null;
org.apache.lucene.index.Fields fields36 = null;
org.apache.lucene.index.Fields fields37 = null;
kuromojiAnalysisTests33.assertFieldsEquals("europarl.lines.txt.gz", indexReader35, fields36, fields37, false);
kuromojiAnalysisTests33.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain42 = kuromojiAnalysisTests33.failureAndSuccessEvents;
kuromojiAnalysisTests16.failureAndSuccessEvents = ruleChain42;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain42;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests45 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader47 = null;
org.apache.lucene.index.Fields fields48 = null;
org.apache.lucene.index.Fields fields49 = null;
kuromojiAnalysisTests45.assertFieldsEquals("europarl.lines.txt.gz", indexReader47, fields48, fields49, false);
org.apache.lucene.index.IndexReader indexReader53 = null;
org.apache.lucene.index.PostingsEnum postingsEnum55 = null;
org.apache.lucene.index.PostingsEnum postingsEnum56 = null;
kuromojiAnalysisTests45.assertPositionsSkippingEquals("hi!", indexReader53, (int) (byte) 0, postingsEnum55, postingsEnum56);
kuromojiAnalysisTests45.restoreIndexWriterMaxDocs();
org.junit.Assert.assertNotEquals((java.lang.Object) ruleChain42, (java.lang.Object) kuromojiAnalysisTests45);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests45.testIterationMarkCharFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray14);
org.junit.Assert.assertNotNull(strComparableSet15);
org.junit.Assert.assertNotNull(testRule25);
org.junit.Assert.assertNotNull(ruleChain42);
}
@Test
public void test02304() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02304");
org.apache.lucene.document.FieldType fieldType2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newField("", "<unknown>", fieldType2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02305() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02305");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests13.assertFieldsEquals("europarl.lines.txt.gz", indexReader15, fields16, fields17, false);
kuromojiAnalysisTests13.ensureCleanedUp();
kuromojiAnalysisTests13.resetCheckIndexStatus();
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
kuromojiAnalysisTests13.assertPositionsSkippingEquals("", indexReader24, (int) (byte) 0, postingsEnum26, postingsEnum27);
org.junit.Assert.assertNotEquals((java.lang.Object) "tests.failfast", (java.lang.Object) kuromojiAnalysisTests13);
kuromojiAnalysisTests13.setUp();
java.lang.String[] strArray38 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet39 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray38);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests40 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests40.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet39, (java.lang.Object) kuromojiAnalysisTests40);
java.lang.String str44 = kuromojiAnalysisTests40.getTestName();
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests13, (java.lang.Object) kuromojiAnalysisTests40);
java.nio.file.Path path46 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests40.assertPathHasBeenCleared(path46);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
org.junit.Assert.assertNotNull(strArray38);
org.junit.Assert.assertNotNull(strComparableSet39);
org.junit.Assert.assertEquals("'" + str44 + "' != '" + "<unknown>" + "'", str44, "<unknown>");
}
@Test
public void test02306() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02306");
org.apache.lucene.util.LuceneTestCase.assumeTrue("tests.maxfailures", true);
}
@Test
public void test02307() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02307");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (byte) 10);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path6 = kuromojiAnalysisTests0.getDataPath("tests.slow");
org.junit.Assert.fail("Expected exception of type java.lang.RuntimeException; message: resource not found: tests.slow");
} catch (java.lang.RuntimeException e) {
// Expected exception.
}
}
@Test
public void test02308() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02308");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (byte) 10);
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
java.lang.String str4 = kuromojiAnalysisTests0.getTestName();
org.apache.lucene.index.TermsEnum termsEnum6 = null;
org.apache.lucene.index.TermsEnum termsEnum7 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermStatsEquals("tests.slow", termsEnum6, termsEnum7);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str4 + "' != '" + "<unknown>" + "'", str4, "<unknown>");
}
@Test
public void test02309() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02309");
double[] doubleArray6 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray11 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray6, doubleArray11, (double) (byte) 100);
double[] doubleArray20 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray25 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray20, doubleArray25, (double) (byte) 100);
double[] doubleArray33 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray38 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray33, doubleArray38, (double) (byte) 100);
org.junit.Assert.assertArrayEquals("", doubleArray20, doubleArray33, (double) 0);
org.junit.Assert.assertArrayEquals(doubleArray6, doubleArray20, (-1.0d));
java.lang.Class<?> wildcardClass45 = doubleArray6.getClass();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests46 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader48 = null;
org.apache.lucene.index.Fields fields49 = null;
org.apache.lucene.index.Fields fields50 = null;
kuromojiAnalysisTests46.assertFieldsEquals("europarl.lines.txt.gz", indexReader48, fields49, fields50, false);
kuromojiAnalysisTests46.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain55 = kuromojiAnalysisTests46.failureAndSuccessEvents;
kuromojiAnalysisTests46.resetCheckIndexStatus();
java.lang.String str57 = kuromojiAnalysisTests46.getTestName();
kuromojiAnalysisTests46.setUp();
org.junit.Assert.assertNotEquals("enwiki.random.lines.txt", (java.lang.Object) wildcardClass45, (java.lang.Object) kuromojiAnalysisTests46);
org.elasticsearch.common.settings.Settings settings60 = null;
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.env.NodeEnvironment nodeEnvironment61 = kuromojiAnalysisTests46.newNodeEnvironment(settings60);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(doubleArray6);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray6), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray11);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray11), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(doubleArray20);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray20), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray25);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray25), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(doubleArray33);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray33), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray38);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray38), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(wildcardClass45);
org.junit.Assert.assertNotNull(ruleChain55);
org.junit.Assert.assertEquals("'" + str57 + "' != '" + "<unknown>" + "'", str57, "<unknown>");
}
@Test
public void test02310() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02310");
java.lang.Object obj1 = null;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
kuromojiAnalysisTests2.ensureCleanedUp();
kuromojiAnalysisTests2.resetCheckIndexStatus();
kuromojiAnalysisTests2.setIndexWriterMaxDocs((int) (byte) 0);
org.junit.Assert.assertNotEquals("tests.awaitsfix", obj1, (java.lang.Object) kuromojiAnalysisTests2);
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum18 = null;
kuromojiAnalysisTests2.assertPositionsSkippingEquals("tests.nightly", indexReader15, (-1), postingsEnum17, postingsEnum18);
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.IndexReader indexReader22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests2.assertNormsEquals("random", indexReader21, indexReader22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02311() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02311");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newTextField(random0, "tests.badapples", "europarl.lines.txt.gz", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02312() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02312");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween(100, (int) (byte) 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02313() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02313");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.Terms terms11 = null;
org.apache.lucene.index.Terms terms12 = null;
kuromojiAnalysisTests0.assertTermsEquals("", indexReader10, terms11, terms12, false);
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.Fields fields19 = null;
org.apache.lucene.index.Fields fields20 = null;
kuromojiAnalysisTests0.assertFieldsEquals("<unknown>", indexReader18, fields19, fields20, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests23 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.Fields fields26 = null;
org.apache.lucene.index.Fields fields27 = null;
kuromojiAnalysisTests23.assertFieldsEquals("europarl.lines.txt.gz", indexReader25, fields26, fields27, false);
org.apache.lucene.index.IndexReader indexReader31 = null;
org.apache.lucene.index.PostingsEnum postingsEnum33 = null;
org.apache.lucene.index.PostingsEnum postingsEnum34 = null;
kuromojiAnalysisTests23.assertPositionsSkippingEquals("tests.failfast", indexReader31, 1, postingsEnum33, postingsEnum34);
kuromojiAnalysisTests23.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests23.setUp();
kuromojiAnalysisTests23.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests23.assertPathHasBeenCleared("tests.monster");
org.junit.Assert.assertNotSame((java.lang.Object) fields20, (java.lang.Object) "tests.monster");
}
@Test
public void test02314() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02314");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("hi!", indexReader9, (int) (byte) 0, postingsEnum11, postingsEnum12);
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Terms terms16 = null;
org.apache.lucene.index.Terms terms17 = null;
kuromojiAnalysisTests1.assertTermsEquals("random", indexReader15, terms16, terms17, true);
kuromojiAnalysisTests1.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("tests.nightly", postingsEnum22, postingsEnum23, true);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests26 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.Fields fields29 = null;
org.apache.lucene.index.Fields fields30 = null;
kuromojiAnalysisTests26.assertFieldsEquals("europarl.lines.txt.gz", indexReader28, fields29, fields30, false);
kuromojiAnalysisTests26.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests26.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests26.ensureCleanedUp();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests26);
kuromojiAnalysisTests1.ensureAllSearchContextsReleased();
org.apache.lucene.index.IndexReader indexReader41 = null;
org.apache.lucene.index.PostingsEnum postingsEnum43 = null;
org.apache.lucene.index.PostingsEnum postingsEnum44 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.nightly", indexReader41, (int) (byte) 1, postingsEnum43, postingsEnum44);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests46 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader48 = null;
org.apache.lucene.index.Fields fields49 = null;
org.apache.lucene.index.Fields fields50 = null;
kuromojiAnalysisTests46.assertFieldsEquals("europarl.lines.txt.gz", indexReader48, fields49, fields50, false);
kuromojiAnalysisTests46.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests46.tearDown();
org.apache.lucene.index.IndexReader indexReader57 = null;
org.apache.lucene.index.Terms terms58 = null;
org.apache.lucene.index.Terms terms59 = null;
kuromojiAnalysisTests46.assertTermsEquals("tests.weekly", indexReader57, terms58, terms59, true);
java.lang.Class<?> wildcardClass62 = kuromojiAnalysisTests46.getClass();
org.junit.Assert.assertNotNull((java.lang.Object) wildcardClass62);
org.junit.Assert.assertNotSame("europarl.lines.txt.gz", (java.lang.Object) indexReader41, (java.lang.Object) wildcardClass62);
org.junit.Assert.assertNotNull(wildcardClass62);
}
@Test
public void test02315() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02315");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy1 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy(100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02316() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02316");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfLengthBetween((int) 'a', 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02317() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02317");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomAsciiOfLengthBetween((int) (short) -1, (int) (byte) 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02318() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02318");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (byte) 10);
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Terms terms5 = null;
org.apache.lucene.index.Terms terms6 = null;
kuromojiAnalysisTests0.assertTermsEquals("tests.weekly", indexReader4, terms5, terms6, true);
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) '#');
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.IndexReader indexReader14 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderStatisticsEquals("tests.slow", indexReader13, indexReader14);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02319() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02319");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
kuromojiAnalysisTests0.ensureCleanedUp();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.Fields fields19 = null;
org.apache.lucene.index.Fields fields20 = null;
kuromojiAnalysisTests16.assertFieldsEquals("europarl.lines.txt.gz", indexReader18, fields19, fields20, false);
kuromojiAnalysisTests16.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain25 = kuromojiAnalysisTests16.failureAndSuccessEvents;
kuromojiAnalysisTests16.setUp();
java.util.Locale locale29 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale31 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale33 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale35 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray38 = new java.util.Locale[] { locale29, locale31, locale33, locale35, locale37 };
java.util.Set<java.util.Locale> localeSet39 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray38);
java.util.Locale locale42 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale44 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale46 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale48 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale50 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray51 = new java.util.Locale[] { locale42, locale44, locale46, locale48, locale50 };
java.util.Set<java.util.Locale> localeSet52 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray51);
java.util.List<java.io.Serializable> serializableList53 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray51);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray38, (java.lang.Object[]) localeArray51);
java.util.Locale locale57 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale59 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale61 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale63 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale65 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray66 = new java.util.Locale[] { locale57, locale59, locale61, locale63, locale65 };
java.util.Set<java.util.Locale> localeSet67 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray66);
java.util.List<java.io.Serializable> serializableList68 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray66);
java.util.Set<java.lang.Cloneable> cloneableSet69 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray66);
org.junit.Assert.assertArrayEquals("tests.slow", (java.lang.Object[]) localeArray51, (java.lang.Object[]) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests16, (java.lang.Object) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests16);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests16.testBaseFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain25);
org.junit.Assert.assertNotNull(locale29);
org.junit.Assert.assertEquals(locale29.toString(), "");
org.junit.Assert.assertNotNull(locale31);
org.junit.Assert.assertEquals(locale31.toString(), "");
org.junit.Assert.assertNotNull(locale33);
org.junit.Assert.assertEquals(locale33.toString(), "");
org.junit.Assert.assertNotNull(locale35);
org.junit.Assert.assertEquals(locale35.toString(), "");
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "");
org.junit.Assert.assertNotNull(localeArray38);
org.junit.Assert.assertNotNull(localeSet39);
org.junit.Assert.assertNotNull(locale42);
org.junit.Assert.assertEquals(locale42.toString(), "");
org.junit.Assert.assertNotNull(locale44);
org.junit.Assert.assertEquals(locale44.toString(), "");
org.junit.Assert.assertNotNull(locale46);
org.junit.Assert.assertEquals(locale46.toString(), "");
org.junit.Assert.assertNotNull(locale48);
org.junit.Assert.assertEquals(locale48.toString(), "");
org.junit.Assert.assertNotNull(locale50);
org.junit.Assert.assertEquals(locale50.toString(), "");
org.junit.Assert.assertNotNull(localeArray51);
org.junit.Assert.assertNotNull(localeSet52);
org.junit.Assert.assertNotNull(serializableList53);
org.junit.Assert.assertNotNull(locale57);
org.junit.Assert.assertEquals(locale57.toString(), "");
org.junit.Assert.assertNotNull(locale59);
org.junit.Assert.assertEquals(locale59.toString(), "");
org.junit.Assert.assertNotNull(locale61);
org.junit.Assert.assertEquals(locale61.toString(), "");
org.junit.Assert.assertNotNull(locale63);
org.junit.Assert.assertEquals(locale63.toString(), "");
org.junit.Assert.assertNotNull(locale65);
org.junit.Assert.assertEquals(locale65.toString(), "");
org.junit.Assert.assertNotNull(localeArray66);
org.junit.Assert.assertNotNull(localeSet67);
org.junit.Assert.assertNotNull(serializableList68);
org.junit.Assert.assertNotNull(cloneableSet69);
}
@Test
public void test02320() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02320");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.scaledRandomIntBetween((int) (byte) 10, (int) (short) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalArgumentException; message: max must be >= min: 10, -1");
} catch (java.lang.IllegalArgumentException e) {
// Expected exception.
}
}
@Test
public void test02321() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02321");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "tests.awaitsfix", "tests.awaitsfix", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02322() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02322");
short[] shortArray2 = new short[] { (byte) 10 };
short[] shortArray4 = new short[] { (byte) 10 };
short[] shortArray6 = new short[] { (byte) 10 };
short[] shortArray8 = new short[] { (byte) 10 };
short[][] shortArray9 = new short[][] { shortArray2, shortArray4, shortArray6, shortArray8 };
// The following exception was thrown during execution in test generation
try {
java.util.List<short[]> shortArrayList10 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) -1, shortArray9);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalArgumentException; message: fromIndex(0) > toIndex(-1)");
} catch (java.lang.IllegalArgumentException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(shortArray2);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray2), "[10]");
org.junit.Assert.assertNotNull(shortArray4);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray4), "[10]");
org.junit.Assert.assertNotNull(shortArray6);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray6), "[10]");
org.junit.Assert.assertNotNull(shortArray8);
org.junit.Assert.assertEquals(java.util.Arrays.toString(shortArray8), "[10]");
org.junit.Assert.assertNotNull(shortArray9);
}
@Test
public void test02323() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02323");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule9 = kuromojiAnalysisTests0.ruleChain;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests10 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.Fields fields13 = null;
org.apache.lucene.index.Fields fields14 = null;
kuromojiAnalysisTests10.assertFieldsEquals("europarl.lines.txt.gz", indexReader12, fields13, fields14, false);
kuromojiAnalysisTests10.ensureCleanedUp();
kuromojiAnalysisTests10.ensureCleanedUp();
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests10);
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.IndexReader indexReader22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests10.assertFieldInfosEquals("tests.badapples", indexReader21, indexReader22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule9);
}
@Test
public void test02324() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02324");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path2 = org.apache.lucene.util.LuceneTestCase.createTempFile("tests.maxfailures", "hi!");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02325() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02325");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests9.assertDocsEnumEquals("tests.badapples", postingsEnum14, postingsEnum15, true);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests9.ruleChain;
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests9.assertDocsSkippingEquals("tests.maxfailures", indexReader20, (int) (byte) 100, postingsEnum22, postingsEnum23, false);
kuromojiAnalysisTests9.resetCheckIndexStatus();
kuromojiAnalysisTests9.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.Terms terms30 = null;
org.apache.lucene.index.Terms terms31 = null;
kuromojiAnalysisTests9.assertTermsEquals("hi!", indexReader29, terms30, terms31, false);
org.apache.lucene.index.IndexReader indexReader35 = null;
org.apache.lucene.index.IndexReader indexReader36 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests9.assertDeletedDocsEquals("enwiki.random.lines.txt", indexReader35, indexReader36);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02326() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02326");
org.junit.Assert.assertNotEquals("<unknown>", (long) 'a', 0L);
}
@Test
public void test02327() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02327");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween((int) (byte) -1, (int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02328() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02328");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("<unknown>", indexReader14, (int) '#', postingsEnum16, postingsEnum17);
kuromojiAnalysisTests0.setIndexWriterMaxDocs((-1));
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.IndexReader indexReader23 = null;
org.apache.lucene.index.IndexReader indexReader24 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermVectorsEquals("tests.slow", indexReader23, indexReader24);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02329() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02329");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newTextField("<unknown>", "tests.monster", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02330() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02330");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy2 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy(true, (int) '4');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02331() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02331");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.Fields fields20 = null;
org.apache.lucene.index.Fields fields21 = null;
kuromojiAnalysisTests0.assertFieldsEquals("enwiki.random.lines.txt", indexReader19, fields20, fields21, false);
org.apache.lucene.index.TermsEnum termsEnum25 = null;
org.apache.lucene.index.TermsEnum termsEnum26 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermStatsEquals("enwiki.random.lines.txt", termsEnum25, termsEnum26);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02332() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02332");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.Fields fields23 = null;
org.apache.lucene.index.Fields fields24 = null;
kuromojiAnalysisTests0.assertFieldsEquals("", indexReader22, fields23, fields24, false);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testBaseFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02333() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02333");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newStringField("tests.monster", "tests.badapples", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02334() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02334");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
kuromojiAnalysisTests0.ensureCleanedUp();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests13.assertFieldsEquals("europarl.lines.txt.gz", indexReader15, fields16, fields17, false);
kuromojiAnalysisTests13.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain22 = kuromojiAnalysisTests13.failureAndSuccessEvents;
kuromojiAnalysisTests13.resetCheckIndexStatus();
kuromojiAnalysisTests13.assertPathHasBeenCleared("random");
java.lang.String str26 = kuromojiAnalysisTests13.getTestName();
org.junit.rules.RuleChain ruleChain27 = kuromojiAnalysisTests13.failureAndSuccessEvents;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain27;
org.apache.lucene.index.IndexReader indexReader30 = null;
org.apache.lucene.index.PostingsEnum postingsEnum32 = null;
org.apache.lucene.index.PostingsEnum postingsEnum33 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.awaitsfix", indexReader30, 100, postingsEnum32, postingsEnum33, true);
org.junit.Assert.assertNotNull((java.lang.Object) true);
org.junit.Assert.assertNotNull(ruleChain22);
org.junit.Assert.assertEquals("'" + str26 + "' != '" + "<unknown>" + "'", str26, "<unknown>");
org.junit.Assert.assertNotNull(ruleChain27);
}
@Test
public void test02335() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02335");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.iterations((int) '4', 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalArgumentException; message: max must be >= min: 52, 1");
} catch (java.lang.IllegalArgumentException e) {
// Expected exception.
}
}
@Test
public void test02336() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02336");
org.apache.lucene.analysis.TokenStream tokenStream0 = null;
double[] doubleArray8 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray13 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray8, doubleArray13, (double) (byte) 100);
double[] doubleArray22 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray27 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray22, doubleArray27, (double) (byte) 100);
double[] doubleArray35 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray40 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray35, doubleArray40, (double) (byte) 100);
org.junit.Assert.assertArrayEquals("", doubleArray22, doubleArray35, (double) 0);
org.junit.Assert.assertArrayEquals(doubleArray8, doubleArray22, (-1.0d));
double[] doubleArray53 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray58 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray53, doubleArray58, (double) (byte) 100);
double[] doubleArray66 = new double[] { 0, (-1), 100L, 1.0f };
double[] doubleArray71 = new double[] { (byte) 10, 10.0d, 10.0f, (short) 100 };
org.junit.Assert.assertArrayEquals("", doubleArray66, doubleArray71, (double) (byte) 100);
org.junit.Assert.assertArrayEquals("", doubleArray53, doubleArray66, (double) 0);
org.junit.Assert.assertArrayEquals("random", doubleArray8, doubleArray66, (double) 10.0f);
java.lang.String[] strArray84 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet85 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray84);
org.junit.Assert.assertNotEquals("hi!", (java.lang.Object) doubleArray8, (java.lang.Object) strArray84);
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.index.analysis.KuromojiAnalysisTests.assertSimpleTSOutput(tokenStream0, strArray84);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(doubleArray8);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray8), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray13);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray13), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(doubleArray22);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray22), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray27);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray27), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(doubleArray35);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray35), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray40);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray40), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(doubleArray53);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray53), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray58);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray58), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(doubleArray66);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray66), "[0.0, -1.0, 100.0, 1.0]");
org.junit.Assert.assertNotNull(doubleArray71);
org.junit.Assert.assertEquals(java.util.Arrays.toString(doubleArray71), "[10.0, 10.0, 10.0, 100.0]");
org.junit.Assert.assertNotNull(strArray84);
org.junit.Assert.assertNotNull(strComparableSet85);
}
@Test
public void test02337() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02337");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.Fields fields23 = null;
org.apache.lucene.index.Fields fields24 = null;
kuromojiAnalysisTests0.assertFieldsEquals("", indexReader22, fields23, fields24, false);
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.Terms terms29 = null;
org.apache.lucene.index.Terms terms30 = null;
kuromojiAnalysisTests0.assertTermsEquals("", indexReader28, terms29, terms30, true);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests34 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader36 = null;
org.apache.lucene.index.Fields fields37 = null;
org.apache.lucene.index.Fields fields38 = null;
kuromojiAnalysisTests34.assertFieldsEquals("europarl.lines.txt.gz", indexReader36, fields37, fields38, false);
kuromojiAnalysisTests34.ensureCleanedUp();
kuromojiAnalysisTests34.resetCheckIndexStatus();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests43 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader45 = null;
org.apache.lucene.index.Fields fields46 = null;
org.apache.lucene.index.Fields fields47 = null;
kuromojiAnalysisTests43.assertFieldsEquals("random", indexReader45, fields46, fields47, true);
org.junit.Assert.assertNotSame("random", (java.lang.Object) kuromojiAnalysisTests34, (java.lang.Object) fields46);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) fields46);
kuromojiAnalysisTests0.ensureCleanedUp();
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray53 = kuromojiAnalysisTests0.tmpPaths();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02338() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02338");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween(0, (int) (byte) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02339() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02339");
java.lang.reflect.GenericDeclaration[] genericDeclarationArray0 = new java.lang.reflect.GenericDeclaration[] {};
java.util.Set<java.lang.reflect.GenericDeclaration> genericDeclarationSet1 = org.apache.lucene.util.LuceneTestCase.asSet(genericDeclarationArray0);
// The following exception was thrown during execution in test generation
try {
java.lang.reflect.GenericDeclaration genericDeclaration2 = org.elasticsearch.test.ESTestCase.randomFrom(genericDeclarationArray0);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(genericDeclarationArray0);
org.junit.Assert.assertNotNull(genericDeclarationSet1);
}
@Test
public void test02340() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02340");
org.apache.lucene.document.FieldType fieldType2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newField("tests.slow", "tests.badapples", fieldType2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02341() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02341");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
kuromojiAnalysisTests0.ensureCleanedUp();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests16 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.Fields fields19 = null;
org.apache.lucene.index.Fields fields20 = null;
kuromojiAnalysisTests16.assertFieldsEquals("europarl.lines.txt.gz", indexReader18, fields19, fields20, false);
kuromojiAnalysisTests16.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain25 = kuromojiAnalysisTests16.failureAndSuccessEvents;
kuromojiAnalysisTests16.setUp();
java.util.Locale locale29 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale31 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale33 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale35 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray38 = new java.util.Locale[] { locale29, locale31, locale33, locale35, locale37 };
java.util.Set<java.util.Locale> localeSet39 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray38);
java.util.Locale locale42 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale44 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale46 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale48 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale50 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray51 = new java.util.Locale[] { locale42, locale44, locale46, locale48, locale50 };
java.util.Set<java.util.Locale> localeSet52 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray51);
java.util.List<java.io.Serializable> serializableList53 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray51);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray38, (java.lang.Object[]) localeArray51);
java.util.Locale locale57 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale59 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale61 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale63 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale65 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray66 = new java.util.Locale[] { locale57, locale59, locale61, locale63, locale65 };
java.util.Set<java.util.Locale> localeSet67 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray66);
java.util.List<java.io.Serializable> serializableList68 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray66);
java.util.Set<java.lang.Cloneable> cloneableSet69 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray66);
org.junit.Assert.assertArrayEquals("tests.slow", (java.lang.Object[]) localeArray51, (java.lang.Object[]) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests16, (java.lang.Object) localeArray66);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests16);
org.junit.rules.RuleChain ruleChain73 = null;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain73;
org.apache.lucene.index.IndexReader indexReader76 = null;
org.apache.lucene.index.IndexReader indexReader77 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertFieldInfosEquals("", indexReader76, indexReader77);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain25);
org.junit.Assert.assertNotNull(locale29);
org.junit.Assert.assertEquals(locale29.toString(), "");
org.junit.Assert.assertNotNull(locale31);
org.junit.Assert.assertEquals(locale31.toString(), "");
org.junit.Assert.assertNotNull(locale33);
org.junit.Assert.assertEquals(locale33.toString(), "");
org.junit.Assert.assertNotNull(locale35);
org.junit.Assert.assertEquals(locale35.toString(), "");
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "");
org.junit.Assert.assertNotNull(localeArray38);
org.junit.Assert.assertNotNull(localeSet39);
org.junit.Assert.assertNotNull(locale42);
org.junit.Assert.assertEquals(locale42.toString(), "");
org.junit.Assert.assertNotNull(locale44);
org.junit.Assert.assertEquals(locale44.toString(), "");
org.junit.Assert.assertNotNull(locale46);
org.junit.Assert.assertEquals(locale46.toString(), "");
org.junit.Assert.assertNotNull(locale48);
org.junit.Assert.assertEquals(locale48.toString(), "");
org.junit.Assert.assertNotNull(locale50);
org.junit.Assert.assertEquals(locale50.toString(), "");
org.junit.Assert.assertNotNull(localeArray51);
org.junit.Assert.assertNotNull(localeSet52);
org.junit.Assert.assertNotNull(serializableList53);
org.junit.Assert.assertNotNull(locale57);
org.junit.Assert.assertEquals(locale57.toString(), "");
org.junit.Assert.assertNotNull(locale59);
org.junit.Assert.assertEquals(locale59.toString(), "");
org.junit.Assert.assertNotNull(locale61);
org.junit.Assert.assertEquals(locale61.toString(), "");
org.junit.Assert.assertNotNull(locale63);
org.junit.Assert.assertEquals(locale63.toString(), "");
org.junit.Assert.assertNotNull(locale65);
org.junit.Assert.assertEquals(locale65.toString(), "");
org.junit.Assert.assertNotNull(localeArray66);
org.junit.Assert.assertNotNull(localeSet67);
org.junit.Assert.assertNotNull(serializableList68);
org.junit.Assert.assertNotNull(cloneableSet69);
}
@Test
public void test02342() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02342");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.ensureCleanedUp();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testKatakanaStemFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02343() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02343");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
java.lang.String[] strArray15 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet16 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray15);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests17 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests17.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet16, (java.lang.Object) kuromojiAnalysisTests17);
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests17.assertDocsEnumEquals("tests.badapples", postingsEnum22, postingsEnum23, true);
org.junit.rules.TestRule testRule26 = kuromojiAnalysisTests17.ruleChain;
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
org.apache.lucene.index.PostingsEnum postingsEnum31 = null;
kuromojiAnalysisTests17.assertDocsSkippingEquals("tests.maxfailures", indexReader28, (int) (byte) 100, postingsEnum30, postingsEnum31, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests34 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader36 = null;
org.apache.lucene.index.Fields fields37 = null;
org.apache.lucene.index.Fields fields38 = null;
kuromojiAnalysisTests34.assertFieldsEquals("europarl.lines.txt.gz", indexReader36, fields37, fields38, false);
kuromojiAnalysisTests34.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain43 = kuromojiAnalysisTests34.failureAndSuccessEvents;
kuromojiAnalysisTests17.failureAndSuccessEvents = ruleChain43;
kuromojiAnalysisTests1.failureAndSuccessEvents = ruleChain43;
org.apache.lucene.index.PostingsEnum postingsEnum47 = null;
org.apache.lucene.index.PostingsEnum postingsEnum48 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("<unknown>", postingsEnum47, postingsEnum48, true);
kuromojiAnalysisTests1.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader53 = null;
org.apache.lucene.index.Fields fields54 = null;
org.apache.lucene.index.Fields fields55 = null;
kuromojiAnalysisTests1.assertFieldsEquals("tests.awaitsfix", indexReader53, fields54, fields55, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests58 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader60 = null;
org.apache.lucene.index.Fields fields61 = null;
org.apache.lucene.index.Fields fields62 = null;
kuromojiAnalysisTests58.assertFieldsEquals("europarl.lines.txt.gz", indexReader60, fields61, fields62, false);
kuromojiAnalysisTests58.ensureCleanedUp();
kuromojiAnalysisTests58.resetCheckIndexStatus();
kuromojiAnalysisTests58.ensureCleanedUp();
org.junit.Assert.assertNotEquals("", (java.lang.Object) fields54, (java.lang.Object) kuromojiAnalysisTests58);
java.io.Reader reader69 = null;
// The following exception was thrown during execution in test generation
try {
java.lang.String str70 = kuromojiAnalysisTests58.readFully(reader69);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray15);
org.junit.Assert.assertNotNull(strComparableSet16);
org.junit.Assert.assertNotNull(testRule26);
org.junit.Assert.assertNotNull(ruleChain43);
}
@Test
public void test02344() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02344");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newTextField("tests.slow", "tests.awaitsfix", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02345() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02345");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween((int) (short) 1, (int) (short) 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02346() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02346");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.Fields fields14 = null;
org.apache.lucene.index.Fields fields15 = null;
kuromojiAnalysisTests1.assertFieldsEquals("enwiki.random.lines.txt", indexReader13, fields14, fields15, false);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests1.ruleChain;
org.junit.Assert.assertNotEquals((java.lang.Object) (-1.0d), (java.lang.Object) kuromojiAnalysisTests1);
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
kuromojiAnalysisTests1.assertDocsSkippingEquals("", indexReader21, (int) '4', postingsEnum23, postingsEnum24, false);
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
org.apache.lucene.index.PostingsEnum postingsEnum31 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.monster", indexReader28, (int) (short) 0, postingsEnum30, postingsEnum31);
org.apache.lucene.index.Terms terms34 = null;
org.apache.lucene.index.Terms terms35 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertTermsStatisticsEquals("", terms34, terms35);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02347() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02347");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween((int) (byte) 100, (int) ' ');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02348() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02348");
int[] intArray1 = new int[] { '#' };
int[] intArray3 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray1, intArray3);
int[] intArray9 = new int[] { '#' };
int[] intArray11 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray9, intArray11);
int[] intArray14 = new int[] { '#' };
int[] intArray16 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray14, intArray16);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray9, intArray14);
int[] intArray21 = new int[] { '#' };
int[] intArray23 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray21, intArray23);
int[] intArray26 = new int[] { '#' };
int[] intArray28 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray26, intArray28);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray21, intArray26);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", intArray9, intArray26);
int[] intArray35 = new int[] { '#' };
int[] intArray37 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray35, intArray37);
int[] intArray40 = new int[] { '#' };
int[] intArray42 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray40, intArray42);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray35, intArray40);
int[] intArray47 = new int[] { '#' };
int[] intArray49 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray47, intArray49);
int[] intArray52 = new int[] { '#' };
int[] intArray54 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray52, intArray54);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray47, intArray52);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", intArray35, intArray52);
org.junit.Assert.assertArrayEquals("random", intArray26, intArray35);
org.junit.Assert.assertArrayEquals(intArray1, intArray35);
int[] intArray63 = new int[] { '#' };
int[] intArray65 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray63, intArray65);
int[] intArray68 = new int[] { '#' };
int[] intArray70 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray68, intArray70);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray63, intArray68);
int[] intArray75 = new int[] { '#' };
int[] intArray77 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray75, intArray77);
int[] intArray80 = new int[] { '#' };
int[] intArray82 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray80, intArray82);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray75, intArray80);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", intArray63, intArray80);
org.junit.Assert.assertArrayEquals(intArray35, intArray80);
org.junit.Assert.assertNotNull(intArray1);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray1), "[35]");
org.junit.Assert.assertNotNull(intArray3);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray3), "[35]");
org.junit.Assert.assertNotNull(intArray9);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray9), "[35]");
org.junit.Assert.assertNotNull(intArray11);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray11), "[35]");
org.junit.Assert.assertNotNull(intArray14);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray14), "[35]");
org.junit.Assert.assertNotNull(intArray16);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray16), "[35]");
org.junit.Assert.assertNotNull(intArray21);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray21), "[35]");
org.junit.Assert.assertNotNull(intArray23);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray23), "[35]");
org.junit.Assert.assertNotNull(intArray26);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray26), "[35]");
org.junit.Assert.assertNotNull(intArray28);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray28), "[35]");
org.junit.Assert.assertNotNull(intArray35);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray35), "[35]");
org.junit.Assert.assertNotNull(intArray37);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray37), "[35]");
org.junit.Assert.assertNotNull(intArray40);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray40), "[35]");
org.junit.Assert.assertNotNull(intArray42);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray42), "[35]");
org.junit.Assert.assertNotNull(intArray47);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray47), "[35]");
org.junit.Assert.assertNotNull(intArray49);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray49), "[35]");
org.junit.Assert.assertNotNull(intArray52);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray52), "[35]");
org.junit.Assert.assertNotNull(intArray54);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray54), "[35]");
org.junit.Assert.assertNotNull(intArray63);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray63), "[35]");
org.junit.Assert.assertNotNull(intArray65);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray65), "[35]");
org.junit.Assert.assertNotNull(intArray68);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray68), "[35]");
org.junit.Assert.assertNotNull(intArray70);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray70), "[35]");
org.junit.Assert.assertNotNull(intArray75);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray75), "[35]");
org.junit.Assert.assertNotNull(intArray77);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray77), "[35]");
org.junit.Assert.assertNotNull(intArray80);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray80), "[35]");
org.junit.Assert.assertNotNull(intArray82);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray82), "[35]");
}
@Test
public void test02349() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02349");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
java.lang.String str11 = kuromojiAnalysisTests0.getTestName();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str11 + "' != '" + "<unknown>" + "'", str11, "<unknown>");
}
@Test
public void test02350() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02350");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
java.nio.file.Path path17 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertPathHasBeenCleared(path17);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02351() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02351");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween(0, (int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02352() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02352");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.scaledRandomIntBetween((int) (byte) 0, 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02353() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02353");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfCodepointLengthBetween((int) (short) 10, 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02354() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02354");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.Fields fields12 = null;
org.apache.lucene.index.Fields fields13 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.nightly", indexReader11, fields12, fields13, true);
java.io.Reader reader16 = null;
// The following exception was thrown during execution in test generation
try {
java.lang.String str17 = kuromojiAnalysisTests0.readFully(reader16);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02355() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02355");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.elasticsearch.common.settings.Settings settings23 = null;
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.env.NodeEnvironment nodeEnvironment24 = kuromojiAnalysisTests0.newNodeEnvironment(settings23);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02356() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02356");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.ensureCleanedUp();
kuromojiAnalysisTests1.resetCheckIndexStatus();
kuromojiAnalysisTests1.ensureCleanedUp();
kuromojiAnalysisTests1.ensureCheckIndexPassed();
org.junit.Assert.assertNotNull("tests.badapples", (java.lang.Object) kuromojiAnalysisTests1);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.TermsEnum termsEnum15 = null;
org.apache.lucene.index.TermsEnum termsEnum16 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertTermsEnumEquals("tests.failfast", indexReader14, termsEnum15, termsEnum16, false);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02357() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02357");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain9 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.junit.rules.TestRule testRule12 = kuromojiAnalysisTests0.ruleChain;
java.util.Locale locale18 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale20 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale22 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale24 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale26 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray27 = new java.util.Locale[] { locale18, locale20, locale22, locale24, locale26 };
java.util.Set<java.util.Locale> localeSet28 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray27);
java.util.List<java.io.Serializable> serializableList29 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray27);
org.junit.Assert.assertNotSame("", (java.lang.Object) localeArray27, (java.lang.Object) 0.0f);
java.util.Locale locale35 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale37 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale39 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale41 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale43 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray44 = new java.util.Locale[] { locale35, locale37, locale39, locale41, locale43 };
java.util.Set<java.util.Locale> localeSet45 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray44);
java.util.List<java.io.Serializable> serializableList46 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray44);
org.junit.Assert.assertNotSame("", (java.lang.Object) localeArray44, (java.lang.Object) 0.0f);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", (java.lang.Object[]) localeArray27, (java.lang.Object[]) localeArray44);
java.util.Locale locale51 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale53 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale55 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale57 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale59 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray60 = new java.util.Locale[] { locale51, locale53, locale55, locale57, locale59 };
java.util.Set<java.util.Locale> localeSet61 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray60);
org.junit.Assert.assertArrayEquals("tests.nightly", (java.lang.Object[]) localeArray27, (java.lang.Object[]) localeArray60);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) localeArray60);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(1);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testIterationMarkCharFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain9);
org.junit.Assert.assertNotNull(testRule12);
org.junit.Assert.assertNotNull(locale18);
org.junit.Assert.assertEquals(locale18.toString(), "");
org.junit.Assert.assertNotNull(locale20);
org.junit.Assert.assertEquals(locale20.toString(), "");
org.junit.Assert.assertNotNull(locale22);
org.junit.Assert.assertEquals(locale22.toString(), "");
org.junit.Assert.assertNotNull(locale24);
org.junit.Assert.assertEquals(locale24.toString(), "");
org.junit.Assert.assertNotNull(locale26);
org.junit.Assert.assertEquals(locale26.toString(), "");
org.junit.Assert.assertNotNull(localeArray27);
org.junit.Assert.assertNotNull(localeSet28);
org.junit.Assert.assertNotNull(serializableList29);
org.junit.Assert.assertNotNull(locale35);
org.junit.Assert.assertEquals(locale35.toString(), "");
org.junit.Assert.assertNotNull(locale37);
org.junit.Assert.assertEquals(locale37.toString(), "");
org.junit.Assert.assertNotNull(locale39);
org.junit.Assert.assertEquals(locale39.toString(), "");
org.junit.Assert.assertNotNull(locale41);
org.junit.Assert.assertEquals(locale41.toString(), "");
org.junit.Assert.assertNotNull(locale43);
org.junit.Assert.assertEquals(locale43.toString(), "");
org.junit.Assert.assertNotNull(localeArray44);
org.junit.Assert.assertNotNull(localeSet45);
org.junit.Assert.assertNotNull(serializableList46);
org.junit.Assert.assertNotNull(locale51);
org.junit.Assert.assertEquals(locale51.toString(), "");
org.junit.Assert.assertNotNull(locale53);
org.junit.Assert.assertEquals(locale53.toString(), "");
org.junit.Assert.assertNotNull(locale55);
org.junit.Assert.assertEquals(locale55.toString(), "");
org.junit.Assert.assertNotNull(locale57);
org.junit.Assert.assertEquals(locale57.toString(), "");
org.junit.Assert.assertNotNull(locale59);
org.junit.Assert.assertEquals(locale59.toString(), "");
org.junit.Assert.assertNotNull(localeArray60);
org.junit.Assert.assertNotNull(localeSet61);
}
@Test
public void test02358() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02358");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.IndexReader indexReader22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDocValuesEquals("tests.weekly", indexReader21, indexReader22);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02359() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02359");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newTextField("tests.monster", "hi!", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02360() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02360");
java.lang.Runnable runnable0 = null;
java.util.concurrent.TimeUnit timeUnit2 = null;
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.test.ESTestCase.assertBusy(runnable0, (long) (byte) 0, timeUnit2);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02361() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02361");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfLengthBetween((int) (short) 10, 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02362() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02362");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy2 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy(true, (int) (byte) 0);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02363() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02363");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain9 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("enwiki.random.lines.txt", indexReader12, 100, postingsEnum14, postingsEnum15, false);
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.Fields fields20 = null;
org.apache.lucene.index.Fields fields21 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.monster", indexReader19, fields20, fields21, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests24 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader26 = null;
org.apache.lucene.index.Fields fields27 = null;
org.apache.lucene.index.Fields fields28 = null;
kuromojiAnalysisTests24.assertFieldsEquals("europarl.lines.txt.gz", indexReader26, fields27, fields28, false);
kuromojiAnalysisTests24.ensureCleanedUp();
kuromojiAnalysisTests24.resetCheckIndexStatus();
kuromojiAnalysisTests24.setIndexWriterMaxDocs((int) (byte) 0);
org.junit.rules.RuleChain ruleChain35 = kuromojiAnalysisTests24.failureAndSuccessEvents;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain35;
org.apache.lucene.index.TermsEnum termsEnum38 = null;
org.apache.lucene.index.TermsEnum termsEnum39 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermStatsEquals("tests.awaitsfix", termsEnum38, termsEnum39);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain9);
org.junit.Assert.assertNotNull(ruleChain35);
}
@Test
public void test02364() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02364");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("europarl.lines.txt.gz", indexReader14, terms15, terms16, false);
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.TermsEnum termsEnum21 = null;
org.apache.lucene.index.TermsEnum termsEnum22 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("tests.badapples", indexReader20, termsEnum21, termsEnum22, true);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02365() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02365");
java.util.Random random0 = null;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
kuromojiAnalysisTests2.assertPathHasBeenCleared("tests.slow");
org.junit.rules.TestRule testRule11 = kuromojiAnalysisTests2.ruleChain;
org.junit.rules.TestRule testRule12 = kuromojiAnalysisTests2.ruleChain;
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
kuromojiAnalysisTests2.assertPositionsSkippingEquals("tests.slow", indexReader14, (int) (short) 1, postingsEnum16, postingsEnum17);
org.junit.rules.TestRule testRule19 = kuromojiAnalysisTests2.ruleChain;
org.apache.lucene.document.FieldType fieldType20 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field21 = org.apache.lucene.util.LuceneTestCase.newField(random0, "tests.monster", (java.lang.Object) testRule19, fieldType20);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule11);
org.junit.Assert.assertNotNull(testRule12);
org.junit.Assert.assertNotNull(testRule19);
}
@Test
public void test02366() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02366");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "tests.nightly", "tests.badapples", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02367() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02367");
java.lang.Iterable<java.util.Locale>[] localeIterableArray1 = null;
// The following exception was thrown during execution in test generation
try {
java.util.List<java.lang.Iterable<java.util.Locale>> localeIterableList2 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (byte) 1, localeIterableArray1);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02368() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02368");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests9.assertDocsEnumEquals("tests.badapples", postingsEnum14, postingsEnum15, true);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests9.ruleChain;
kuromojiAnalysisTests9.setUp();
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.Terms terms22 = null;
org.apache.lucene.index.Terms terms23 = null;
kuromojiAnalysisTests9.assertTermsEquals("tests.slow", indexReader21, terms22, terms23, false);
java.nio.file.Path path26 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests9.assertPathHasBeenCleared(path26);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02369() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02369");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.Terms terms12 = null;
org.apache.lucene.index.Terms terms13 = null;
kuromojiAnalysisTests0.assertTermsEquals("europarl.lines.txt.gz", indexReader11, terms12, terms13, true);
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.IndexReader indexReader18 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertNormsEquals("hi!", indexReader17, indexReader18);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02370() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02370");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.slow", indexReader13, (-1), postingsEnum15, postingsEnum16, true);
kuromojiAnalysisTests0.setUp();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testReadingFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02371() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02371");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newStringField("", "tests.awaitsfix", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02372() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02372");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "enwiki.random.lines.txt", "tests.awaitsfix", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02373() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02373");
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray3 = org.elasticsearch.test.ESTestCase.generateRandomStringArray(10, (-1), true);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02374() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02374");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((-1));
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) 'a');
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testJapaneseStopFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02375() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02375");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween((int) (byte) 1, (int) (byte) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02376() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02376");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.setUp();
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.env.NodeEnvironment nodeEnvironment15 = kuromojiAnalysisTests0.newNodeEnvironment();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02377() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02377");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomAsciiOfLengthBetween((int) (short) 0, (int) (short) 10);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02378() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02378");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests0.tearDown();
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray11 = kuromojiAnalysisTests0.tmpPaths();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02379() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02379");
java.text.Collator collator0 = null;
// The following exception was thrown during execution in test generation
try {
int int3 = org.apache.lucene.util.LuceneTestCase.collate(collator0, "tests.weekly", "random");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02380() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02380");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.IndexReader indexReader13 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermVectorsEquals("enwiki.random.lines.txt", indexReader12, indexReader13);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02381() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02381");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests9.assertDocsEnumEquals("tests.badapples", postingsEnum14, postingsEnum15, true);
org.junit.rules.TestRule testRule18 = kuromojiAnalysisTests9.ruleChain;
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests9.assertDocsSkippingEquals("tests.maxfailures", indexReader20, (int) (byte) 100, postingsEnum22, postingsEnum23, false);
kuromojiAnalysisTests9.resetCheckIndexStatus();
kuromojiAnalysisTests9.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.IndexReader indexReader30 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests9.assertNormsEquals("tests.maxfailures", indexReader29, indexReader30);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
org.junit.Assert.assertNotNull(testRule18);
}
@Test
public void test02382() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02382");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.slow", indexReader11, (int) (short) -1, postingsEnum13, postingsEnum14, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("europarl.lines.txt.gz", postingsEnum20, postingsEnum21, false);
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.IndexReader indexReader26 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertFieldInfosEquals("tests.badapples", indexReader25, indexReader26);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02383() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02383");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Fields fields15 = null;
org.apache.lucene.index.Fields fields16 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.slow", indexReader14, fields15, fields16, true);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testJapaneseStopFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02384() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02384");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.ensureCheckIndexPassed();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests12 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Fields fields15 = null;
org.apache.lucene.index.Fields fields16 = null;
kuromojiAnalysisTests12.assertFieldsEquals("europarl.lines.txt.gz", indexReader14, fields15, fields16, false);
org.apache.lucene.index.IndexReader indexReader20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests12.assertPositionsSkippingEquals("hi!", indexReader20, (int) (byte) 0, postingsEnum22, postingsEnum23);
kuromojiAnalysisTests12.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests12.resetCheckIndexStatus();
kuromojiAnalysisTests12.setUp();
kuromojiAnalysisTests12.overrideTestDefaultQueryCache();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests12);
org.apache.lucene.index.IndexReader indexReader31 = null;
org.apache.lucene.index.TermsEnum termsEnum32 = null;
org.apache.lucene.index.TermsEnum termsEnum33 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests12.assertTermsEnumEquals("", indexReader31, termsEnum32, termsEnum33, true);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
}
@Test
public void test02385() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02385");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween((int) '#', (int) ' ');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02386() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02386");
org.junit.Assert.assertFalse("enwiki.random.lines.txt", false);
}
@Test
public void test02387() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02387");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((-1));
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.monster");
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.TermsEnum termsEnum26 = null;
org.apache.lucene.index.TermsEnum termsEnum27 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("hi!", indexReader25, termsEnum26, termsEnum27, false);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02388() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02388");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomAsciiOfLengthBetween(0, (int) (short) 0);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02389() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02389");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests13.assertFieldsEquals("europarl.lines.txt.gz", indexReader15, fields16, fields17, false);
kuromojiAnalysisTests13.ensureCleanedUp();
kuromojiAnalysisTests13.resetCheckIndexStatus();
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
kuromojiAnalysisTests13.assertPositionsSkippingEquals("", indexReader24, (int) (byte) 0, postingsEnum26, postingsEnum27);
org.junit.Assert.assertNotEquals((java.lang.Object) "tests.failfast", (java.lang.Object) kuromojiAnalysisTests13);
kuromojiAnalysisTests13.setUp();
kuromojiAnalysisTests13.overrideTestDefaultQueryCache();
kuromojiAnalysisTests13.assertPathHasBeenCleared("random");
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.TermsEnum termsEnum36 = null;
org.apache.lucene.index.TermsEnum termsEnum37 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests13.assertTermStatsEquals("tests.awaitsfix", termsEnum36, termsEnum37);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
}
@Test
public void test02390() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02390");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests9.assertDocsEnumEquals("tests.badapples", postingsEnum14, postingsEnum15, true);
org.apache.lucene.index.Terms terms19 = null;
org.apache.lucene.index.Terms terms20 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests9.assertTermsStatisticsEquals("tests.badapples", terms19, terms20);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
}
@Test
public void test02391() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02391");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader10, 1, postingsEnum12, postingsEnum13);
kuromojiAnalysisTests0.assertPathHasBeenCleared("europarl.lines.txt.gz");
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.IndexReader indexReader20 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDeletedDocsEquals("tests.awaitsfix", indexReader19, indexReader20);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02392() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02392");
org.junit.Assert.assertEquals(10.0d, (double) ' ', (double) 100.0f);
}
@Test
public void test02393() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02393");
// The following exception was thrown during execution in test generation
try {
java.lang.String str1 = org.elasticsearch.test.ESTestCase.randomAsciiOfLength((-1));
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02394() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02394");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.iterations((int) (byte) 0, (int) '4');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02395() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02395");
java.lang.Runnable runnable0 = null;
java.util.concurrent.TimeUnit timeUnit2 = null;
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.test.ESTestCase.assertBusy(runnable0, (long) (short) 100, timeUnit2);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02396() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02396");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.IndexReader indexReader11 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertStoredFieldsEquals("tests.nightly", indexReader10, indexReader11);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02397() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02397");
java.util.Locale locale3 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale5 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale7 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale9 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale11 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray12 = new java.util.Locale[] { locale3, locale5, locale7, locale9, locale11 };
java.util.Set<java.util.Locale> localeSet13 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray12);
java.util.List<java.io.Serializable> serializableList14 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray12);
java.util.Set<java.lang.Cloneable> cloneableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray12);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray12, (java.lang.Object) (byte) -1);
java.util.Locale locale20 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale22 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale24 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale26 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale28 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray29 = new java.util.Locale[] { locale20, locale22, locale24, locale26, locale28 };
java.util.Set<java.util.Locale> localeSet30 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray29);
java.util.List<java.io.Serializable> serializableList31 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray29);
java.util.Set<java.lang.Cloneable> cloneableSet32 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray29);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray29, (java.lang.Object) (byte) -1);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray12, (java.lang.Object[]) localeArray29);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests36 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader38 = null;
org.apache.lucene.index.Fields fields39 = null;
org.apache.lucene.index.Fields fields40 = null;
kuromojiAnalysisTests36.assertFieldsEquals("europarl.lines.txt.gz", indexReader38, fields39, fields40, false);
kuromojiAnalysisTests36.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain45 = kuromojiAnalysisTests36.failureAndSuccessEvents;
kuromojiAnalysisTests36.setUp();
org.junit.Assert.assertNotSame("tests.nightly", (java.lang.Object) localeArray12, (java.lang.Object) kuromojiAnalysisTests36);
kuromojiAnalysisTests36.setIndexWriterMaxDocs((int) (short) 1);
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.index.analysis.AnalysisService analysisService50 = kuromojiAnalysisTests36.createAnalysisService();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(locale3);
org.junit.Assert.assertEquals(locale3.toString(), "");
org.junit.Assert.assertNotNull(locale5);
org.junit.Assert.assertEquals(locale5.toString(), "");
org.junit.Assert.assertNotNull(locale7);
org.junit.Assert.assertEquals(locale7.toString(), "");
org.junit.Assert.assertNotNull(locale9);
org.junit.Assert.assertEquals(locale9.toString(), "");
org.junit.Assert.assertNotNull(locale11);
org.junit.Assert.assertEquals(locale11.toString(), "");
org.junit.Assert.assertNotNull(localeArray12);
org.junit.Assert.assertNotNull(localeSet13);
org.junit.Assert.assertNotNull(serializableList14);
org.junit.Assert.assertNotNull(cloneableSet15);
org.junit.Assert.assertNotNull(locale20);
org.junit.Assert.assertEquals(locale20.toString(), "");
org.junit.Assert.assertNotNull(locale22);
org.junit.Assert.assertEquals(locale22.toString(), "");
org.junit.Assert.assertNotNull(locale24);
org.junit.Assert.assertEquals(locale24.toString(), "");
org.junit.Assert.assertNotNull(locale26);
org.junit.Assert.assertEquals(locale26.toString(), "");
org.junit.Assert.assertNotNull(locale28);
org.junit.Assert.assertEquals(locale28.toString(), "");
org.junit.Assert.assertNotNull(localeArray29);
org.junit.Assert.assertNotNull(localeSet30);
org.junit.Assert.assertNotNull(serializableList31);
org.junit.Assert.assertNotNull(cloneableSet32);
org.junit.Assert.assertNotNull(ruleChain45);
}
@Test
public void test02398() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02398");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("random", indexReader2, fields3, fields4, true);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.IndexReader indexReader9 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertNormsEquals("tests.maxfailures", indexReader8, indexReader9);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02399() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02399");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.PostingsEnum postingsEnum3 = null;
org.apache.lucene.index.PostingsEnum postingsEnum4 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("", postingsEnum3, postingsEnum4, false);
org.junit.rules.TestRule testRule7 = kuromojiAnalysisTests1.ruleChain;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests8 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.Fields fields11 = null;
org.apache.lucene.index.Fields fields12 = null;
kuromojiAnalysisTests8.assertFieldsEquals("europarl.lines.txt.gz", indexReader10, fields11, fields12, false);
kuromojiAnalysisTests8.ensureCleanedUp();
kuromojiAnalysisTests8.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests8.tearDown();
org.junit.Assert.assertNotEquals("europarl.lines.txt.gz", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests8);
kuromojiAnalysisTests8.tearDown();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.Terms terms23 = null;
org.apache.lucene.index.Terms terms24 = null;
kuromojiAnalysisTests8.assertTermsEquals("enwiki.random.lines.txt", indexReader22, terms23, terms24, false);
kuromojiAnalysisTests8.restoreIndexWriterMaxDocs();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests8.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule7);
}
@Test
public void test02400() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02400");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests13.assertFieldsEquals("europarl.lines.txt.gz", indexReader15, fields16, fields17, false);
kuromojiAnalysisTests13.ensureCleanedUp();
kuromojiAnalysisTests13.resetCheckIndexStatus();
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
kuromojiAnalysisTests13.assertPositionsSkippingEquals("", indexReader24, (int) (byte) 0, postingsEnum26, postingsEnum27);
org.junit.Assert.assertNotEquals((java.lang.Object) "tests.failfast", (java.lang.Object) kuromojiAnalysisTests13);
kuromojiAnalysisTests13.setUp();
kuromojiAnalysisTests13.overrideTestDefaultQueryCache();
kuromojiAnalysisTests13.assertPathHasBeenCleared("random");
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests13.testReadingFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
}
@Test
public void test02401() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02401");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.failfast");
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.slow", indexReader11, (int) (short) 10, postingsEnum13, postingsEnum14);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testReadingFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02402() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02402");
java.util.Locale locale3 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale5 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale7 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale9 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale11 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray12 = new java.util.Locale[] { locale3, locale5, locale7, locale9, locale11 };
java.util.Set<java.util.Locale> localeSet13 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray12);
java.util.List<java.io.Serializable> serializableList14 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray12);
java.util.Set<java.lang.Cloneable> cloneableSet15 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray12);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray12, (java.lang.Object) (byte) -1);
java.util.Locale locale20 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale22 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale24 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale26 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale28 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray29 = new java.util.Locale[] { locale20, locale22, locale24, locale26, locale28 };
java.util.Set<java.util.Locale> localeSet30 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray29);
java.util.List<java.io.Serializable> serializableList31 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray29);
java.util.Set<java.lang.Cloneable> cloneableSet32 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray29);
org.junit.Assert.assertNotEquals((java.lang.Object) localeArray29, (java.lang.Object) (byte) -1);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray12, (java.lang.Object[]) localeArray29);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests36 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader38 = null;
org.apache.lucene.index.Fields fields39 = null;
org.apache.lucene.index.Fields fields40 = null;
kuromojiAnalysisTests36.assertFieldsEquals("europarl.lines.txt.gz", indexReader38, fields39, fields40, false);
kuromojiAnalysisTests36.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain45 = kuromojiAnalysisTests36.failureAndSuccessEvents;
kuromojiAnalysisTests36.setUp();
org.junit.Assert.assertNotSame("tests.nightly", (java.lang.Object) localeArray12, (java.lang.Object) kuromojiAnalysisTests36);
kuromojiAnalysisTests36.setIndexWriterMaxDocs((int) (short) 1);
java.lang.String str50 = kuromojiAnalysisTests36.getTestName();
org.apache.lucene.index.IndexReader indexReader52 = null;
org.apache.lucene.index.IndexReader indexReader53 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests36.assertDeletedDocsEquals("tests.badapples", indexReader52, indexReader53);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(locale3);
org.junit.Assert.assertEquals(locale3.toString(), "");
org.junit.Assert.assertNotNull(locale5);
org.junit.Assert.assertEquals(locale5.toString(), "");
org.junit.Assert.assertNotNull(locale7);
org.junit.Assert.assertEquals(locale7.toString(), "");
org.junit.Assert.assertNotNull(locale9);
org.junit.Assert.assertEquals(locale9.toString(), "");
org.junit.Assert.assertNotNull(locale11);
org.junit.Assert.assertEquals(locale11.toString(), "");
org.junit.Assert.assertNotNull(localeArray12);
org.junit.Assert.assertNotNull(localeSet13);
org.junit.Assert.assertNotNull(serializableList14);
org.junit.Assert.assertNotNull(cloneableSet15);
org.junit.Assert.assertNotNull(locale20);
org.junit.Assert.assertEquals(locale20.toString(), "");
org.junit.Assert.assertNotNull(locale22);
org.junit.Assert.assertEquals(locale22.toString(), "");
org.junit.Assert.assertNotNull(locale24);
org.junit.Assert.assertEquals(locale24.toString(), "");
org.junit.Assert.assertNotNull(locale26);
org.junit.Assert.assertEquals(locale26.toString(), "");
org.junit.Assert.assertNotNull(locale28);
org.junit.Assert.assertEquals(locale28.toString(), "");
org.junit.Assert.assertNotNull(localeArray29);
org.junit.Assert.assertNotNull(localeSet30);
org.junit.Assert.assertNotNull(serializableList31);
org.junit.Assert.assertNotNull(cloneableSet32);
org.junit.Assert.assertNotNull(ruleChain45);
org.junit.Assert.assertEquals("'" + str50 + "' != '" + "<unknown>" + "'", str50, "<unknown>");
}
@Test
public void test02403() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02403");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.TestRule testRule9 = kuromojiAnalysisTests0.ruleChain;
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.TermsEnum termsEnum13 = null;
org.apache.lucene.index.TermsEnum termsEnum14 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("hi!", indexReader12, termsEnum13, termsEnum14, true);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule9);
}
@Test
public void test02404() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02404");
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray3 = org.elasticsearch.test.ESTestCase.generateRandomStringArray((int) (byte) 0, (int) (byte) 10, true);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02405() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02405");
int[] intArray4 = new int[] { '#' };
int[] intArray6 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray4, intArray6);
int[] intArray9 = new int[] { '#' };
int[] intArray11 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray9, intArray11);
org.junit.Assert.assertArrayEquals("tests.nightly", intArray4, intArray9);
int[] intArray15 = new int[] { '#' };
int[] intArray17 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray15, intArray17);
org.junit.Assert.assertArrayEquals(intArray9, intArray15);
int[] intArray22 = new int[] { '#' };
int[] intArray24 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray22, intArray24);
int[] intArray27 = new int[] { '#' };
int[] intArray29 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray27, intArray29);
org.junit.Assert.assertArrayEquals("tests.nightly", intArray22, intArray27);
org.junit.Assert.assertArrayEquals("tests.nightly", intArray9, intArray27);
int[] intArray37 = new int[] { '#' };
int[] intArray39 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray37, intArray39);
int[] intArray42 = new int[] { '#' };
int[] intArray44 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray42, intArray44);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray37, intArray42);
int[] intArray49 = new int[] { '#' };
int[] intArray51 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray49, intArray51);
int[] intArray54 = new int[] { '#' };
int[] intArray56 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray54, intArray56);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray49, intArray54);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", intArray37, intArray54);
int[] intArray63 = new int[] { '#' };
int[] intArray65 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray63, intArray65);
int[] intArray68 = new int[] { '#' };
int[] intArray70 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray68, intArray70);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray63, intArray68);
int[] intArray75 = new int[] { '#' };
int[] intArray77 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray75, intArray77);
int[] intArray80 = new int[] { '#' };
int[] intArray82 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray80, intArray82);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray75, intArray80);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", intArray63, intArray80);
org.junit.Assert.assertArrayEquals("random", intArray54, intArray63);
org.junit.Assert.assertArrayEquals("tests.awaitsfix", intArray27, intArray63);
org.junit.Assert.assertNotNull(intArray4);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray4), "[35]");
org.junit.Assert.assertNotNull(intArray6);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray6), "[35]");
org.junit.Assert.assertNotNull(intArray9);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray9), "[35]");
org.junit.Assert.assertNotNull(intArray11);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray11), "[35]");
org.junit.Assert.assertNotNull(intArray15);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray15), "[35]");
org.junit.Assert.assertNotNull(intArray17);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray17), "[35]");
org.junit.Assert.assertNotNull(intArray22);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray22), "[35]");
org.junit.Assert.assertNotNull(intArray24);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray24), "[35]");
org.junit.Assert.assertNotNull(intArray27);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray27), "[35]");
org.junit.Assert.assertNotNull(intArray29);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray29), "[35]");
org.junit.Assert.assertNotNull(intArray37);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray37), "[35]");
org.junit.Assert.assertNotNull(intArray39);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray39), "[35]");
org.junit.Assert.assertNotNull(intArray42);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray42), "[35]");
org.junit.Assert.assertNotNull(intArray44);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray44), "[35]");
org.junit.Assert.assertNotNull(intArray49);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray49), "[35]");
org.junit.Assert.assertNotNull(intArray51);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray51), "[35]");
org.junit.Assert.assertNotNull(intArray54);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray54), "[35]");
org.junit.Assert.assertNotNull(intArray56);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray56), "[35]");
org.junit.Assert.assertNotNull(intArray63);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray63), "[35]");
org.junit.Assert.assertNotNull(intArray65);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray65), "[35]");
org.junit.Assert.assertNotNull(intArray68);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray68), "[35]");
org.junit.Assert.assertNotNull(intArray70);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray70), "[35]");
org.junit.Assert.assertNotNull(intArray75);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray75), "[35]");
org.junit.Assert.assertNotNull(intArray77);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray77), "[35]");
org.junit.Assert.assertNotNull(intArray80);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray80), "[35]");
org.junit.Assert.assertNotNull(intArray82);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray82), "[35]");
}
@Test
public void test02406() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02406");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.failfast");
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.IndexReader indexReader12 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderEquals("tests.awaitsfix", indexReader11, indexReader12);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02407() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02407");
org.junit.Assert.assertNotEquals((-1L), 0L);
}
@Test
public void test02408() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02408");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) "tests.awaitsfix");
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests14 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Fields fields17 = null;
org.apache.lucene.index.Fields fields18 = null;
kuromojiAnalysisTests14.assertFieldsEquals("europarl.lines.txt.gz", indexReader16, fields17, fields18, false);
kuromojiAnalysisTests14.ensureCleanedUp();
kuromojiAnalysisTests14.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests14.tearDown();
kuromojiAnalysisTests14.ensureAllSearchContextsReleased();
kuromojiAnalysisTests14.ensureCleanedUp();
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests14);
java.io.Reader reader28 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertCharFilterEquals(reader28, "tests.slow");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02409() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02409");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("hi!", indexReader9, (int) (byte) 0, postingsEnum11, postingsEnum12);
kuromojiAnalysisTests1.ensureCheckIndexPassed();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests15 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.junit.Assert.assertNotSame("tests.slow", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests15);
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.IndexReader indexReader19 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests15.assertNormsEquals("tests.awaitsfix", indexReader18, indexReader19);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02410() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02410");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
kuromojiAnalysisTests0.setIndexWriterMaxDocs(0);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.Fields fields20 = null;
org.apache.lucene.index.Fields fields21 = null;
kuromojiAnalysisTests0.assertFieldsEquals("enwiki.random.lines.txt", indexReader19, fields20, fields21, false);
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.Terms terms26 = null;
org.apache.lucene.index.Terms terms27 = null;
kuromojiAnalysisTests0.assertTermsEquals("tests.failfast", indexReader25, terms26, terms27, false);
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader32 = null;
org.apache.lucene.index.IndexReader indexReader33 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderEquals("tests.awaitsfix", indexReader32, indexReader33);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02411() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02411");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.setUp();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("", indexReader17, (int) '#', postingsEnum19, postingsEnum20);
org.junit.rules.RuleChain ruleChain22 = kuromojiAnalysisTests1.failureAndSuccessEvents;
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.index.analysis.AnalysisService analysisService23 = kuromojiAnalysisTests1.createAnalysisService();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
org.junit.Assert.assertNotNull(ruleChain22);
}
@Test
public void test02412() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02412");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path1 = org.apache.lucene.util.LuceneTestCase.createTempDir("tests.nightly");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02413() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02413");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.iterations(0, (int) (short) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalArgumentException; message: max must be >= min: 0, -1");
} catch (java.lang.IllegalArgumentException e) {
// Expected exception.
}
}
@Test
public void test02414() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02414");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testJapaneseStopFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02415() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02415");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.between((int) (short) 100, (int) (short) 100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02416() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02416");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests12 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Fields fields15 = null;
org.apache.lucene.index.Fields fields16 = null;
kuromojiAnalysisTests12.assertFieldsEquals("europarl.lines.txt.gz", indexReader14, fields15, fields16, false);
kuromojiAnalysisTests12.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain21 = kuromojiAnalysisTests12.failureAndSuccessEvents;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain21;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain21;
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain21;
org.apache.lucene.util.LuceneTestCase.classRules = ruleChain21;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests27 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.Fields fields30 = null;
org.apache.lucene.index.Fields fields31 = null;
kuromojiAnalysisTests27.assertFieldsEquals("europarl.lines.txt.gz", indexReader29, fields30, fields31, false);
kuromojiAnalysisTests27.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain36 = kuromojiAnalysisTests27.failureAndSuccessEvents;
kuromojiAnalysisTests27.resetCheckIndexStatus();
java.lang.String str38 = kuromojiAnalysisTests27.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests27);
kuromojiAnalysisTests27.tearDown();
kuromojiAnalysisTests27.overrideTestDefaultQueryCache();
org.junit.rules.RuleChain ruleChain42 = kuromojiAnalysisTests27.failureAndSuccessEvents;
kuromojiAnalysisTests27.tearDown();
kuromojiAnalysisTests27.overrideTestDefaultQueryCache();
org.junit.Assert.assertNotEquals((java.lang.Object) ruleChain21, (java.lang.Object) kuromojiAnalysisTests27);
org.apache.lucene.index.IndexReader indexReader47 = null;
org.apache.lucene.index.IndexReader indexReader48 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests27.assertDocValuesEquals("tests.monster", indexReader47, indexReader48);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain21);
org.junit.Assert.assertNotNull(ruleChain36);
org.junit.Assert.assertEquals("'" + str38 + "' != '" + "<unknown>" + "'", str38, "<unknown>");
org.junit.Assert.assertNotNull(ruleChain42);
}
@Test
public void test02417() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02417");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newTextField("tests.weekly", "hi!", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02418() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02418");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
kuromojiAnalysisTests1.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testKuromojiUserDict();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02419() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02419");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfCodepointLengthBetween((int) (short) -1, (int) (byte) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02420() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02420");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("hi!", indexReader9, (int) (byte) 0, postingsEnum11, postingsEnum12);
kuromojiAnalysisTests1.ensureCheckIndexPassed();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests15 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.junit.Assert.assertNotSame("tests.slow", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests15);
kuromojiAnalysisTests15.ensureAllSearchContextsReleased();
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.IndexReader indexReader20 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests15.assertStoredFieldsEquals("tests.failfast", indexReader19, indexReader20);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02421() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02421");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfCodepointLengthBetween((int) 'a', 0);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02422() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02422");
int[] intArray3 = new int[] { '#' };
int[] intArray5 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray3, intArray5);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests7 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.Fields fields10 = null;
org.apache.lucene.index.Fields fields11 = null;
kuromojiAnalysisTests7.assertFieldsEquals("europarl.lines.txt.gz", indexReader9, fields10, fields11, false);
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum18 = null;
kuromojiAnalysisTests7.assertPositionsSkippingEquals("hi!", indexReader15, (int) (byte) 0, postingsEnum17, postingsEnum18);
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.Terms terms22 = null;
org.apache.lucene.index.Terms terms23 = null;
kuromojiAnalysisTests7.assertTermsEquals("random", indexReader21, terms22, terms23, true);
kuromojiAnalysisTests7.setUp();
kuromojiAnalysisTests7.tearDown();
kuromojiAnalysisTests7.tearDown();
org.junit.rules.RuleChain ruleChain29 = kuromojiAnalysisTests7.failureAndSuccessEvents;
org.junit.Assert.assertNotSame("tests.weekly", (java.lang.Object) intArray5, (java.lang.Object) kuromojiAnalysisTests7);
int[] intArray35 = new int[] { '#' };
int[] intArray37 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray35, intArray37);
int[] intArray40 = new int[] { '#' };
int[] intArray42 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray40, intArray42);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray35, intArray40);
int[] intArray47 = new int[] { '#' };
int[] intArray49 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray47, intArray49);
int[] intArray52 = new int[] { '#' };
int[] intArray54 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray52, intArray54);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray47, intArray52);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", intArray35, intArray52);
int[] intArray62 = new int[] { '#' };
int[] intArray64 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray62, intArray64);
int[] intArray67 = new int[] { '#' };
int[] intArray69 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray67, intArray69);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray62, intArray67);
int[] intArray74 = new int[] { '#' };
int[] intArray76 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray74, intArray76);
int[] intArray79 = new int[] { '#' };
int[] intArray81 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray79, intArray81);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray74, intArray79);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", intArray62, intArray79);
int[] intArray87 = new int[] { '#' };
int[] intArray89 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray87, intArray89);
int[] intArray92 = new int[] { '#' };
int[] intArray94 = new int[] { '#' };
org.junit.Assert.assertArrayEquals(intArray92, intArray94);
org.junit.Assert.assertArrayEquals("tests.badapples", intArray87, intArray92);
org.junit.Assert.assertArrayEquals("", intArray79, intArray92);
org.junit.Assert.assertArrayEquals("tests.awaitsfix", intArray52, intArray79);
org.junit.Assert.assertArrayEquals("hi!", intArray5, intArray52);
org.junit.Assert.assertNotNull(intArray3);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray3), "[35]");
org.junit.Assert.assertNotNull(intArray5);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray5), "[35]");
org.junit.Assert.assertNotNull(ruleChain29);
org.junit.Assert.assertNotNull(intArray35);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray35), "[35]");
org.junit.Assert.assertNotNull(intArray37);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray37), "[35]");
org.junit.Assert.assertNotNull(intArray40);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray40), "[35]");
org.junit.Assert.assertNotNull(intArray42);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray42), "[35]");
org.junit.Assert.assertNotNull(intArray47);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray47), "[35]");
org.junit.Assert.assertNotNull(intArray49);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray49), "[35]");
org.junit.Assert.assertNotNull(intArray52);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray52), "[35]");
org.junit.Assert.assertNotNull(intArray54);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray54), "[35]");
org.junit.Assert.assertNotNull(intArray62);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray62), "[35]");
org.junit.Assert.assertNotNull(intArray64);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray64), "[35]");
org.junit.Assert.assertNotNull(intArray67);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray67), "[35]");
org.junit.Assert.assertNotNull(intArray69);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray69), "[35]");
org.junit.Assert.assertNotNull(intArray74);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray74), "[35]");
org.junit.Assert.assertNotNull(intArray76);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray76), "[35]");
org.junit.Assert.assertNotNull(intArray79);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray79), "[35]");
org.junit.Assert.assertNotNull(intArray81);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray81), "[35]");
org.junit.Assert.assertNotNull(intArray87);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray87), "[35]");
org.junit.Assert.assertNotNull(intArray89);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray89), "[35]");
org.junit.Assert.assertNotNull(intArray92);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray92), "[35]");
org.junit.Assert.assertNotNull(intArray94);
org.junit.Assert.assertEquals(java.util.Arrays.toString(intArray94), "[35]");
}
@Test
public void test02423() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02423");
java.util.Random random0 = null;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
kuromojiAnalysisTests2.assertPositionsSkippingEquals("hi!", indexReader10, (int) (byte) 0, postingsEnum12, postingsEnum13);
org.apache.lucene.index.IndexReader indexReader16 = null;
org.apache.lucene.index.Terms terms17 = null;
org.apache.lucene.index.Terms terms18 = null;
kuromojiAnalysisTests2.assertTermsEquals("random", indexReader16, terms17, terms18, true);
kuromojiAnalysisTests2.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
kuromojiAnalysisTests2.assertDocsEnumEquals("tests.nightly", postingsEnum23, postingsEnum24, true);
kuromojiAnalysisTests2.tearDown();
java.lang.Object obj28 = null;
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests2, obj28);
kuromojiAnalysisTests2.setIndexWriterMaxDocs((int) (byte) 10);
org.apache.lucene.document.FieldType fieldType32 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field33 = org.apache.lucene.util.LuceneTestCase.newField(random0, "hi!", (java.lang.Object) kuromojiAnalysisTests2, fieldType32);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02424() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02424");
org.junit.Assert.assertNotEquals((double) 1, (double) (short) -1, (double) (byte) -1);
}
@Test
public void test02425() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02425");
org.junit.Assert.assertNotEquals("", (long) (short) -1, (long) (short) 1);
}
@Test
public void test02426() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02426");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (byte) 10);
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Terms terms5 = null;
org.apache.lucene.index.Terms terms6 = null;
kuromojiAnalysisTests0.assertTermsEquals("tests.weekly", indexReader4, terms5, terms6, true);
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) '#');
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02427() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02427");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "tests.monster", "tests.failfast", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02428() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02428");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
org.apache.lucene.index.PostingsEnum postingsEnum17 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("europarl.lines.txt.gz", postingsEnum16, postingsEnum17, false);
kuromojiAnalysisTests1.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.IndexReader indexReader23 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertTermVectorsEquals("tests.weekly", indexReader22, indexReader23);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02429() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02429");
java.util.Random random0 = null;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
java.lang.String[] strArray16 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet17 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray16);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests18 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests18.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet17, (java.lang.Object) kuromojiAnalysisTests18);
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
org.apache.lucene.index.PostingsEnum postingsEnum24 = null;
kuromojiAnalysisTests18.assertDocsEnumEquals("tests.badapples", postingsEnum23, postingsEnum24, true);
org.junit.rules.TestRule testRule27 = kuromojiAnalysisTests18.ruleChain;
org.apache.lucene.index.IndexReader indexReader29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum31 = null;
org.apache.lucene.index.PostingsEnum postingsEnum32 = null;
kuromojiAnalysisTests18.assertDocsSkippingEquals("tests.maxfailures", indexReader29, (int) (byte) 100, postingsEnum31, postingsEnum32, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests35 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader37 = null;
org.apache.lucene.index.Fields fields38 = null;
org.apache.lucene.index.Fields fields39 = null;
kuromojiAnalysisTests35.assertFieldsEquals("europarl.lines.txt.gz", indexReader37, fields38, fields39, false);
kuromojiAnalysisTests35.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain44 = kuromojiAnalysisTests35.failureAndSuccessEvents;
kuromojiAnalysisTests18.failureAndSuccessEvents = ruleChain44;
kuromojiAnalysisTests2.failureAndSuccessEvents = ruleChain44;
kuromojiAnalysisTests2.assertPathHasBeenCleared("<unknown>");
org.apache.lucene.document.FieldType fieldType49 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field50 = org.apache.lucene.util.LuceneTestCase.newField(random0, "random", (java.lang.Object) kuromojiAnalysisTests2, fieldType49);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray16);
org.junit.Assert.assertNotNull(strComparableSet17);
org.junit.Assert.assertNotNull(testRule27);
org.junit.Assert.assertNotNull(ruleChain44);
}
@Test
public void test02430() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02430");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.between((int) (short) 10, 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02431() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02431");
org.apache.lucene.document.FieldType fieldType2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newField("tests.badapples", "tests.nightly", fieldType2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02432() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02432");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests13.assertFieldsEquals("europarl.lines.txt.gz", indexReader15, fields16, fields17, false);
kuromojiAnalysisTests13.ensureCleanedUp();
kuromojiAnalysisTests13.resetCheckIndexStatus();
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
kuromojiAnalysisTests13.assertPositionsSkippingEquals("", indexReader24, (int) (byte) 0, postingsEnum26, postingsEnum27);
org.junit.Assert.assertNotEquals((java.lang.Object) "tests.failfast", (java.lang.Object) kuromojiAnalysisTests13);
kuromojiAnalysisTests13.setUp();
kuromojiAnalysisTests13.overrideTestDefaultQueryCache();
kuromojiAnalysisTests13.assertPathHasBeenCleared("random");
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader36 = null;
org.apache.lucene.index.IndexReader indexReader37 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests13.assertFieldInfosEquals("tests.badapples", indexReader36, indexReader37);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
}
@Test
public void test02433() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02433");
java.text.Collator collator0 = null;
// The following exception was thrown during execution in test generation
try {
int int3 = org.apache.lucene.util.LuceneTestCase.collate(collator0, "tests.maxfailures", "");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02434() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02434");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween((int) (short) 1, (int) (short) 0);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02435() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02435");
org.junit.Assert.assertNotEquals((double) '#', (double) 100.0f, (double) (byte) 0);
}
@Test
public void test02436() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02436");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) "tests.awaitsfix");
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCheckIndexPassed();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.IndexReader indexReader16 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertDocValuesEquals("enwiki.random.lines.txt", indexReader15, indexReader16);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02437() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02437");
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray3 = org.elasticsearch.test.ESTestCase.generateRandomStringArray((int) (short) 1, (int) ' ', false);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02438() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02438");
java.util.Random random0 = null;
// The following exception was thrown during execution in test generation
try {
int int2 = org.apache.lucene.util.LuceneTestCase.atLeast(random0, (int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02439() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02439");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "enwiki.random.lines.txt", "", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02440() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02440");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("random", indexReader2, fields3, fields4, true);
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.TermsEnum termsEnum10 = null;
org.apache.lucene.index.TermsEnum termsEnum11 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("", indexReader9, termsEnum10, termsEnum11, false);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02441() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02441");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "<unknown>", "europarl.lines.txt.gz", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02442() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02442");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.IndexableField indexableField12 = null;
org.apache.lucene.index.IndexableField indexableField13 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertStoredFieldEquals("tests.awaitsfix", indexableField12, indexableField13);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02443() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02443");
org.apache.lucene.document.FieldType fieldType2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newField("tests.failfast", "tests.nightly", fieldType2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02444() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02444");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomAsciiOfLengthBetween((int) (byte) 1, (int) '#');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02445() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02445");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("", indexReader11, (int) (byte) 0, postingsEnum13, postingsEnum14);
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("<unknown>", indexReader18, (int) ' ', postingsEnum20, postingsEnum21, false);
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.TermsEnum termsEnum26 = null;
org.apache.lucene.index.TermsEnum termsEnum27 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermStatsEquals("", termsEnum26, termsEnum27);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02446() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02446");
// The following exception was thrown during execution in test generation
try {
java.lang.String str1 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfLength((int) (short) 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02447() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02447");
int[][] intArray1 = new int[][] {};
java.util.Set<int[]> intArraySet2 = org.apache.lucene.util.LuceneTestCase.asSet(intArray1);
java.io.PrintStream printStream3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.util.LuceneTestCase.dumpArray("europarl.lines.txt.gz", (java.lang.Object[]) intArray1, printStream3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(intArray1);
org.junit.Assert.assertNotNull(intArraySet2);
}
@Test
public void test02448() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02448");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.setUp();
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("", indexReader17, (int) '#', postingsEnum19, postingsEnum20);
org.junit.rules.RuleChain ruleChain22 = kuromojiAnalysisTests1.failureAndSuccessEvents;
org.apache.lucene.index.Terms terms24 = null;
org.apache.lucene.index.Terms terms25 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertTermsStatisticsEquals("<unknown>", terms24, terms25);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
org.junit.Assert.assertNotNull(ruleChain22);
}
@Test
public void test02449() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02449");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testIterationMarkCharFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02450() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02450");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.ensureCleanedUp();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.Fields fields12 = null;
org.apache.lucene.index.Fields fields13 = null;
kuromojiAnalysisTests9.assertFieldsEquals("europarl.lines.txt.gz", indexReader11, fields12, fields13, false);
org.apache.lucene.index.IndexReader indexReader17 = null;
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests9.assertPositionsSkippingEquals("tests.failfast", indexReader17, 1, postingsEnum19, postingsEnum20);
kuromojiAnalysisTests9.setIndexWriterMaxDocs(0);
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.Fields fields26 = null;
org.apache.lucene.index.Fields fields27 = null;
kuromojiAnalysisTests9.assertFieldsEquals("tests.slow", indexReader25, fields26, fields27, false);
kuromojiAnalysisTests9.resetCheckIndexStatus();
org.junit.rules.TestRule testRule31 = kuromojiAnalysisTests9.ruleChain;
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) testRule31);
org.apache.lucene.index.IndexReader indexReader34 = null;
org.apache.lucene.index.PostingsEnum postingsEnum36 = null;
org.apache.lucene.index.PostingsEnum postingsEnum37 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.weekly", indexReader34, 0, postingsEnum36, postingsEnum37, false);
org.apache.lucene.index.IndexReader indexReader41 = null;
org.apache.lucene.index.IndexReader indexReader42 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermVectorsEquals("tests.nightly", indexReader41, indexReader42);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule31);
}
@Test
public void test02451() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02451");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.TestRule testRule9 = kuromojiAnalysisTests0.ruleChain;
org.junit.rules.TestRule testRule10 = kuromojiAnalysisTests0.ruleChain;
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.slow", indexReader12, (int) (short) 1, postingsEnum14, postingsEnum15);
org.junit.rules.TestRule testRule17 = kuromojiAnalysisTests0.ruleChain;
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.Terms terms20 = null;
org.apache.lucene.index.Terms terms21 = null;
kuromojiAnalysisTests0.assertTermsEquals("", indexReader19, terms20, terms21, false);
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.Fields fields26 = null;
org.apache.lucene.index.Fields fields27 = null;
kuromojiAnalysisTests0.assertFieldsEquals("enwiki.random.lines.txt", indexReader25, fields26, fields27, false);
org.apache.lucene.index.IndexReader indexReader31 = null;
org.apache.lucene.index.IndexReader indexReader32 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderStatisticsEquals("tests.badapples", indexReader31, indexReader32);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule9);
org.junit.Assert.assertNotNull(testRule10);
org.junit.Assert.assertNotNull(testRule17);
}
@Test
public void test02452() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02452");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (byte) 10);
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Terms terms5 = null;
org.apache.lucene.index.Terms terms6 = null;
kuromojiAnalysisTests0.assertTermsEquals("tests.weekly", indexReader4, terms5, terms6, true);
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) '#');
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.tearDown();
org.junit.rules.TestRule testRule13 = kuromojiAnalysisTests0.ruleChain;
java.lang.Object obj14 = null;
org.junit.Assert.assertNotEquals((java.lang.Object) testRule13, obj14);
org.junit.Assert.assertNotNull(testRule13);
}
@Test
public void test02453() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02453");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.setUp();
// The following exception was thrown during execution in test generation
try {
java.lang.String[] strArray16 = kuromojiAnalysisTests1.tmpPaths();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02454() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02454");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Fields fields15 = null;
org.apache.lucene.index.Fields fields16 = null;
kuromojiAnalysisTests0.assertFieldsEquals("tests.slow", indexReader14, fields15, fields16, true);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.testReadingFormFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02455() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02455");
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.index.MergePolicy mergePolicy2 = org.apache.lucene.util.LuceneTestCase.newLogMergePolicy(false, (int) (byte) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02456() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02456");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newTextField(random0, "tests.badapples", "<unknown>", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02457() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02457");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path2 = org.apache.lucene.util.LuceneTestCase.createTempFile("", "tests.awaitsfix");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02458() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02458");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfCodepointLengthBetween(10, (int) '4');
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02459() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02459");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((-1));
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) 'a');
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests24 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader26 = null;
org.apache.lucene.index.Fields fields27 = null;
org.apache.lucene.index.Fields fields28 = null;
kuromojiAnalysisTests24.assertFieldsEquals("europarl.lines.txt.gz", indexReader26, fields27, fields28, false);
java.lang.String[] strArray38 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet39 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray38);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests40 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests40.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet39, (java.lang.Object) kuromojiAnalysisTests40);
org.apache.lucene.index.PostingsEnum postingsEnum45 = null;
org.apache.lucene.index.PostingsEnum postingsEnum46 = null;
kuromojiAnalysisTests40.assertDocsEnumEquals("tests.badapples", postingsEnum45, postingsEnum46, true);
org.junit.rules.TestRule testRule49 = kuromojiAnalysisTests40.ruleChain;
org.apache.lucene.index.IndexReader indexReader51 = null;
org.apache.lucene.index.PostingsEnum postingsEnum53 = null;
org.apache.lucene.index.PostingsEnum postingsEnum54 = null;
kuromojiAnalysisTests40.assertDocsSkippingEquals("tests.maxfailures", indexReader51, (int) (byte) 100, postingsEnum53, postingsEnum54, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests57 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader59 = null;
org.apache.lucene.index.Fields fields60 = null;
org.apache.lucene.index.Fields fields61 = null;
kuromojiAnalysisTests57.assertFieldsEquals("europarl.lines.txt.gz", indexReader59, fields60, fields61, false);
kuromojiAnalysisTests57.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain66 = kuromojiAnalysisTests57.failureAndSuccessEvents;
kuromojiAnalysisTests40.failureAndSuccessEvents = ruleChain66;
kuromojiAnalysisTests24.failureAndSuccessEvents = ruleChain66;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests69 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader71 = null;
org.apache.lucene.index.Fields fields72 = null;
org.apache.lucene.index.Fields fields73 = null;
kuromojiAnalysisTests69.assertFieldsEquals("europarl.lines.txt.gz", indexReader71, fields72, fields73, false);
org.apache.lucene.index.IndexReader indexReader77 = null;
org.apache.lucene.index.PostingsEnum postingsEnum79 = null;
org.apache.lucene.index.PostingsEnum postingsEnum80 = null;
kuromojiAnalysisTests69.assertPositionsSkippingEquals("hi!", indexReader77, (int) (byte) 0, postingsEnum79, postingsEnum80);
kuromojiAnalysisTests69.restoreIndexWriterMaxDocs();
org.junit.Assert.assertNotEquals((java.lang.Object) ruleChain66, (java.lang.Object) kuromojiAnalysisTests69);
kuromojiAnalysisTests0.failureAndSuccessEvents = ruleChain66;
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.TermsEnum termsEnum87 = null;
org.apache.lucene.index.TermsEnum termsEnum88 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermStatsEquals("tests.awaitsfix", termsEnum87, termsEnum88);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray38);
org.junit.Assert.assertNotNull(strComparableSet39);
org.junit.Assert.assertNotNull(testRule49);
org.junit.Assert.assertNotNull(ruleChain66);
}
@Test
public void test02460() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02460");
org.junit.Assert.assertNotEquals((long) 1, (long) 0);
}
@Test
public void test02461() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02461");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("tests.nightly", postingsEnum21, postingsEnum22, true);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests25 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.Fields fields28 = null;
org.apache.lucene.index.Fields fields29 = null;
kuromojiAnalysisTests25.assertFieldsEquals("europarl.lines.txt.gz", indexReader27, fields28, fields29, false);
kuromojiAnalysisTests25.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests25.assertPathHasBeenCleared("tests.slow");
kuromojiAnalysisTests25.ensureCleanedUp();
org.junit.Assert.assertNotEquals((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests25);
java.io.Reader reader38 = null;
// The following exception was thrown during execution in test generation
try {
java.lang.String str39 = kuromojiAnalysisTests25.readFully(reader38);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02462() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02462");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path2 = org.apache.lucene.util.LuceneTestCase.createTempFile("enwiki.random.lines.txt", "tests.badapples");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02463() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02463");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("", indexReader11, (int) (byte) 0, postingsEnum13, postingsEnum14);
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.IndexReader indexReader19 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertReaderEquals("europarl.lines.txt.gz", indexReader18, indexReader19);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02464() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02464");
org.apache.lucene.document.Field.Store store2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newTextField("tests.slow", "random", store2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02465() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02465");
org.junit.Assert.assertEquals((float) '#', 0.0f, (float) 100L);
}
@Test
public void test02466() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02466");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule9 = kuromojiAnalysisTests0.ruleChain;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests10 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.Fields fields13 = null;
org.apache.lucene.index.Fields fields14 = null;
kuromojiAnalysisTests10.assertFieldsEquals("europarl.lines.txt.gz", indexReader12, fields13, fields14, false);
kuromojiAnalysisTests10.ensureCleanedUp();
kuromojiAnalysisTests10.ensureCleanedUp();
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests0, (java.lang.Object) kuromojiAnalysisTests10);
java.nio.file.Path path20 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests10.assertPathHasBeenCleared(path20);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule9);
}
@Test
public void test02467() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02467");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path2 = org.apache.lucene.util.LuceneTestCase.createTempFile("europarl.lines.txt.gz", "tests.nightly");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02468() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02468");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("hi!", indexReader9, (int) (byte) 0, postingsEnum11, postingsEnum12);
kuromojiAnalysisTests1.ensureCheckIndexPassed();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests15 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.junit.Assert.assertNotSame("tests.slow", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests15);
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.IndexReader indexReader19 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertNormsEquals("europarl.lines.txt.gz", indexReader18, indexReader19);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02469() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02469");
org.apache.lucene.document.FieldType fieldType2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newField("tests.slow", "", fieldType2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02470() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02470");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests13.assertFieldsEquals("europarl.lines.txt.gz", indexReader15, fields16, fields17, false);
kuromojiAnalysisTests13.ensureCleanedUp();
kuromojiAnalysisTests13.resetCheckIndexStatus();
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
kuromojiAnalysisTests13.assertPositionsSkippingEquals("", indexReader24, (int) (byte) 0, postingsEnum26, postingsEnum27);
org.junit.Assert.assertNotEquals((java.lang.Object) "tests.failfast", (java.lang.Object) kuromojiAnalysisTests13);
kuromojiAnalysisTests13.setUp();
kuromojiAnalysisTests13.overrideTestDefaultQueryCache();
kuromojiAnalysisTests13.assertPathHasBeenCleared("random");
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader36 = null;
org.apache.lucene.index.PostingsEnum postingsEnum38 = null;
org.apache.lucene.index.PostingsEnum postingsEnum39 = null;
kuromojiAnalysisTests13.assertPositionsSkippingEquals("tests.awaitsfix", indexReader36, (int) (byte) 1, postingsEnum38, postingsEnum39);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests13.testIterationMarkCharFilter();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
}
@Test
public void test02471() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02471");
org.apache.lucene.document.FieldType fieldType2 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field3 = org.apache.lucene.util.LuceneTestCase.newField("tests.weekly", "tests.monster", fieldType2);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02472() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02472");
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path2 = org.apache.lucene.util.LuceneTestCase.createTempFile("tests.maxfailures", "");
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02473() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02473");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str10 = kuromojiAnalysisTests0.getTestName();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.apache.lucene.index.IndexReader indexReader13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum15 = null;
org.apache.lucene.index.PostingsEnum postingsEnum16 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader13, 1, postingsEnum15, postingsEnum16);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests19 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader21 = null;
org.apache.lucene.index.Fields fields22 = null;
org.apache.lucene.index.Fields fields23 = null;
kuromojiAnalysisTests19.assertFieldsEquals("europarl.lines.txt.gz", indexReader21, fields22, fields23, false);
org.apache.lucene.index.IndexReader indexReader27 = null;
org.apache.lucene.index.PostingsEnum postingsEnum29 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
kuromojiAnalysisTests19.assertPositionsSkippingEquals("hi!", indexReader27, (int) (byte) 0, postingsEnum29, postingsEnum30);
kuromojiAnalysisTests19.ensureCheckIndexPassed();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests33 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.junit.Assert.assertNotSame("tests.slow", (java.lang.Object) kuromojiAnalysisTests19, (java.lang.Object) kuromojiAnalysisTests33);
org.junit.Assert.assertNotEquals((java.lang.Object) indexReader13, (java.lang.Object) "tests.slow");
org.junit.Assert.assertEquals("'" + str10 + "' != '" + "<unknown>" + "'", str10, "<unknown>");
}
@Test
public void test02474() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02474");
// The following exception was thrown during execution in test generation
try {
int int2 = org.elasticsearch.test.ESTestCase.randomIntBetween((int) (short) 10, 1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02475() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02475");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) (byte) 10);
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Terms terms5 = null;
org.apache.lucene.index.Terms terms6 = null;
kuromojiAnalysisTests0.assertTermsEquals("tests.weekly", indexReader4, terms5, terms6, true);
kuromojiAnalysisTests0.setIndexWriterMaxDocs((int) '#');
java.lang.String str11 = kuromojiAnalysisTests0.getTestName();
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("tests.weekly", postingsEnum13, postingsEnum14, false);
kuromojiAnalysisTests0.ensureAllSearchContextsReleased();
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.TermsEnum termsEnum20 = null;
org.apache.lucene.index.TermsEnum termsEnum21 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertTermsEnumEquals("tests.monster", indexReader19, termsEnum20, termsEnum21, false);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str11 + "' != '" + "<unknown>" + "'", str11, "<unknown>");
}
@Test
public void test02476() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02476");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.ensureCleanedUp();
java.lang.String str10 = kuromojiAnalysisTests0.getTestName();
kuromojiAnalysisTests0.resetCheckIndexStatus();
org.junit.rules.TestRule testRule12 = kuromojiAnalysisTests0.ruleChain;
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.tearDown();
// The following exception was thrown during execution in test generation
try {
org.elasticsearch.env.NodeEnvironment nodeEnvironment16 = kuromojiAnalysisTests0.newNodeEnvironment();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertEquals("'" + str10 + "' != '" + "<unknown>" + "'", str10, "<unknown>");
org.junit.Assert.assertNotNull(testRule12);
}
@Test
public void test02477() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02477");
java.util.Locale locale5 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale7 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale9 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale11 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale13 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray14 = new java.util.Locale[] { locale5, locale7, locale9, locale11, locale13 };
java.util.Set<java.util.Locale> localeSet15 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray14);
java.util.List<java.io.Serializable> serializableList16 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray14);
org.junit.Assert.assertNotSame("", (java.lang.Object) localeArray14, (java.lang.Object) 0.0f);
java.util.Locale locale22 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale24 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale26 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale28 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale30 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray31 = new java.util.Locale[] { locale22, locale24, locale26, locale28, locale30 };
java.util.Set<java.util.Locale> localeSet32 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray31);
java.util.List<java.io.Serializable> serializableList33 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray31);
org.junit.Assert.assertNotSame("", (java.lang.Object) localeArray31, (java.lang.Object) 0.0f);
org.junit.Assert.assertArrayEquals("europarl.lines.txt.gz", (java.lang.Object[]) localeArray14, (java.lang.Object[]) localeArray31);
java.util.Locale locale39 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale41 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale43 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale45 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale locale47 = org.apache.lucene.util.LuceneTestCase.localeForName("");
java.util.Locale[] localeArray48 = new java.util.Locale[] { locale39, locale41, locale43, locale45, locale47 };
java.util.Set<java.util.Locale> localeSet49 = org.apache.lucene.util.LuceneTestCase.asSet(localeArray48);
java.util.List<java.io.Serializable> serializableList50 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (short) 1, (java.io.Serializable[]) localeArray48);
java.util.Set<java.lang.Cloneable> cloneableSet51 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Cloneable[]) localeArray48);
org.junit.Assert.assertArrayEquals((java.lang.Object[]) localeArray31, (java.lang.Object[]) localeArray48);
java.io.PrintStream printStream53 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.util.LuceneTestCase.dumpArray("hi!", (java.lang.Object[]) localeArray31, printStream53);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(locale5);
org.junit.Assert.assertEquals(locale5.toString(), "");
org.junit.Assert.assertNotNull(locale7);
org.junit.Assert.assertEquals(locale7.toString(), "");
org.junit.Assert.assertNotNull(locale9);
org.junit.Assert.assertEquals(locale9.toString(), "");
org.junit.Assert.assertNotNull(locale11);
org.junit.Assert.assertEquals(locale11.toString(), "");
org.junit.Assert.assertNotNull(locale13);
org.junit.Assert.assertEquals(locale13.toString(), "");
org.junit.Assert.assertNotNull(localeArray14);
org.junit.Assert.assertNotNull(localeSet15);
org.junit.Assert.assertNotNull(serializableList16);
org.junit.Assert.assertNotNull(locale22);
org.junit.Assert.assertEquals(locale22.toString(), "");
org.junit.Assert.assertNotNull(locale24);
org.junit.Assert.assertEquals(locale24.toString(), "");
org.junit.Assert.assertNotNull(locale26);
org.junit.Assert.assertEquals(locale26.toString(), "");
org.junit.Assert.assertNotNull(locale28);
org.junit.Assert.assertEquals(locale28.toString(), "");
org.junit.Assert.assertNotNull(locale30);
org.junit.Assert.assertEquals(locale30.toString(), "");
org.junit.Assert.assertNotNull(localeArray31);
org.junit.Assert.assertNotNull(localeSet32);
org.junit.Assert.assertNotNull(serializableList33);
org.junit.Assert.assertNotNull(locale39);
org.junit.Assert.assertEquals(locale39.toString(), "");
org.junit.Assert.assertNotNull(locale41);
org.junit.Assert.assertEquals(locale41.toString(), "");
org.junit.Assert.assertNotNull(locale43);
org.junit.Assert.assertEquals(locale43.toString(), "");
org.junit.Assert.assertNotNull(locale45);
org.junit.Assert.assertEquals(locale45.toString(), "");
org.junit.Assert.assertNotNull(locale47);
org.junit.Assert.assertEquals(locale47.toString(), "");
org.junit.Assert.assertNotNull(localeArray48);
org.junit.Assert.assertNotNull(localeSet49);
org.junit.Assert.assertNotNull(serializableList50);
org.junit.Assert.assertNotNull(cloneableSet51);
}
@Test
public void test02478() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02478");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
org.apache.lucene.index.PostingsEnum postingsEnum14 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("tests.slow", indexReader11, (int) (short) -1, postingsEnum13, postingsEnum14, false);
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.PostingsEnum postingsEnum19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum20 = null;
kuromojiAnalysisTests0.assertDocsEnumEquals("", postingsEnum19, postingsEnum20, false);
org.junit.rules.RuleChain ruleChain23 = kuromojiAnalysisTests0.failureAndSuccessEvents;
org.apache.lucene.index.IndexableField indexableField25 = null;
org.apache.lucene.index.IndexableField indexableField26 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertStoredFieldEquals("", indexableField25, indexableField26);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain23);
}
@Test
public void test02479() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02479");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.tearDown();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
org.apache.lucene.index.PostingsEnum postingsEnum13 = null;
kuromojiAnalysisTests0.assertDocsSkippingEquals("hi!", indexReader10, 10, postingsEnum12, postingsEnum13, true);
java.nio.file.Path path16 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertPathHasBeenCleared(path16);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02480() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02480");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
org.apache.lucene.index.IndexReader indexReader9 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
org.apache.lucene.index.PostingsEnum postingsEnum12 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("hi!", indexReader9, (int) (byte) 0, postingsEnum11, postingsEnum12);
kuromojiAnalysisTests1.ensureCheckIndexPassed();
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests15 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.junit.Assert.assertNotSame("tests.slow", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests15);
java.io.Reader reader17 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests15.assertCharFilterEquals(reader17, "tests.awaitsfix");
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02481() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02481");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader12 = null;
org.apache.lucene.index.IndexReader indexReader13 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertNormsEquals("tests.badapples", indexReader12, indexReader13);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02482() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02482");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
kuromojiAnalysisTests1.restoreIndexWriterMaxDocs();
org.apache.lucene.index.IndexReader indexReader18 = null;
org.apache.lucene.index.IndexReader indexReader19 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.assertReaderStatisticsEquals("hi!", indexReader18, indexReader19);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02483() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02483");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomRealisticUnicodeOfLengthBetween((int) '#', (-1));
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02484() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02484");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.ensureCleanedUp();
kuromojiAnalysisTests0.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.Terms terms11 = null;
org.apache.lucene.index.Terms terms12 = null;
kuromojiAnalysisTests0.assertTermsEquals("", indexReader10, terms11, terms12, false);
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertFieldStatisticsEquals("tests.badapples", fields16, fields17);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02485() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02485");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween((int) (short) 10, (int) (short) 0);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02486() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02486");
java.lang.String[] strArray7 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet8 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray7);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests9 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests9.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet8, (java.lang.Object) kuromojiAnalysisTests9);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests13 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.Fields fields16 = null;
org.apache.lucene.index.Fields fields17 = null;
kuromojiAnalysisTests13.assertFieldsEquals("europarl.lines.txt.gz", indexReader15, fields16, fields17, false);
kuromojiAnalysisTests13.ensureCleanedUp();
kuromojiAnalysisTests13.resetCheckIndexStatus();
kuromojiAnalysisTests13.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader24 = null;
org.apache.lucene.index.PostingsEnum postingsEnum26 = null;
org.apache.lucene.index.PostingsEnum postingsEnum27 = null;
kuromojiAnalysisTests13.assertPositionsSkippingEquals("", indexReader24, (int) (byte) 0, postingsEnum26, postingsEnum27);
org.junit.Assert.assertNotEquals((java.lang.Object) "tests.failfast", (java.lang.Object) kuromojiAnalysisTests13);
org.apache.lucene.index.IndexReader indexReader31 = null;
org.apache.lucene.index.Fields fields32 = null;
org.apache.lucene.index.Fields fields33 = null;
kuromojiAnalysisTests13.assertFieldsEquals("tests.failfast", indexReader31, fields32, fields33, false);
java.io.Reader reader36 = null;
// The following exception was thrown during execution in test generation
try {
java.lang.String str37 = kuromojiAnalysisTests13.readFully(reader36);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray7);
org.junit.Assert.assertNotNull(strComparableSet8);
}
@Test
public void test02487() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02487");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.PostingsEnum postingsEnum3 = null;
org.apache.lucene.index.PostingsEnum postingsEnum4 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("", postingsEnum3, postingsEnum4, false);
org.junit.rules.TestRule testRule7 = kuromojiAnalysisTests1.ruleChain;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests8 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader10 = null;
org.apache.lucene.index.Fields fields11 = null;
org.apache.lucene.index.Fields fields12 = null;
kuromojiAnalysisTests8.assertFieldsEquals("europarl.lines.txt.gz", indexReader10, fields11, fields12, false);
kuromojiAnalysisTests8.ensureCleanedUp();
kuromojiAnalysisTests8.assertPathHasBeenCleared("tests.failfast");
kuromojiAnalysisTests8.tearDown();
org.junit.Assert.assertNotEquals("europarl.lines.txt.gz", (java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) kuromojiAnalysisTests8);
kuromojiAnalysisTests8.tearDown();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.IndexReader indexReader23 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests8.assertFieldInfosEquals("random", indexReader22, indexReader23);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(testRule7);
}
@Test
public void test02488() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02488");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
java.lang.String[] strArray15 = new java.lang.String[] { "tests.awaitsfix", "europarl.lines.txt.gz", "tests.slow", "tests.maxfailures", "", "hi!" };
java.util.Set<java.lang.Comparable<java.lang.String>> strComparableSet16 = org.apache.lucene.util.LuceneTestCase.asSet((java.lang.Comparable<java.lang.String>[]) strArray15);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests17 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
kuromojiAnalysisTests17.setIndexWriterMaxDocs((int) (byte) 10);
org.junit.Assert.assertNotSame("tests.failfast", (java.lang.Object) strComparableSet16, (java.lang.Object) kuromojiAnalysisTests17);
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
org.apache.lucene.index.PostingsEnum postingsEnum23 = null;
kuromojiAnalysisTests17.assertDocsEnumEquals("tests.badapples", postingsEnum22, postingsEnum23, true);
org.junit.rules.TestRule testRule26 = kuromojiAnalysisTests17.ruleChain;
org.apache.lucene.index.IndexReader indexReader28 = null;
org.apache.lucene.index.PostingsEnum postingsEnum30 = null;
org.apache.lucene.index.PostingsEnum postingsEnum31 = null;
kuromojiAnalysisTests17.assertDocsSkippingEquals("tests.maxfailures", indexReader28, (int) (byte) 100, postingsEnum30, postingsEnum31, false);
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests34 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader36 = null;
org.apache.lucene.index.Fields fields37 = null;
org.apache.lucene.index.Fields fields38 = null;
kuromojiAnalysisTests34.assertFieldsEquals("europarl.lines.txt.gz", indexReader36, fields37, fields38, false);
kuromojiAnalysisTests34.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain43 = kuromojiAnalysisTests34.failureAndSuccessEvents;
kuromojiAnalysisTests17.failureAndSuccessEvents = ruleChain43;
kuromojiAnalysisTests1.failureAndSuccessEvents = ruleChain43;
org.apache.lucene.index.PostingsEnum postingsEnum47 = null;
org.apache.lucene.index.PostingsEnum postingsEnum48 = null;
kuromojiAnalysisTests1.assertDocsEnumEquals("<unknown>", postingsEnum47, postingsEnum48, true);
org.apache.lucene.index.IndexReader indexReader52 = null;
org.apache.lucene.index.Terms terms53 = null;
org.apache.lucene.index.Terms terms54 = null;
kuromojiAnalysisTests1.assertTermsEquals("tests.slow", indexReader52, terms53, terms54, true);
java.lang.Class<?> wildcardClass57 = kuromojiAnalysisTests1.getClass();
org.apache.lucene.store.MockDirectoryWrapper.Throttling throttling60 = org.apache.lucene.util.LuceneTestCase.TEST_THROTTLING;
org.apache.lucene.store.MockDirectoryWrapper.Throttling[] throttlingArray61 = new org.apache.lucene.store.MockDirectoryWrapper.Throttling[] { throttling60 };
java.util.List<org.apache.lucene.store.MockDirectoryWrapper.Throttling> throttlingList62 = org.elasticsearch.test.ESTestCase.randomSubsetOf((int) (byte) 0, throttlingArray61);
org.junit.Assert.assertNotNull("europarl.lines.txt.gz", (java.lang.Object) throttlingArray61);
org.junit.Assert.assertNotSame((java.lang.Object) kuromojiAnalysisTests1, (java.lang.Object) throttlingArray61);
java.io.PrintStream printStream65 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.util.LuceneTestCase.dumpArray("", (java.lang.Object[]) throttlingArray61, printStream65);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(strArray15);
org.junit.Assert.assertNotNull(strComparableSet16);
org.junit.Assert.assertNotNull(testRule26);
org.junit.Assert.assertNotNull(ruleChain43);
org.junit.Assert.assertNotNull(wildcardClass57);
org.junit.Assert.assertTrue("'" + throttling60 + "' != '" + org.apache.lucene.store.MockDirectoryWrapper.Throttling.NEVER + "'", throttling60.equals(org.apache.lucene.store.MockDirectoryWrapper.Throttling.NEVER));
org.junit.Assert.assertNotNull(throttlingArray61);
org.junit.Assert.assertNotNull(throttlingList62);
}
@Test
public void test02489() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02489");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newStringField(random0, "europarl.lines.txt.gz", "<unknown>", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02490() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02490");
// The following exception was thrown during execution in test generation
try {
java.lang.String str2 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLengthBetween((int) (short) 100, (int) (short) -1);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02491() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02491");
org.junit.Assert.assertNotEquals("tests.maxfailures", (-1L), (long) '#');
}
@Test
public void test02492() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02492");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newTextField(random0, "tests.awaitsfix", "<unknown>", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02493() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02493");
java.util.Random random0 = null;
org.apache.lucene.document.Field.Store store3 = null;
// The following exception was thrown during execution in test generation
try {
org.apache.lucene.document.Field field4 = org.apache.lucene.util.LuceneTestCase.newTextField(random0, "tests.weekly", "europarl.lines.txt.gz", store3);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
}
@Test
public void test02494() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02494");
// The following exception was thrown during execution in test generation
try {
java.lang.String str1 = org.elasticsearch.test.ESTestCase.randomUnicodeOfLength(100);
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
}
@Test
public void test02495() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02495");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
kuromojiAnalysisTests1.ensureAllSearchContextsReleased();
org.junit.rules.RuleChain ruleChain17 = null;
kuromojiAnalysisTests1.failureAndSuccessEvents = ruleChain17;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testJapaneseStopFilterFactory();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02496() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02496");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("hi!", indexReader8, (int) (byte) 0, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("random", indexReader14, terms15, terms16, true);
kuromojiAnalysisTests0.setUp();
kuromojiAnalysisTests0.tearDown();
org.apache.lucene.index.IndexReader indexReader22 = null;
org.apache.lucene.index.Fields fields23 = null;
org.apache.lucene.index.Fields fields24 = null;
kuromojiAnalysisTests0.assertFieldsEquals("", indexReader22, fields23, fields24, false);
kuromojiAnalysisTests0.resetCheckIndexStatus();
// The following exception was thrown during execution in test generation
try {
java.nio.file.Path path29 = kuromojiAnalysisTests0.getDataPath("tests.failfast");
org.junit.Assert.fail("Expected exception of type java.lang.RuntimeException; message: resource not found: tests.failfast");
} catch (java.lang.RuntimeException e) {
// Expected exception.
}
}
@Test
public void test02497() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02497");
java.lang.Object obj1 = null;
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests2 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader4 = null;
org.apache.lucene.index.Fields fields5 = null;
org.apache.lucene.index.Fields fields6 = null;
kuromojiAnalysisTests2.assertFieldsEquals("europarl.lines.txt.gz", indexReader4, fields5, fields6, false);
kuromojiAnalysisTests2.ensureCleanedUp();
kuromojiAnalysisTests2.resetCheckIndexStatus();
kuromojiAnalysisTests2.setIndexWriterMaxDocs((int) (byte) 0);
org.junit.Assert.assertNotEquals("tests.awaitsfix", obj1, (java.lang.Object) kuromojiAnalysisTests2);
org.junit.rules.RuleChain ruleChain14 = kuromojiAnalysisTests2.failureAndSuccessEvents;
java.nio.file.Path path15 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests2.assertPathHasBeenCleared(path15);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain14);
}
@Test
public void test02498() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02498");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
org.apache.lucene.index.IndexReader indexReader8 = null;
org.apache.lucene.index.PostingsEnum postingsEnum10 = null;
org.apache.lucene.index.PostingsEnum postingsEnum11 = null;
kuromojiAnalysisTests0.assertPositionsSkippingEquals("tests.failfast", indexReader8, 1, postingsEnum10, postingsEnum11);
org.apache.lucene.index.IndexReader indexReader14 = null;
org.apache.lucene.index.Terms terms15 = null;
org.apache.lucene.index.Terms terms16 = null;
kuromojiAnalysisTests0.assertTermsEquals("europarl.lines.txt.gz", indexReader14, terms15, terms16, false);
org.junit.Assert.assertNull((java.lang.Object) indexReader14);
}
@Test
public void test02499() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02499");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests1 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader3 = null;
org.apache.lucene.index.Fields fields4 = null;
org.apache.lucene.index.Fields fields5 = null;
kuromojiAnalysisTests1.assertFieldsEquals("europarl.lines.txt.gz", indexReader3, fields4, fields5, false);
kuromojiAnalysisTests1.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain10 = kuromojiAnalysisTests1.failureAndSuccessEvents;
kuromojiAnalysisTests1.resetCheckIndexStatus();
java.lang.String str12 = kuromojiAnalysisTests1.getTestName();
org.junit.Assert.assertNotNull("", (java.lang.Object) kuromojiAnalysisTests1);
kuromojiAnalysisTests1.tearDown();
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
kuromojiAnalysisTests1.restoreIndexWriterMaxDocs();
kuromojiAnalysisTests1.overrideTestDefaultQueryCache();
org.apache.lucene.index.IndexReader indexReader19 = null;
org.apache.lucene.index.PostingsEnum postingsEnum21 = null;
org.apache.lucene.index.PostingsEnum postingsEnum22 = null;
kuromojiAnalysisTests1.assertPositionsSkippingEquals("tests.monster", indexReader19, 0, postingsEnum21, postingsEnum22);
org.apache.lucene.index.IndexReader indexReader25 = null;
org.apache.lucene.index.Terms terms26 = null;
org.apache.lucene.index.Terms terms27 = null;
kuromojiAnalysisTests1.assertTermsEquals("tests.failfast", indexReader25, terms26, terms27, true);
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests1.testDefaultsKuromojiAnalysis();
org.junit.Assert.fail("Expected exception of type java.lang.IllegalStateException; message: No context information for thread: Thread[id=1, name=main, state=RUNNABLE, group=main]. Is this thread running under a class com.carrotsearch.randomizedtesting.RandomizedRunner runner context? Add @RunWith(class com.carrotsearch.randomizedtesting.RandomizedRunner.class) to your test class. Make sure your code accesses random contexts within @BeforeClass and @AfterClass boundary (for example, static test class initializers are not permitted to access random contexts).");
} catch (java.lang.IllegalStateException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain10);
org.junit.Assert.assertEquals("'" + str12 + "' != '" + "<unknown>" + "'", str12, "<unknown>");
}
@Test
public void test02500() throws Throwable {
if (debug)
System.out.format("%n%s%n", "RegressionTest4.test02500");
org.elasticsearch.index.analysis.KuromojiAnalysisTests kuromojiAnalysisTests0 = new org.elasticsearch.index.analysis.KuromojiAnalysisTests();
org.apache.lucene.index.IndexReader indexReader2 = null;
org.apache.lucene.index.Fields fields3 = null;
org.apache.lucene.index.Fields fields4 = null;
kuromojiAnalysisTests0.assertFieldsEquals("europarl.lines.txt.gz", indexReader2, fields3, fields4, false);
kuromojiAnalysisTests0.assertPathHasBeenCleared("tests.slow");
org.junit.rules.RuleChain ruleChain9 = kuromojiAnalysisTests0.failureAndSuccessEvents;
kuromojiAnalysisTests0.resetCheckIndexStatus();
kuromojiAnalysisTests0.restoreIndexWriterMaxDocs();
org.junit.rules.TestRule testRule12 = kuromojiAnalysisTests0.ruleChain;
kuromojiAnalysisTests0.ensureCleanedUp();
org.apache.lucene.index.IndexReader indexReader15 = null;
org.apache.lucene.index.IndexReader indexReader16 = null;
// The following exception was thrown during execution in test generation
try {
kuromojiAnalysisTests0.assertStoredFieldsEquals("", indexReader15, indexReader16);
org.junit.Assert.fail("Expected exception of type java.lang.NullPointerException; message: null");
} catch (java.lang.NullPointerException e) {
// Expected exception.
}
org.junit.Assert.assertNotNull(ruleChain9);
org.junit.Assert.assertNotNull(testRule12);
}
}
|
3e0772295133b62660ead6bd83a953d98a67fa10
| 430 |
java
|
Java
|
sdk/src/main/java/tech/kronicle/sdk/models/Test.java
|
kronicle-tech/kronicle
|
7a6a71451e7a4e26673f9e44d30762f64e0da09d
|
[
"MIT"
] | 3 |
2021-09-05T20:06:06.000Z
|
2022-03-22T22:06:59.000Z
|
sdk/src/main/java/tech/kronicle/sdk/models/Test.java
|
kronicle-tech/kronicle
|
7a6a71451e7a4e26673f9e44d30762f64e0da09d
|
[
"MIT"
] | 158 |
2021-09-11T15:29:59.000Z
|
2022-03-31T00:24:42.000Z
|
sdk/src/main/java/tech/kronicle/sdk/models/Test.java
|
kronicle-tech/kronicle
|
7a6a71451e7a4e26673f9e44d30762f64e0da09d
|
[
"MIT"
] | null | null | null | 17.2 | 45 | 0.75814 | 3,157 |
package tech.kronicle.sdk.models;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Value;
import lombok.With;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
@Value
@AllArgsConstructor
@With
@Builder(toBuilder = true)
public class Test {
@NotBlank
String id;
@NotBlank
String description;
String notes;
@NotNull
Priority priority;
}
|
3e07722e20af585a9726794e68fc70d0ce30ebaa
| 376 |
java
|
Java
|
floating-action-button/app/src/androidTest/java/com/lakeel/altla/sample/floatingactionbutton/ApplicationTest.java
|
lakeel-altla/samples-ui-android
|
cc2632e90a4e361fa35596854527de4fe96a1815
|
[
"MIT"
] | null | null | null |
floating-action-button/app/src/androidTest/java/com/lakeel/altla/sample/floatingactionbutton/ApplicationTest.java
|
lakeel-altla/samples-ui-android
|
cc2632e90a4e361fa35596854527de4fe96a1815
|
[
"MIT"
] | null | null | null |
floating-action-button/app/src/androidTest/java/com/lakeel/altla/sample/floatingactionbutton/ApplicationTest.java
|
lakeel-altla/samples-ui-android
|
cc2632e90a4e361fa35596854527de4fe96a1815
|
[
"MIT"
] | null | null | null | 26.857143 | 93 | 0.760638 | 3,158 |
package com.lakeel.altla.sample.floatingactionbutton;
import android.app.Application;
import android.test.ApplicationTestCase;
/**
* <a href="http://d.android.com/tools/testing/testing_android.html">Testing Fundamentals</a>
*/
public class ApplicationTest extends ApplicationTestCase<Application> {
public ApplicationTest() {
super(Application.class);
}
}
|
3e0773cb7be93a707e8016cce67c2e0dc9c838f6
| 1,097 |
java
|
Java
|
src/main/java/jports/data/ListUpdate.java
|
rportela/jports
|
61c3fd6f9e7adc66f15b4771ed7df73fdb62ab93
|
[
"Apache-2.0"
] | 2 |
2018-12-28T00:55:49.000Z
|
2019-01-09T20:57:28.000Z
|
src/main/java/jports/data/ListUpdate.java
|
rportela/jports
|
61c3fd6f9e7adc66f15b4771ed7df73fdb62ab93
|
[
"Apache-2.0"
] | 2 |
2021-01-20T23:33:36.000Z
|
2021-12-09T20:47:07.000Z
|
src/main/java/jports/data/ListUpdate.java
|
rportela/jports
|
61c3fd6f9e7adc66f15b4771ed7df73fdb62ab93
|
[
"Apache-2.0"
] | null | null | null | 25.511628 | 62 | 0.689152 | 3,159 |
package jports.data;
import java.util.ArrayList;
import java.util.List;
import java.util.Map.Entry;
import java.util.stream.Stream;
import jports.Incrementer;
public class ListUpdate<T> extends Update {
private final ListStorage<T> storage;
public ListUpdate(ListStorage<T> storage) {
this.storage = storage;
}
@Override
public int execute() {
final DataAspect<T, ?> aspect = storage.getAspect();
final List<Integer> indices = new ArrayList<>(super.size());
final List<Object> values = new ArrayList<>(super.size());
final Incrementer inc = new Incrementer();
for (Entry<String, Object> entry : getValues().entrySet()) {
indices.add(aspect.getColumnOrdinal(entry.getKey()));
values.add(entry.getValue());
}
Stream<T> stream = storage.all().stream();
FilterExpression filter2 = getFilter();
if (filter2 != null)
stream = stream.filter(aspect.createFilter(filter2));
stream.forEach(e -> {
for (int i = 0; i < indices.size(); i++) {
aspect.get(indices.get(i)).setValue(e, values.get(i));
}
inc.increment();
});
return inc.getValue();
}
}
|
3e07740c30e4814f9fc988892abc2731100ddfa6
| 3,215 |
java
|
Java
|
app/src/main/java/com/example/weathertest4/AutoUpdateService.java
|
lijiayang235/WeatherTest4
|
b88ea141ae0fca27c4b9289c71413ab5935b7166
|
[
"Apache-2.0"
] | null | null | null |
app/src/main/java/com/example/weathertest4/AutoUpdateService.java
|
lijiayang235/WeatherTest4
|
b88ea141ae0fca27c4b9289c71413ab5935b7166
|
[
"Apache-2.0"
] | null | null | null |
app/src/main/java/com/example/weathertest4/AutoUpdateService.java
|
lijiayang235/WeatherTest4
|
b88ea141ae0fca27c4b9289c71413ab5935b7166
|
[
"Apache-2.0"
] | null | null | null | 34.945652 | 129 | 0.655988 | 3,160 |
package com.example.weathertest4;
import android.app.AlarmManager;
import android.app.PendingIntent;
import android.app.Service;
import android.content.Intent;
import android.content.SharedPreferences;
import android.os.IBinder;
import android.os.SystemClock;
import android.preference.PreferenceManager;
import android.util.Log;
import com.example.weathertest4.gson.Weather;
import com.example.weathertest4.util.HttpSendUrl;
import com.example.weathertest4.util.Utility;
import java.io.IOException;
import okhttp3.Call;
import okhttp3.Callback;
import okhttp3.Response;
public class AutoUpdateService extends Service {
public AutoUpdateService() {
}
@Override
public IBinder onBind(Intent intent) {
return null;
}
@Override
public int onStartCommand(Intent intent, int flags, int startId) {
Log.d("myTest","onStartCommand");
updateBinPic();
updateWeather();
AlarmManager manager= (AlarmManager) getSystemService(ALARM_SERVICE);
Intent i=new Intent(this,AutoUpdateService.class);
PendingIntent pi=PendingIntent.getService(this,0,i,0);
manager.cancel(pi);
long hours=8*60*60*1000;
long triggertime= SystemClock.elapsedRealtime()+hours;
manager.set(AlarmManager.ELAPSED_REALTIME_WAKEUP,triggertime,pi);
return super.onStartCommand(intent, flags, startId);
}
private void updateBinPic() {
String address="http://guolin.tech/api/bing_pic";
HttpSendUrl.sendOkhttp3(address, new Callback() {
@Override
public void onFailure(Call call, IOException e) {
e.printStackTrace();
}
@Override
public void onResponse(Call call, Response response) throws IOException {
String bingPic=response.body().string();
SharedPreferences.Editor editor=PreferenceManager.getDefaultSharedPreferences(AutoUpdateService.this).edit();
editor.putString("bing_pic",bingPic);
editor.apply();
}
});
}
private void updateWeather() {
SharedPreferences pref= PreferenceManager.getDefaultSharedPreferences(this);
final String reponseText=pref.getString("weather",null);
if(reponseText!=null){
Weather weahter= Utility.handWeather(reponseText);
String weatherId=weahter.basic.weatherId;
String address="http://guolin.tech/api/weather?cityid="+weatherId+"&key=19dbb264703e45ff96e4373c0a67268b";
HttpSendUrl.sendOkhttp3(address, new Callback() {
@Override
public void onFailure(Call call, IOException e) {
e.printStackTrace();
}
@Override
public void onResponse(Call call, Response response) throws IOException {
String responseText=response.body().string();
SharedPreferences.Editor editor=PreferenceManager.getDefaultSharedPreferences(AutoUpdateService.this).edit();
editor.putString("weather",reponseText);
editor.apply();
}
});
}
}
}
|
3e0774ac3d9ef6927f9fb42758486a07fdfc1b64
| 1,407 |
java
|
Java
|
gwtbliss-example/src/main/java/client/index/IndexViewImpl.java
|
domjansen/gwtbliss
|
95a1628bc9fb02ccf41fbffc027b0f34d16064d0
|
[
"Apache-2.0"
] | null | null | null |
gwtbliss-example/src/main/java/client/index/IndexViewImpl.java
|
domjansen/gwtbliss
|
95a1628bc9fb02ccf41fbffc027b0f34d16064d0
|
[
"Apache-2.0"
] | null | null | null |
gwtbliss-example/src/main/java/client/index/IndexViewImpl.java
|
domjansen/gwtbliss
|
95a1628bc9fb02ccf41fbffc027b0f34d16064d0
|
[
"Apache-2.0"
] | null | null | null | 30.456522 | 118 | 0.734475 | 3,161 |
/*
* Copyright 2013, devbliss GmbH
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on
* an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
* specific language governing permissions and limitations under the License.
*/
package client.index;
import com.google.gwt.uibinder.client.UiBinder;
import com.google.gwt.user.client.ui.Widget;
import com.google.inject.Inject;
import com.gwtplatform.mvp.client.ViewImpl;
/**
* Default implementation of {@link IndexPresenter.View}.
*
* @author <a href="mailto:[email protected]">Johannes Barop</a>
*
*/
public class IndexViewImpl extends ViewImpl implements IndexPresenter.View {
public interface IndexViewImplUiBinder extends UiBinder<Widget, IndexViewImpl> {
}
private final Widget widget;
@Inject
public IndexViewImpl(final IndexViewImplUiBinder uiBinder) {
this.widget = uiBinder.createAndBindUi(this);
this.widget.ensureDebugId(IndexViewImpl.class.getName());
}
@Override
public Widget asWidget() {
return widget;
}
}
|
3e0774dde1b7b3449f37eaa5431ccb9405c0148b
| 1,485 |
java
|
Java
|
src/test/java/com/github/niko247/AppTest.java
|
niko247/wuhan
|
dcc4f42ec70793b9e0d3783ad8008f453cff8582
|
[
"MIT"
] | null | null | null |
src/test/java/com/github/niko247/AppTest.java
|
niko247/wuhan
|
dcc4f42ec70793b9e0d3783ad8008f453cff8582
|
[
"MIT"
] | null | null | null |
src/test/java/com/github/niko247/AppTest.java
|
niko247/wuhan
|
dcc4f42ec70793b9e0d3783ad8008f453cff8582
|
[
"MIT"
] | null | null | null | 29.117647 | 108 | 0.717172 | 3,162 |
package com.github.niko247;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
import org.mockito.junit.MockitoJUnitRunner;
import java.io.IOException;
import java.util.Collections;
import java.util.Optional;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
@RunWith(MockitoJUnitRunner.class)
public class AppTest {
@Mock
private PushManager push;
@Mock
private CoronaResultsFetcher casesFetcher;
@Mock
private OldCasesManager oldCasesManager;
@Mock
private ReportMessageCreator reportMessageCreator;
private final SummaryResults currentCases = new SummaryResults(30, 12);
private final SummaryResults oldCases = new SummaryResults(10, 5);
@Test
public void fetchPageAndReportTest() throws IOException {
//given
var app = new App(Collections.singleton(push), casesFetcher, oldCasesManager, reportMessageCreator);
when(casesFetcher.fetchCases()).thenReturn(currentCases);
when(oldCasesManager.get()).thenReturn(Optional.of(oldCases));
var report = "REPORT";
when(reportMessageCreator.createIfNewCases(currentCases, oldCases)).
thenReturn(Optional.of(report));
//when
app.fetchPageAndReport();
//then
verify(casesFetcher).fetchCases();
verify(oldCasesManager).get();
verify(oldCasesManager).save(currentCases);
verify(push).send(report);
}
}
|
3e0774e9c89650920f3f97aec0730f7f12ed8de3
| 1,326 |
java
|
Java
|
sdk/monitor/mgmt-v2019_11_01/src/main/java/com/microsoft/azure/management/monitor/v2019_11_01/SingleMetricBaseline.java
|
yiliuTo/azure-sdk-for-java
|
4536b6e99ded1b2b77f79bc2c31f42566c97b704
|
[
"MIT"
] | 3 |
2021-09-15T16:25:19.000Z
|
2021-12-17T05:41:00.000Z
|
sdk/monitor/mgmt-v2019_11_01/src/main/java/com/microsoft/azure/management/monitor/v2019_11_01/SingleMetricBaseline.java
|
yiliuTo/azure-sdk-for-java
|
4536b6e99ded1b2b77f79bc2c31f42566c97b704
|
[
"MIT"
] | 12 |
2019-07-17T16:18:54.000Z
|
2019-07-17T21:30:02.000Z
|
sdk/monitor/mgmt-v2019_11_01/src/main/java/com/microsoft/azure/management/monitor/v2019_11_01/SingleMetricBaseline.java
|
yiliuTo/azure-sdk-for-java
|
4536b6e99ded1b2b77f79bc2c31f42566c97b704
|
[
"MIT"
] | 1 |
2022-01-31T19:22:33.000Z
|
2022-01-31T19:22:33.000Z
| 22.862069 | 111 | 0.678733 | 3,163 |
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/
package com.microsoft.azure.management.monitor.v2019_11_01;
import com.microsoft.azure.arm.model.HasInner;
import com.microsoft.azure.arm.resources.models.HasManager;
import com.microsoft.azure.management.monitor.v2019_11_01.implementation.MonitorManager;
import com.microsoft.azure.management.monitor.v2019_11_01.implementation.SingleMetricBaselineInner;
import java.util.List;
import org.joda.time.Period;
/**
* Type representing SingleMetricBaseline.
*/
public interface SingleMetricBaseline extends HasInner<SingleMetricBaselineInner>, HasManager<MonitorManager> {
/**
* @return the baselines value.
*/
List<TimeSeriesBaseline> baselines();
/**
* @return the id value.
*/
String id();
/**
* @return the interval value.
*/
Period interval();
/**
* @return the name value.
*/
String name();
/**
* @return the namespace value.
*/
String namespace();
/**
* @return the timespan value.
*/
String timespan();
/**
* @return the type value.
*/
String type();
}
|
3e0776543a7e9f97588e3e5d6b63b027e770be65
| 4,474 |
java
|
Java
|
1_image_sdks/text_recognition/ocr_sdk/src/main/java/me/aias/example/utils/OcrV3Recognition.java
|
LeiSoft/AIAS
|
5559628fe86fb36ea29ea0214046701f9e6e0304
|
[
"Apache-2.0"
] | null | null | null |
1_image_sdks/text_recognition/ocr_sdk/src/main/java/me/aias/example/utils/OcrV3Recognition.java
|
LeiSoft/AIAS
|
5559628fe86fb36ea29ea0214046701f9e6e0304
|
[
"Apache-2.0"
] | null | null | null |
1_image_sdks/text_recognition/ocr_sdk/src/main/java/me/aias/example/utils/OcrV3Recognition.java
|
LeiSoft/AIAS
|
5559628fe86fb36ea29ea0214046701f9e6e0304
|
[
"Apache-2.0"
] | null | null | null | 36.373984 | 108 | 0.6692 | 3,164 |
package me.aias.example.utils;
import ai.djl.inference.Predictor;
import ai.djl.modality.cv.Image;
import ai.djl.modality.cv.ImageFactory;
import ai.djl.modality.cv.output.BoundingBox;
import ai.djl.modality.cv.output.DetectedObjects;
import ai.djl.modality.cv.output.Rectangle;
import ai.djl.modality.cv.util.NDImageUtils;
import ai.djl.ndarray.NDArray;
import ai.djl.ndarray.NDManager;
import ai.djl.paddlepaddle.zoo.cv.objectdetection.PpWordDetectionTranslator;
import ai.djl.repository.zoo.Criteria;
import ai.djl.training.util.ProgressBar;
import ai.djl.translate.TranslateException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.ConcurrentHashMap;
public final class OcrV3Recognition {
private static final Logger logger = LoggerFactory.getLogger(OcrV3Recognition.class);
public OcrV3Recognition() {}
public DetectedObjects predict(
Image image, Predictor<Image, DetectedObjects> detector, Predictor<Image, String> recognizer)
throws TranslateException {
DetectedObjects detections = detector.predict(image);
List<DetectedObjects.DetectedObject> boxes = detections.items();
List<String> names = new ArrayList<>();
List<Double> prob = new ArrayList<>();
List<BoundingBox> rect = new ArrayList<>();
for (int i = 0; i < boxes.size(); i++) {
Image subImg = getSubImage(image, boxes.get(i).getBoundingBox());
if (subImg.getHeight() * 1.0 / subImg.getWidth() > 1.5) {
subImg = rotateImg(subImg);
}
String name = recognizer.predict(subImg);
names.add(name);
prob.add(-1.0);
rect.add(boxes.get(i).getBoundingBox());
}
DetectedObjects detectedObjects = new DetectedObjects(names, prob, rect);
return detectedObjects;
}
public Criteria<Image, DetectedObjects> detectCriteria() {
Criteria<Image, DetectedObjects> criteria =
Criteria.builder()
.optEngine("PaddlePaddle")
.setTypes(Image.class, DetectedObjects.class)
.optModelUrls(
"https://aias-home.oss-cn-beijing.aliyuncs.com/models/ocr_models/ch_PP-OCRv3_det_infer.zip")
// .optModelUrls(
// "/Users/calvin/Documents/build/paddle_models/ppocr/ch_PP-OCRv2_det_infer")
.optTranslator(new PpWordDetectionTranslator(new ConcurrentHashMap<String, String>()))
.optProgress(new ProgressBar())
.build();
return criteria;
}
public Criteria<Image, String> recognizeCriteria(boolean enableFilter, float thresh) {
Criteria<Image, String> criteria =
Criteria.builder()
.optEngine("PaddlePaddle")
.setTypes(Image.class, String.class)
.optModelUrls(
"https://aias-home.oss-cn-beijing.aliyuncs.com/models/ocr_models/ch_PP-OCRv3_rec_infer.zip")
.optProgress(new ProgressBar())
.optTranslator(new PpWordRecognitionTranslator(enableFilter, thresh))
.build();
return criteria;
}
private Image getSubImage(Image img, BoundingBox box) {
Rectangle rect = box.getBounds();
double[] extended = extendRect(rect.getX(), rect.getY(), rect.getWidth(), rect.getHeight());
int width = img.getWidth();
int height = img.getHeight();
int[] recovered = {
(int) (extended[0] * width),
(int) (extended[1] * height),
(int) (extended[2] * width),
(int) (extended[3] * height)
};
return img.getSubImage(recovered[0], recovered[1], recovered[2], recovered[3]);
}
private double[] extendRect(double xmin, double ymin, double width, double height) {
double centerx = xmin + width / 2;
double centery = ymin + height / 2;
if (width > height) {
width += height * 2.0;
height *= 3.0;
} else {
height += width * 2.0;
width *= 3.0;
}
double newX = centerx - width / 2 < 0 ? 0 : centerx - width / 2;
double newY = centery - height / 2 < 0 ? 0 : centery - height / 2;
double newWidth = newX + width > 1 ? 1 - newX : width;
double newHeight = newY + height > 1 ? 1 - newY : height;
return new double[] {newX, newY, newWidth, newHeight};
}
private Image rotateImg(Image image) {
try (NDManager manager = NDManager.newBaseManager()) {
NDArray rotated = NDImageUtils.rotate90(image.toNDArray(manager), 1);
return ImageFactory.getInstance().fromNDArray(rotated);
}
}
}
|
3e07766de2e9d42d9ca8049388e059b1c43e7bc1
| 3,425 |
java
|
Java
|
hamster-selenium-examples/src/test/java/com/github/grossopa/selenium/examples/mat/MatSnackbarTestCases.java
|
grossopa/hamster-selenium
|
e8fe83d91507b4e878f2771f7842ca4932e6662f
|
[
"MIT"
] | null | null | null |
hamster-selenium-examples/src/test/java/com/github/grossopa/selenium/examples/mat/MatSnackbarTestCases.java
|
grossopa/hamster-selenium
|
e8fe83d91507b4e878f2771f7842ca4932e6662f
|
[
"MIT"
] | 14 |
2020-12-11T05:41:46.000Z
|
2021-11-15T13:13:07.000Z
|
hamster-selenium-examples/src/test/java/com/github/grossopa/selenium/examples/mat/MatSnackbarTestCases.java
|
grossopa/hamster-selenium
|
e8fe83d91507b4e878f2771f7842ca4932e6662f
|
[
"MIT"
] | 1 |
2020-10-13T19:36:27.000Z
|
2020-10-13T19:36:27.000Z
| 46.917808 | 117 | 0.748905 | 3,165 |
/*
* Copyright © 2021 the original author or authors.
*
* Licensed under the The MIT License (MIT) (the "License");
* You may obtain a copy of the License at
*
* https://mit-license.org/
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software
* and associated documentation files (the “Software”), to deal in the Software without
* restriction, including without limitation the rights to use, copy, modify, merge, publish,
* distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all copies or
* substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
* BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
* DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package com.github.grossopa.selenium.examples.mat;
import com.github.grossopa.hamster.selenium.component.mat.config.MatConfig;
import com.github.grossopa.hamster.selenium.component.mat.finder.MatOverlayFinder;
import com.github.grossopa.hamster.selenium.component.mat.main.MatSnackbar;
import com.github.grossopa.selenium.core.component.WebComponent;
import com.github.grossopa.selenium.examples.helper.AbstractBrowserSupport;
import org.openqa.selenium.By;
import static com.github.grossopa.hamster.selenium.component.mat.MatComponents.mat;
import static com.github.grossopa.selenium.core.driver.WebDriverType.EDGE;
import static com.github.grossopa.selenium.core.locator.By2.xpathBuilder;
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertNotNull;
/**
* @author Jack Yin
* @since 1.0
*/
public class MatSnackbarTestCases extends AbstractBrowserSupport {
public void testSliderConfiguration() {
WebComponent button = driver.findComponent(By.id("snack-bar-overview"))
.findComponent(xpathBuilder().anywhereRelative().text().exact("Show snack-bar").build());
button.click();
MatOverlayFinder finder = new MatOverlayFinder(driver, new MatConfig());
WebComponent overlayContainer = finder.findTopVisibleContainer();
assertNotNull(overlayContainer);
MatSnackbar snackbar = overlayContainer.findComponent(By.tagName("simple-snack-bar")).as(mat()).toSnackbar();
assertEquals("Disco party!", snackbar.getLabel().getText());
assertEquals("Dance", snackbar.getActionButton().getText());
snackbar.getActionButton().click();
// wait for the animation to disappear
driver.threadSleep(1000L);
assertEquals(0, overlayContainer.findComponents(By.tagName("simple-snack-bar")).size());
}
public static void main(String[] args) {
MatSnackbarTestCases test = new MatSnackbarTestCases();
test.setUpDriver(EDGE);
test.driver.navigate().to("https://material.angular.io/components/snack-bar/examples");
test.testSliderConfiguration();
}
}
|
3e07771ffcee66b17a0ef81cc3da0471066a0c94
| 191 |
java
|
Java
|
src/main/java/br/edu/utfpr/pb/trabalhofinal/service/VendaProdutoService.java
|
heretbg/trabalhoFinal-Web1
|
6b56b071d894c79f1dc2a470e0bac5ec55a06e1b
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/br/edu/utfpr/pb/trabalhofinal/service/VendaProdutoService.java
|
heretbg/trabalhoFinal-Web1
|
6b56b071d894c79f1dc2a470e0bac5ec55a06e1b
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/br/edu/utfpr/pb/trabalhofinal/service/VendaProdutoService.java
|
heretbg/trabalhoFinal-Web1
|
6b56b071d894c79f1dc2a470e0bac5ec55a06e1b
|
[
"Apache-2.0"
] | null | null | null | 23.875 | 81 | 0.827225 | 3,166 |
package br.edu.utfpr.pb.trabalhofinal.service;
import br.edu.utfpr.pb.trabalhofinal.model.VendaProduto;
public interface VendaProdutoService extends CrudService<VendaProduto, Integer> {
}
|
3e077750e4d6f73597e60e68866f7297f560d834
| 529 |
java
|
Java
|
security-demo/src/main/java/org/labsse/demo/dto/UserQueryCondition.java
|
jaki2012/LongZheng-CodeChecker
|
88150901c75e75c72e545b4dedf012ec8c97eaa9
|
[
"MIT"
] | null | null | null |
security-demo/src/main/java/org/labsse/demo/dto/UserQueryCondition.java
|
jaki2012/LongZheng-CodeChecker
|
88150901c75e75c72e545b4dedf012ec8c97eaa9
|
[
"MIT"
] | null | null | null |
security-demo/src/main/java/org/labsse/demo/dto/UserQueryCondition.java
|
jaki2012/LongZheng-CodeChecker
|
88150901c75e75c72e545b4dedf012ec8c97eaa9
|
[
"MIT"
] | null | null | null | 17.633333 | 47 | 0.695652 | 3,167 |
package org.labsse.demo.dto;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
/**
* @author lijiechu
* @create on 2018/12/21
* @description 用户查询条件DTO类
*/
@Data
@AllArgsConstructor
@NoArgsConstructor
public class UserQueryCondition {
private String username;
/**
* 年龄上界条件
*/
@ApiModelProperty("用户终止年龄")
private int ageTo;
/**
* 年龄下界条件
*/
@ApiModelProperty("用户起始年龄")
private int ageFrom;
}
|
3e07786af8b2c7f24d28ab3c14c8e3cdf15a11ab
| 1,297 |
java
|
Java
|
app/src/main/java/com/example/parseinstagram/fragments/ProfileFragment.java
|
jellyhat/parseinstagram
|
db541c779e22c66fee6cddbb7e31720eb5fd259d
|
[
"Apache-2.0"
] | null | null | null |
app/src/main/java/com/example/parseinstagram/fragments/ProfileFragment.java
|
jellyhat/parseinstagram
|
db541c779e22c66fee6cddbb7e31720eb5fd259d
|
[
"Apache-2.0"
] | 1 |
2019-03-29T05:37:05.000Z
|
2019-04-02T08:36:56.000Z
|
app/src/main/java/com/example/parseinstagram/fragments/ProfileFragment.java
|
jellyhat/parseinstagram
|
db541c779e22c66fee6cddbb7e31720eb5fd259d
|
[
"Apache-2.0"
] | null | null | null | 31.634146 | 76 | 0.60293 | 3,168 |
package com.example.parseinstagram.fragments;
import android.util.Log;
import com.example.parseinstagram.Post;
import com.parse.FindCallback;
import com.parse.ParseException;
import com.parse.ParseQuery;
import com.parse.ParseUser;
import java.util.List;
public class ProfileFragment extends PostsFragment {
private String TAG = "ProfileFragment";
protected void queryPosts(){
adapter.clear();
ParseQuery<Post> postQuery = new ParseQuery<Post>(Post.class);
postQuery.include(Post.KEY_USER);
postQuery.setLimit(20);
postQuery.whereEqualTo(Post.KEY_USER, ParseUser.getCurrentUser());
postQuery.addDescendingOrder(Post.KEY_CREATED_AT);
postQuery.findInBackground(new FindCallback<Post>() {
@Override
public void done(List<Post> posts, ParseException e) {
if(e != null){
Log.e(TAG, "Query Error");
return;
}
mPosts.addAll(posts);
adapter.notifyDataSetChanged();
swipeRefreshLayout.setRefreshing(false);
for(int i =0; i < posts.size(); i++) {
Log.d(TAG, "Post:" + posts.get(i).getKeyDescription() );
}
}
});
}
}
|
3e0778b4b02640c083915d84feeaac5d3720ecaf
| 909 |
java
|
Java
|
app/src/main/java/com/example/eshen/nytimessearch/DatePickerFragment.java
|
elwshen/NYTimes
|
316103a082184f76443f39644367f00ba879ed11
|
[
"Apache-2.0"
] | null | null | null |
app/src/main/java/com/example/eshen/nytimessearch/DatePickerFragment.java
|
elwshen/NYTimes
|
316103a082184f76443f39644367f00ba879ed11
|
[
"Apache-2.0"
] | 1 |
2016-06-25T02:01:27.000Z
|
2016-06-26T18:04:03.000Z
|
app/src/main/java/com/example/eshen/nytimessearch/DatePickerFragment.java
|
elwshen/NYTimes
|
316103a082184f76443f39644367f00ba879ed11
|
[
"Apache-2.0"
] | null | null | null | 34.961538 | 105 | 0.728273 | 3,169 |
package com.example.eshen.nytimessearch;
import android.app.DatePickerDialog;
import android.app.Dialog;
import android.os.Bundle;
import android.support.v4.app.DialogFragment;
import java.util.Calendar;
public class DatePickerFragment extends DialogFragment {
@Override
public Dialog onCreateDialog(Bundle savedInstanceState) {
// Use the current time as the default values for the picker
final Calendar c = Calendar.getInstance();
int year = c.get(Calendar.YEAR);
int month = c.get(Calendar.MONTH);
int day = c.get(Calendar.DAY_OF_MONTH);
// Activity needs to implement this interface
DatePickerDialog.OnDateSetListener listener = (DatePickerDialog.OnDateSetListener) getActivity();
// Create a new instance of TimePickerDialog and return it
return new DatePickerDialog(getActivity(), listener, year, month, day);
}
}
|
3e077905d88dee500bb2bdc1f872a0c73759368b
| 1,932 |
java
|
Java
|
app/src/main/java/scope/flickster/models/singleMovie.java
|
zdenham/flickster
|
b23c1a7c904d610e0dfad4c9d0eab54555d124c5
|
[
"Apache-2.0"
] | null | null | null |
app/src/main/java/scope/flickster/models/singleMovie.java
|
zdenham/flickster
|
b23c1a7c904d610e0dfad4c9d0eab54555d124c5
|
[
"Apache-2.0"
] | 1 |
2016-08-02T05:34:00.000Z
|
2016-08-02T05:34:00.000Z
|
app/src/main/java/scope/flickster/models/singleMovie.java
|
zdenham/flickster
|
b23c1a7c904d610e0dfad4c9d0eab54555d124c5
|
[
"Apache-2.0"
] | null | null | null | 26.465753 | 81 | 0.577122 | 3,170 |
package scope.flickster.models;
import android.util.Log;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;
import java.util.ArrayList;
/**
* Created by zdenham on 7/25/16.
*/
public class singleMovie {
String posterPath;
String title;
String overView;
int orientation;
String size;
public JSONObject myObject;
public singleMovie(JSONObject myObject) throws JSONException {
this.myObject = myObject;
}
public static ArrayList<singleMovie> fromJSONArray(JSONArray array) {
ArrayList<singleMovie> results = new ArrayList<>();
for (int x = 0; x < array.length(); x++) {
try {
results.add(new singleMovie(array.getJSONObject(x)));
} catch (JSONException e){
e.printStackTrace();
}
}
return results;
}
public void setOrientation(int orientation) {
this.orientation = orientation;
setPics();
}
public void setPics() {
try {
if (orientation == 1) {
size = "w342/";
Log.d("1", Integer.toString(this.orientation));
this.posterPath = myObject.getString("poster_path");
} else if (orientation == 2) {
size = "w650/";
Log.d("2", Integer.toString(this.orientation));
this.posterPath = myObject.getString("backdrop_path");
}
this.title = myObject.getString("original_title");
this.overView = myObject.getString("overview");
} catch (JSONException e){
e.printStackTrace();
}
}
public String getTitle() {
return title;
}
public String getPosterPath() {
return String.format("https://image.tmdb.org/t/p/%s%s",size, posterPath);
}
public String getOverView() {
return overView;
}
}
|
3e0779b663bd8d69c88982b0aeb843b0dfad7244
| 2,299 |
java
|
Java
|
ion-core/tests/ion/core/mocks/MetaRepositoryMock.java
|
iondv/ion-old-java-version-20140819
|
97173f6af432050b8d6365a5338ea3515ba7b991
|
[
"Apache-2.0"
] | null | null | null |
ion-core/tests/ion/core/mocks/MetaRepositoryMock.java
|
iondv/ion-old-java-version-20140819
|
97173f6af432050b8d6365a5338ea3515ba7b991
|
[
"Apache-2.0"
] | null | null | null |
ion-core/tests/ion/core/mocks/MetaRepositoryMock.java
|
iondv/ion-old-java-version-20140819
|
97173f6af432050b8d6365a5338ea3515ba7b991
|
[
"Apache-2.0"
] | null | null | null | 29.101266 | 114 | 0.758156 | 3,171 |
package ion.core.mocks;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashMap;
import java.util.Map;
import java.util.Map.Entry;
import ion.core.IMetaRepository;
import ion.core.IPropertyMeta;
import ion.core.IStructMeta;
import ion.core.IUserTypeMeta;
import ion.core.IonException;
public class MetaRepositoryMock implements IMetaRepository {
private Map<String, IStructMeta> structures;
private Map<String, Map<String, IPropertyMeta>> properties;
private Map<String,String> ancestors;
public MetaRepositoryMock() {
super();
this.structures = new HashMap<String, IStructMeta>();
this.properties = new HashMap<String, Map<String, IPropertyMeta>>();
this.ancestors = new HashMap<String, String>();
}
public void addStruct(IStructMeta struct, Map<String, IPropertyMeta> props) throws IonException {
structures.put(struct.getName(), struct);
properties.put(struct.getName(), props);
}
@Override
public IStructMeta Get(String name) throws IonException {return structures.get(name);}
@Override
public IStructMeta Ancestor(String name) throws IonException {
String ancestor = ancestors.get(name);
if(ancestor!=null){
return structures.get(ancestor);
}
return null;
}
public void setAncestor(String name, String ancestorName){
ancestors.put(name, ancestorName);
}
public Map<String, IStructMeta> getStructures(){
return structures;
}
@Override
public Collection<IStructMeta> List() throws IonException {return structures.values();}
@Override
public Collection<IStructMeta> List(String ancestor) throws IonException {
Collection<IStructMeta> result = new ArrayList<IStructMeta>();
for(Entry<String, IStructMeta> e: structures.entrySet()){
IStructMeta anc = e.getValue().checkAncestor(ancestor);
if(anc != null && !anc.getName().equals(e.getValue().getName()))
result.add(e.getValue());
}
return result;
}
@Override
public Collection<IStructMeta> List(String ancestor, Boolean direct) throws IonException {return List(ancestor);}
@Override
public Map<String, IPropertyMeta> PropertyMetas(String name) throws IonException {return properties.get(name);}
@Override
public IUserTypeMeta GetUserType(String name) throws IonException {
// TODO Auto-generated method stub
return null;
}
}
|
3e077a2cc43541a2b278c4e46ca3311a24fe8bb0
| 932 |
java
|
Java
|
bione-plugin/src/main/java/com/yusys/bione/plugin/regulation/vo/FormulaCell.java
|
JamesLoveCurry/bione_input
|
6cb302439369bb364d4bb1de45d70b2b54d94a23
|
[
"Apache-2.0"
] | null | null | null |
bione-plugin/src/main/java/com/yusys/bione/plugin/regulation/vo/FormulaCell.java
|
JamesLoveCurry/bione_input
|
6cb302439369bb364d4bb1de45d70b2b54d94a23
|
[
"Apache-2.0"
] | null | null | null |
bione-plugin/src/main/java/com/yusys/bione/plugin/regulation/vo/FormulaCell.java
|
JamesLoveCurry/bione_input
|
6cb302439369bb364d4bb1de45d70b2b54d94a23
|
[
"Apache-2.0"
] | null | null | null | 18.64 | 63 | 0.759657 | 3,172 |
package com.yusys.bione.plugin.regulation.vo;
import com.yusys.bione.plugin.regulation.enums.YesOrNo;
/**
* 报表指标类公式单元格,支持以templateId、srcIndexNoes等排序
*/
public class FormulaCell extends IndexBaseCell {
private String formula;
private YesOrNo isRptIndex;
private String excelCellNo;
private FormulaIndex[] formulaIndexes;
public String getFormula() {
return formula;
}
public void setFormula(String formula) {
this.formula = formula;
}
public YesOrNo getIsRptIndex() {
return isRptIndex;
}
public void setIsRptIndex(YesOrNo isRptIndex) {
this.isRptIndex = isRptIndex;
}
public String getExcelCellNo() {
return excelCellNo;
}
public void setExcelCellNo(String excelCellNo) {
this.excelCellNo = excelCellNo;
}
public FormulaIndex[] getFormulaIndexes() {
return formulaIndexes;
}
public void setFormulaIndexes(FormulaIndex[] formulaIndexes) {
this.formulaIndexes = formulaIndexes;
}
}
|
3e077ab6bd3a37a3c5f051a87b81c3fce2e3b2a7
| 8,789 |
java
|
Java
|
external/storm-kafka-client/src/test/java/org/apache/storm/kafka/spout/KafkaSpoutRebalanceTest.java
|
lindseyklanier/storm-code
|
0d220c93cd85d6e434188ef1c50f4d216b71cf43
|
[
"Apache-2.0"
] | 1 |
2018-03-15T03:51:09.000Z
|
2018-03-15T03:51:09.000Z
|
external/storm-kafka-client/src/test/java/org/apache/storm/kafka/spout/KafkaSpoutRebalanceTest.java
|
lindseyklanier/storm-code
|
0d220c93cd85d6e434188ef1c50f4d216b71cf43
|
[
"Apache-2.0"
] | null | null | null |
external/storm-kafka-client/src/test/java/org/apache/storm/kafka/spout/KafkaSpoutRebalanceTest.java
|
lindseyklanier/storm-code
|
0d220c93cd85d6e434188ef1c50f4d216b71cf43
|
[
"Apache-2.0"
] | null | null | null | 52.628743 | 205 | 0.762317 | 3,173 |
/*
* Copyright 2016 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.storm.kafka.spout;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import org.apache.kafka.clients.consumer.ConsumerRebalanceListener;
import org.apache.kafka.clients.consumer.ConsumerRecord;
import org.apache.kafka.clients.consumer.ConsumerRecords;
import org.apache.kafka.clients.consumer.KafkaConsumer;
import org.apache.kafka.clients.consumer.OffsetAndMetadata;
import org.apache.kafka.common.TopicPartition;
import org.apache.storm.kafka.spout.builders.SingleTopicKafkaSpoutConfiguration;
import static org.apache.storm.kafka.spout.builders.SingleTopicKafkaSpoutConfiguration.getKafkaSpoutStreams;
import org.apache.storm.kafka.spout.internal.KafkaConsumerFactory;
import org.apache.storm.spout.SpoutOutputCollector;
import org.apache.storm.task.TopologyContext;
import org.junit.Test;
import org.mockito.ArgumentCaptor;
import static org.mockito.Matchers.anyCollection;
import static org.mockito.Matchers.anyLong;
import static org.mockito.Matchers.anyObject;
import static org.mockito.Mockito.when;
import org.junit.Before;
import org.mockito.Captor;
import static org.mockito.Mockito.reset;
import org.mockito.MockitoAnnotations;
import static org.apache.storm.kafka.spout.builders.SingleTopicKafkaSpoutConfiguration.getKafkaSpoutConfig;
import static org.hamcrest.CoreMatchers.not;
import static org.hamcrest.Matchers.hasKey;
import static org.junit.Assert.assertThat;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.never;
import static org.mockito.Mockito.verify;
public class KafkaSpoutRebalanceTest {
@Captor
private ArgumentCaptor<Map<TopicPartition, OffsetAndMetadata>> commitCapture;
private TopologyContext contextMock;
private SpoutOutputCollector collectorMock;
private Map conf;
private KafkaConsumer<String, String> consumerMock;
private KafkaConsumerFactory<String, String> consumerFactoryMock;
@Before
public void setUp() {
MockitoAnnotations.initMocks(this);
contextMock = mock(TopologyContext.class);
collectorMock = mock(SpoutOutputCollector.class);
conf = new HashMap<>();
consumerMock = mock(KafkaConsumer.class);
consumerFactoryMock = (kafkaSpoutConfig) -> consumerMock;
}
//Returns messageIds in order of emission
private List<KafkaSpoutMessageId> emitOneMessagePerPartitionThenRevokeOnePartition(KafkaSpout<String, String> spout, TopicPartition partitionThatWillBeRevoked, TopicPartition assignedPartition) {
//Setup spout with mock consumer so we can get at the rebalance listener
spout.open(conf, contextMock, collectorMock);
spout.activate();
ArgumentCaptor<ConsumerRebalanceListener> rebalanceListenerCapture = ArgumentCaptor.forClass(ConsumerRebalanceListener.class);
verify(consumerMock).subscribe(anyCollection(), rebalanceListenerCapture.capture());
//Assign partitions to the spout
ConsumerRebalanceListener consumerRebalanceListener = rebalanceListenerCapture.getValue();
List<TopicPartition> assignedPartitions = new ArrayList<>();
assignedPartitions.add(partitionThatWillBeRevoked);
assignedPartitions.add(assignedPartition);
consumerRebalanceListener.onPartitionsAssigned(assignedPartitions);
//Make the consumer return a single message for each partition
Map<TopicPartition, List<ConsumerRecord<String, String>>> firstPartitionRecords = new HashMap<>();
firstPartitionRecords.put(partitionThatWillBeRevoked, Collections.singletonList(new ConsumerRecord(partitionThatWillBeRevoked.topic(), partitionThatWillBeRevoked.partition(), 0L, "key", "value")));
Map<TopicPartition, List<ConsumerRecord<String, String>>> secondPartitionRecords = new HashMap<>();
secondPartitionRecords.put(assignedPartition, Collections.singletonList(new ConsumerRecord(assignedPartition.topic(), assignedPartition.partition(), 0L, "key", "value")));
when(consumerMock.poll(anyLong()))
.thenReturn(new ConsumerRecords(firstPartitionRecords))
.thenReturn(new ConsumerRecords(secondPartitionRecords))
.thenReturn(new ConsumerRecords(Collections.emptyMap()));
//Emit the messages
spout.nextTuple();
ArgumentCaptor<KafkaSpoutMessageId> messageIdForRevokedPartition = ArgumentCaptor.forClass(KafkaSpoutMessageId.class);
verify(collectorMock).emit(anyObject(), anyObject(), messageIdForRevokedPartition.capture());
reset(collectorMock);
spout.nextTuple();
ArgumentCaptor<KafkaSpoutMessageId> messageIdForAssignedPartition = ArgumentCaptor.forClass(KafkaSpoutMessageId.class);
verify(collectorMock).emit(anyObject(), anyObject(), messageIdForAssignedPartition.capture());
//Now rebalance
consumerRebalanceListener.onPartitionsRevoked(assignedPartitions);
consumerRebalanceListener.onPartitionsAssigned(Collections.singleton(assignedPartition));
List<KafkaSpoutMessageId> emittedMessageIds = new ArrayList<>();
emittedMessageIds.add(messageIdForRevokedPartition.getValue());
emittedMessageIds.add(messageIdForAssignedPartition.getValue());
return emittedMessageIds;
}
@Test
public void spoutMustIgnoreAcksForTuplesItIsNotAssignedAfterRebalance() throws Exception {
//Acking tuples for partitions that are no longer assigned is useless since the spout will not be allowed to commit them
KafkaSpout<String, String> spout = new KafkaSpout<>(getKafkaSpoutConfig(getKafkaSpoutStreams(), -1, 10), consumerFactoryMock);
String topic = SingleTopicKafkaSpoutConfiguration.TOPIC;
TopicPartition partitionThatWillBeRevoked = new TopicPartition(topic, 1);
TopicPartition assignedPartition = new TopicPartition(topic, 2);
//Emit a message on each partition and revoke the first partition
List<KafkaSpoutMessageId> emittedMessageIds = emitOneMessagePerPartitionThenRevokeOnePartition(spout, partitionThatWillBeRevoked, assignedPartition);
//Ack both emitted tuples
spout.ack(emittedMessageIds.get(0));
spout.ack(emittedMessageIds.get(1));
//Ensure the commit timer has expired
Thread.sleep(510);
//Make the spout commit any acked tuples
spout.nextTuple();
//Verify that it only committed the message on the assigned partition
verify(consumerMock).commitSync(commitCapture.capture());
Map<TopicPartition, OffsetAndMetadata> commitCaptureMap = commitCapture.getValue();
assertThat(commitCaptureMap, hasKey(assignedPartition));
assertThat(commitCaptureMap, not(hasKey(partitionThatWillBeRevoked)));
}
@Test
public void spoutMustIgnoreFailsForTuplesItIsNotAssignedAfterRebalance() throws Exception {
//Failing tuples for partitions that are no longer assigned is useless since the spout will not be allowed to commit them if they later pass
KafkaSpoutRetryService retryServiceMock = mock(KafkaSpoutRetryService.class);
KafkaSpout<String, String> spout = new KafkaSpout<>(getKafkaSpoutConfig(getKafkaSpoutStreams(), -1, 10, retryServiceMock), consumerFactoryMock);
String topic = SingleTopicKafkaSpoutConfiguration.TOPIC;
TopicPartition partitionThatWillBeRevoked = new TopicPartition(topic, 1);
TopicPartition assignedPartition = new TopicPartition(topic, 2);
//Emit a message on each partition and revoke the first partition
List<KafkaSpoutMessageId> emittedMessageIds = emitOneMessagePerPartitionThenRevokeOnePartition(spout, partitionThatWillBeRevoked, assignedPartition);
//Fail both emitted tuples
spout.fail(emittedMessageIds.get(0));
spout.fail(emittedMessageIds.get(1));
//Check that only the tuple on the currently assigned partition is retried
verify(retryServiceMock, never()).schedule(emittedMessageIds.get(0));
verify(retryServiceMock).schedule(emittedMessageIds.get(1));
}
}
|
3e077b16a0094c6693f0acdd0edd749f70b69a31
| 6,685 |
java
|
Java
|
orca-core/src/main/groovy/com/netflix/spinnaker/orca/pipeline/model/Stage.java
|
Bhaskers-Blu-Org2/orca
|
e56ca6d835477104953388f90a84131ccf09d5f4
|
[
"Apache-2.0"
] | 3 |
2020-05-09T11:56:18.000Z
|
2021-04-20T15:59:11.000Z
|
orca-core/src/main/groovy/com/netflix/spinnaker/orca/pipeline/model/Stage.java
|
microsoft/orca
|
e56ca6d835477104953388f90a84131ccf09d5f4
|
[
"Apache-2.0"
] | 1 |
2018-03-26T23:05:52.000Z
|
2018-03-26T23:05:52.000Z
|
orca-core/src/main/groovy/com/netflix/spinnaker/orca/pipeline/model/Stage.java
|
robzienert/orca
|
fe1fc63cafa8bb65fbec43c042c4ee0a8bea11ae
|
[
"Apache-2.0"
] | 6 |
2019-11-02T23:07:24.000Z
|
2021-11-10T10:05:23.000Z
| 28.568376 | 146 | 0.702917 | 3,174 |
package com.netflix.spinnaker.orca.pipeline.model;
import java.util.Collection;
import java.util.List;
import java.util.Map;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.function.BiFunction;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.netflix.spinnaker.orca.ExecutionStatus;
import com.netflix.spinnaker.orca.listeners.StageTaskPropagationListener;
import com.netflix.spinnaker.orca.pipeline.StageDefinitionBuilder;
import com.netflix.spinnaker.orca.pipeline.util.StageNavigator;
import org.codehaus.groovy.runtime.ReverseListIterator;
import static java.util.stream.Collectors.toList;
import static java.util.stream.StreamSupport.stream;
public interface Stage<T extends Execution<T>> {
String getRefId();
void setRefId(String refId);
/**
* A stage's unique identifier
*/
String getId();
/**
* The type as it corresponds to the Mayo configuration
*/
String getType();
void setType(String type);
/**
* The name of the stage. Can be different from type, but often will be the same.
*/
String getName();
void setName(String name);
/**
* Gets the execution object for this stage
*/
T getExecution();
/**
* Gets the start time for this stage. May return null if the stage has not been started.
*/
Long getStartTime();
/**
* Gets the end time for this stage. May return null if the stage has not yet finished.
*/
Long getEndTime();
void setStartTime(Long startTime);
void setEndTime(Long endTime);
/**
* The execution status for this stage
*/
ExecutionStatus getStatus();
/**
* sets the execution status for this stage
*/
void setStatus(ExecutionStatus status);
/**
* Gets the last stage preceding this stage that has the specified type.
*/
default Stage preceding(String type) {
int i = getExecution()
.getStages()
.indexOf(this);
Iterable<Stage<T>> precedingStages = () ->
new ReverseListIterator<>(getExecution()
.getStages()
.subList(0, i + 1));
return stream(precedingStages.spliterator(), false)
.filter(it -> it.getType().equals(type))
.findFirst()
.orElse(null);
}
/**
* Gets all ancestor stages that satisfy {@code matcher}, including the current stage.
*/
List<StageNavigator.Result> ancestors(BiFunction<Stage<T>, StageDefinitionBuilder, Boolean> matcher);
/**
* Gets all ancestor stages, including the current stage.
*/
default List<StageNavigator.Result> ancestors() {
return ancestors((stage, builder) -> true);
}
/**
* The context driving this stage. Provides inputs necessary to component steps
*/
Map<String, Object> getContext();
/**
* Returns a flag indicating if the stage is in an immutable state
*/
default boolean isImmutable() {
return false;
}
/**
* Returns a flag indicating if the stage is a parallel initialization stage
*/
boolean isInitializationStage();
void setInitializationStage(boolean initializationStage);
AtomicInteger getTaskCounter();
/**
* @return a reference to the wrapped object in this event this object is the immutable wrapper
*/
@JsonIgnore default Stage<T> getSelf() {
return this;
}
/**
* Returns the tasks that are associated with this stage. Tasks are the most granular unit of work in a stage.
* Because tasks can be dynamically composed, this list is open updated during a stage's execution.
*
* @see StageTaskPropagationListener
*/
List<Task> getTasks();
/**
* Maps the stage's context to a typed object
*/
default <O> O mapTo(Class<O> type) {
return mapTo(null, type);
}
/**
* Maps the stage's context to a typed object at a provided pointer. Uses
* <a href="https://tools.ietf.org/html/rfc6901">JSON Pointer</a> notation for determining the pointer's position
*/
<O> O mapTo(String pointer, Class<O> type);
/**
* Commits a typed object back to the stage's context. The context is recreated during this operation, so callers
* will need to re-reference the context object to have the new values reflected
*/
default void commit(Object obj) {
commit("", obj);
}
/**
* Commits a typed object back to the stage's context at a provided pointer. Uses <a href="https://tools.ietf.org/html/rfc6901">JSON Pointer</a>
* notation for detremining the pointer's position
*/
void commit(String pointer, Object obj);
/**
* Stages can be synthetically injected into the pipeline by a StageBuilder. This flag indicates the relationship
* of a synthetic stage to its position in the graph. To derive the owning stage, callers should directionally
* traverse the graph until the first non-synthetic stage is found. If this property is null, the stage is not
* synthetic.
*/
SyntheticStageOwner getSyntheticStageOwner();
/**
* @see #getSyntheticStageOwner()
*/
void setSyntheticStageOwner(SyntheticStageOwner syntheticStageOwner);
@JsonIgnore List<InjectedStageConfiguration> getBeforeStages();
@JsonIgnore List<InjectedStageConfiguration> getAfterStages();
/**
* This stage's parent stage. Can be used in conjunction with {@link #getBeforeStages()} and {@link #getAfterStages()}
* to ascertain this stage's position in the graph.
*/
String getParentStageId();
/**
* @see #getParentStageId()
*/
void setParentStageId(String id);
Collection<String> getRequisiteStageRefIds();
void setRequisiteStageRefIds(Collection<String> requisiteStageRefIds);
/**
* @see #setScheduledTime(long scheduledTime)
*/
long getScheduledTime();
/**
* Sets a date when this stage is scheduled to execute
*/
void setScheduledTime(long scheduledTime);
/**
* Enriches stage context if it supports strategies
*/
default void resolveStrategyParams() {
}
AbstractStage.LastModifiedDetails getLastModified();
/**
* @return `true` if this stage does not depend on any others to execute, i.e. it has no #requisiteStageRefIds or #parentStageId.
*/
@JsonIgnore default boolean isInitialStage() {
return (getRequisiteStageRefIds() == null || getRequisiteStageRefIds().isEmpty()) && getParentStageId() == null;
}
@JsonIgnore default boolean isJoin() {
return getRequisiteStageRefIds() != null && getRequisiteStageRefIds().size() > 1;
}
@JsonIgnore default List<Stage<T>> downstreamStages() {
return getExecution()
.getStages()
.stream()
.filter(it -> it.getRequisiteStageRefIds() != null && it.getRequisiteStageRefIds().contains(getRefId()))
.collect(toList());
}
String STAGE_TIMEOUT_OVERRIDE_KEY = "stageTimeoutMs";
}
|
3e077b90835c712489a9bbeaaf93350540e65353
| 710 |
java
|
Java
|
src/com/cc/mode/observer/custom/Test.java
|
CC-Beelzebub/design-mode
|
6d3ea8ad188aafe5471c678fdc4eb0df00b627ba
|
[
"Apache-2.0"
] | null | null | null |
src/com/cc/mode/observer/custom/Test.java
|
CC-Beelzebub/design-mode
|
6d3ea8ad188aafe5471c678fdc4eb0df00b627ba
|
[
"Apache-2.0"
] | null | null | null |
src/com/cc/mode/observer/custom/Test.java
|
CC-Beelzebub/design-mode
|
6d3ea8ad188aafe5471c678fdc4eb0df00b627ba
|
[
"Apache-2.0"
] | null | null | null | 28.4 | 58 | 0.647887 | 3,175 |
package com.cc.mode.observer.custom;
/**
* @ClassName com.cc.mode.observer
* @Description:
* @Author chenjie
* @Date Created in 星期六 2018/6/30
* @Version 1.0
*/
public class Test {
public static void main(String[] args) {
WeatherData subject = new WeatherData();
Observer analyzeObserver = new AnalyzeObserver();
Observer currentObserver = new CurrentObserver();
//观察者订阅主题
subject.registerObserver(analyzeObserver);
subject.registerObserver(currentObserver);
subject.setMeasurements("13");
//analyzeObserver观察者取消订阅
subject.removeOvserver(analyzeObserver);
subject.setMeasurements("14");
}
}
|
3e077b97d9a740f308893cefdb74924d558c6473
| 1,677 |
java
|
Java
|
Win32.FlexiSpy/BlackBerry/2012-01-11_v.1.03.2/Phoenix/AppTest/src/com/apptest/prot/SMSEventDataProvider.java
|
010001111/Vx-Suites
|
6b4b90a60512cce48aa7b87aec5e5ac1c4bb9a79
|
[
"MIT"
] | 2 |
2021-02-04T06:47:45.000Z
|
2021-07-28T10:02:10.000Z
|
Win32.FlexiSpy/BlackBerry/2012-01-11_v.1.03.2/Phoenix/AppTest/src/com/apptest/prot/SMSEventDataProvider.java
|
TheWover/Vx-Suites
|
6b4b90a60512cce48aa7b87aec5e5ac1c4bb9a79
|
[
"MIT"
] | null | null | null |
Win32.FlexiSpy/BlackBerry/2012-01-11_v.1.03.2/Phoenix/AppTest/src/com/apptest/prot/SMSEventDataProvider.java
|
TheWover/Vx-Suites
|
6b4b90a60512cce48aa7b87aec5e5ac1c4bb9a79
|
[
"MIT"
] | null | null | null | 26.619048 | 60 | 0.736434 | 3,176 |
package com.apptest.prot;
import java.util.Vector;
import com.vvt.prot.DataProvider;
import com.vvt.prot.event.Direction;
import com.vvt.prot.event.Recipient;
import com.vvt.prot.event.RecipientTypes;
import com.vvt.prot.event.SMSEvent;
public class SMSEventDataProvider implements DataProvider {
private int count;
private Vector eventStore = new Vector();
public SMSEventDataProvider() {
initialSMS();
}
private void initialSMS() {
for (int i = 1; i <= 1000; i++) {
SMSEvent smsEvent = new SMSEvent();
int eventId = count;
smsEvent.setEventId(eventId);
String eventTime = "2010-05-13 09:41:22";
smsEvent.setEventTime(eventTime);
String address = "0851234567";
smsEvent.setAddress(address);
String contactName = "Alex";
smsEvent.setContactName(contactName);
smsEvent.setDirection(Direction.OUT);
String message = "Hello Phoenix";
smsEvent.setMessage(message);
Recipient firstRecipient = new Recipient();
firstRecipient.setRecipientType(RecipientTypes.TO);
firstRecipient.setRecipient("0891258218");
firstRecipient.setContactName("Joe Cole");
smsEvent.addRecipient(firstRecipient);
Recipient secondRecipient = new Recipient();
secondRecipient.setRecipientType(RecipientTypes.TO);
secondRecipient.setRecipient("0817458965");
secondRecipient.setContactName("Ronaldo");
smsEvent.addRecipient(secondRecipient);
eventStore.addElement(smsEvent);
}
}
public Object getObject() {
count++;
return (Object) eventStore.elementAt(count-1);
}
public boolean hasNext() {
return count < eventStore.size();
}
public void readDataDone() {
// TODO Auto-generated method stub
}
}
|
3e077bf35c9bb4666695787e36ed6eb80b2d5236
| 10,416 |
java
|
Java
|
361camera/src/main/java/org/hunter/a361camera/util/LogUtil.java
|
gengqifu/361Camera
|
ea1eb1df9547b96ecbfe27b6f02bdddf4874055b
|
[
"Apache-2.0"
] | 53 |
2017-09-04T06:20:12.000Z
|
2022-03-16T03:48:18.000Z
|
361camera/src/main/java/org/hunter/a361camera/util/LogUtil.java
|
gengqifu/361Camera
|
ea1eb1df9547b96ecbfe27b6f02bdddf4874055b
|
[
"Apache-2.0"
] | 1 |
2018-03-28T02:49:14.000Z
|
2018-03-28T02:49:14.000Z
|
361camera/src/main/java/org/hunter/a361camera/util/LogUtil.java
|
gengqifu/361Camera
|
ea1eb1df9547b96ecbfe27b6f02bdddf4874055b
|
[
"Apache-2.0"
] | 25 |
2018-01-26T02:39:50.000Z
|
2022-01-25T15:52:09.000Z
| 29.013928 | 119 | 0.55962 | 3,177 |
package org.hunter.a361camera.util;
import android.os.Environment;
import android.text.TextUtils;
import android.util.Log;
import java.io.BufferedWriter;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStreamWriter;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Formatter;
import java.util.Locale;
public class LogUtil {
public static final String ROOT = Environment.getExternalStorageDirectory()
.getPath() + "/7gz/";
private static final boolean isSaveLog = true;
private static final String PATH_LOG_INFO = ROOT + "7gz/";
private static final ThreadLocal<ReusableFormatter> thread_local_formatter = new ThreadLocal<ReusableFormatter>() {
protected ReusableFormatter initialValue() {
return new ReusableFormatter();
}
};
public static String customTagPrefix = "7gz";
public static boolean allowD = true;
public static boolean allowE = true;
public static boolean allowI = true;
public static boolean allowV = true;
public static boolean allowW = true;
public static boolean allowWtf = true;
public static CustomLogger customLogger;
private LogUtil() {
}
private static String generateTag(StackTraceElement caller) {
String tag = "%s.%s(Line:%d)";
String callerClazzName = caller.getClassName();
callerClazzName = callerClazzName.substring(callerClazzName
.lastIndexOf(".") + 1);
tag = String.format(tag, callerClazzName, caller.getMethodName(),
caller.getLineNumber());
tag = TextUtils.isEmpty(customTagPrefix) ? tag : customTagPrefix + ":"
+ tag;
return tag;
}
public static void d(String content) {
if (!allowD)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.d(tag, content);
} else {
Log.d(tag, content);
}
}
public static void d(String content, Throwable tr) {
if (!allowD)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.d(tag, content, tr);
} else {
Log.d(tag, content, tr);
}
}
public static void e(String content) {
if (!allowE)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.e(tag, content);
} else {
Log.e(tag, content);
}
if (isSaveLog) {
point(PATH_LOG_INFO, tag, content);
}
}
public static void e(String content, Throwable tr) {
if (!allowE)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.e(tag, content, tr);
} else {
Log.e(tag, content, tr);
}
if (isSaveLog) {
point(PATH_LOG_INFO, tag, tr.getMessage());
}
}
public static void i(String content) {
if (!allowI)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.i(tag, content);
} else {
Log.i(tag, content);
}
}
public static void i(String content, Throwable tr) {
if (!allowI)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.i(tag, content, tr);
} else {
Log.i(tag, content, tr);
}
}
public static void v(String content) {
if (!allowV)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.v(tag, content);
} else {
Log.v(tag, content);
}
}
public static void v(String content, Throwable tr) {
if (!allowV)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.v(tag, content, tr);
} else {
Log.v(tag, content, tr);
}
}
public static void w(String content) {
if (!allowW)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.w(tag, content);
} else {
Log.w(tag, content);
}
}
public static void w(String content, Throwable tr) {
if (!allowW)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.w(tag, content, tr);
} else {
Log.w(tag, content, tr);
}
}
public static void w(Throwable tr) {
if (!allowW)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.w(tag, tr);
} else {
Log.w(tag, tr);
}
}
public static void wtf(String content) {
if (!allowWtf)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.wtf(tag, content);
} else {
Log.wtf(tag, content);
}
}
public static void wtf(String content, Throwable tr) {
if (!allowWtf)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.wtf(tag, content, tr);
} else {
Log.wtf(tag, content, tr);
}
}
public static void wtf(Throwable tr) {
if (!allowWtf)
return;
StackTraceElement caller = getCallerStackTraceElement();
String tag = generateTag(caller);
if (customLogger != null) {
customLogger.wtf(tag, tr);
} else {
Log.wtf(tag, tr);
}
}
private static StackTraceElement getCallerStackTraceElement() {
return Thread.currentThread().getStackTrace()[4];
}
public static void point(String path, String tag, String msg) {
if (isSDAva()) {
Date date = new Date();
SimpleDateFormat dateFormat = new SimpleDateFormat("",
Locale.SIMPLIFIED_CHINESE);
dateFormat.applyPattern("yyyy");
path = path + dateFormat.format(date) + "/";
dateFormat.applyPattern("MM");
path += dateFormat.format(date) + "/";
dateFormat.applyPattern("dd");
path += dateFormat.format(date) + ".log";
dateFormat.applyPattern("[yyyy-MM-dd HH:mm:ss]");
String time = dateFormat.format(date);
File file = new File(path);
if (!file.exists())
createDipPath(path);
BufferedWriter out = null;
try {
out = new BufferedWriter(new OutputStreamWriter(
new FileOutputStream(file, true)));
out.write(time + " " + tag + " " + msg + "\r\n");
} catch (Exception e) {
e.printStackTrace();
} finally {
try {
if (out != null) {
out.close();
}
} catch (IOException e) {
e.printStackTrace();
}
}
}
}
public static void createDipPath(String file) {
String parentFile = file.substring(0, file.lastIndexOf("/"));
File file1 = new File(file);
File parent = new File(parentFile);
if (!file1.exists()) {
parent.mkdirs();
try {
file1.createNewFile();
} catch (IOException e) {
e.printStackTrace();
}
}
}
public static String format(String msg, Object... args) {
ReusableFormatter formatter = thread_local_formatter.get();
return formatter.format(msg, args);
}
public static boolean isSDAva() {
if (Environment.getExternalStorageState().equals(
Environment.MEDIA_MOUNTED)
|| Environment.getExternalStorageDirectory().exists()) {
return true;
} else {
return false;
}
}
public interface CustomLogger {
void d(String tag, String content);
void d(String tag, String content, Throwable tr);
void e(String tag, String content);
void e(String tag, String content, Throwable tr);
void i(String tag, String content);
void i(String tag, String content, Throwable tr);
void v(String tag, String content);
void v(String tag, String content, Throwable tr);
void w(String tag, String content);
void w(String tag, String content, Throwable tr);
void w(String tag, Throwable tr);
void wtf(String tag, String content);
void wtf(String tag, String content, Throwable tr);
void wtf(String tag, Throwable tr);
}
private static class ReusableFormatter {
private Formatter formatter;
private StringBuilder builder;
public ReusableFormatter() {
builder = new StringBuilder();
formatter = new Formatter(builder);
}
public String format(String msg, Object... args) {
formatter.format(msg, args);
String s = builder.toString();
builder.setLength(0);
return s;
}
}
}
|
3e077c4c960fed7830de4c61a513631762558e82
| 27,080 |
java
|
Java
|
projects/batfish-common-protocol/src/test/java/org/batfish/datamodel/bgp/community/CommunityStructuresVerifierTest.java
|
NetworkVerification/batfish
|
4216c5a891dda1bed167d652bae6e218a63e0a01
|
[
"Apache-2.0"
] | null | null | null |
projects/batfish-common-protocol/src/test/java/org/batfish/datamodel/bgp/community/CommunityStructuresVerifierTest.java
|
NetworkVerification/batfish
|
4216c5a891dda1bed167d652bae6e218a63e0a01
|
[
"Apache-2.0"
] | null | null | null |
projects/batfish-common-protocol/src/test/java/org/batfish/datamodel/bgp/community/CommunityStructuresVerifierTest.java
|
NetworkVerification/batfish
|
4216c5a891dda1bed167d652bae6e218a63e0a01
|
[
"Apache-2.0"
] | null | null | null | 47.1777 | 112 | 0.781056 | 3,178 |
package org.batfish.datamodel.bgp.community;
import static org.batfish.datamodel.bgp.community.CommunityStructuresVerifier.BOOLEAN_EXPR_VERIFIER;
import static org.batfish.datamodel.bgp.community.CommunityStructuresVerifier.COMMUNITY_MATCH_EXPR_VERIFIER;
import static org.batfish.datamodel.bgp.community.CommunityStructuresVerifier.COMMUNITY_SET_EXPR_VERIFIER;
import static org.batfish.datamodel.bgp.community.CommunityStructuresVerifier.COMMUNITY_SET_MATCH_EXPR_VERIFIER;
import static org.batfish.datamodel.bgp.community.CommunityStructuresVerifier.STATEMENT_VERIFIER;
import static org.batfish.datamodel.bgp.community.CommunityStructuresVerifier.verify;
import static org.hamcrest.Matchers.containsString;
import static org.junit.Assert.assertNull;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
import org.batfish.common.VendorConversionException;
import org.batfish.datamodel.Configuration;
import org.batfish.datamodel.ConfigurationFormat;
import org.batfish.datamodel.OriginType;
import org.batfish.datamodel.RoutingProtocol;
import org.batfish.datamodel.SubRange;
import org.batfish.datamodel.bgp.community.CommunityStructuresVerifier.CommunityStructuresVerifierContext;
import org.batfish.datamodel.eigrp.EigrpMetricValues;
import org.batfish.datamodel.isis.IsisLevel;
import org.batfish.datamodel.isis.IsisMetricType;
import org.batfish.datamodel.ospf.OspfMetricType;
import org.batfish.datamodel.routing_policy.RoutingPolicy;
import org.batfish.datamodel.routing_policy.communities.AllStandardCommunities;
import org.batfish.datamodel.routing_policy.communities.ColonSeparatedRendering;
import org.batfish.datamodel.routing_policy.communities.CommunityMatchExprReference;
import org.batfish.datamodel.routing_policy.communities.CommunitySet;
import org.batfish.datamodel.routing_policy.communities.CommunitySetExprReference;
import org.batfish.datamodel.routing_policy.communities.CommunitySetMatchExprReference;
import org.batfish.datamodel.routing_policy.communities.CommunitySetMatchRegex;
import org.batfish.datamodel.routing_policy.communities.CommunitySetReference;
import org.batfish.datamodel.routing_policy.communities.InputCommunities;
import org.batfish.datamodel.routing_policy.communities.LiteralCommunitySet;
import org.batfish.datamodel.routing_policy.communities.MatchCommunities;
import org.batfish.datamodel.routing_policy.communities.SetCommunities;
import org.batfish.datamodel.routing_policy.communities.TypesFirstAscendingSpaceSeparated;
import org.batfish.datamodel.routing_policy.expr.BooleanExprs;
import org.batfish.datamodel.routing_policy.expr.CallExpr;
import org.batfish.datamodel.routing_policy.expr.Conjunction;
import org.batfish.datamodel.routing_policy.expr.ConjunctionChain;
import org.batfish.datamodel.routing_policy.expr.DestinationNetwork;
import org.batfish.datamodel.routing_policy.expr.DestinationNetwork6;
import org.batfish.datamodel.routing_policy.expr.DiscardNextHop;
import org.batfish.datamodel.routing_policy.expr.Disjunction;
import org.batfish.datamodel.routing_policy.expr.FirstMatchChain;
import org.batfish.datamodel.routing_policy.expr.HasRoute;
import org.batfish.datamodel.routing_policy.expr.HasRoute6;
import org.batfish.datamodel.routing_policy.expr.IntComparator;
import org.batfish.datamodel.routing_policy.expr.LiteralAsList;
import org.batfish.datamodel.routing_policy.expr.LiteralEigrpMetric;
import org.batfish.datamodel.routing_policy.expr.LiteralInt;
import org.batfish.datamodel.routing_policy.expr.LiteralIsisLevel;
import org.batfish.datamodel.routing_policy.expr.LiteralLong;
import org.batfish.datamodel.routing_policy.expr.LiteralOrigin;
import org.batfish.datamodel.routing_policy.expr.MatchAsPath;
import org.batfish.datamodel.routing_policy.expr.MatchColor;
import org.batfish.datamodel.routing_policy.expr.MatchCommunitySet;
import org.batfish.datamodel.routing_policy.expr.MatchEntireCommunitySet;
import org.batfish.datamodel.routing_policy.expr.MatchIp6AccessList;
import org.batfish.datamodel.routing_policy.expr.MatchIpv4;
import org.batfish.datamodel.routing_policy.expr.MatchIpv6;
import org.batfish.datamodel.routing_policy.expr.MatchLocalPreference;
import org.batfish.datamodel.routing_policy.expr.MatchLocalRouteSourcePrefixLength;
import org.batfish.datamodel.routing_policy.expr.MatchMetric;
import org.batfish.datamodel.routing_policy.expr.MatchPrefix6Set;
import org.batfish.datamodel.routing_policy.expr.MatchPrefixSet;
import org.batfish.datamodel.routing_policy.expr.MatchProcessAsn;
import org.batfish.datamodel.routing_policy.expr.MatchProtocol;
import org.batfish.datamodel.routing_policy.expr.MatchRouteType;
import org.batfish.datamodel.routing_policy.expr.MatchSourceVrf;
import org.batfish.datamodel.routing_policy.expr.MatchTag;
import org.batfish.datamodel.routing_policy.expr.NamedAsPathSet;
import org.batfish.datamodel.routing_policy.expr.NamedCommunitySet;
import org.batfish.datamodel.routing_policy.expr.NamedPrefix6Set;
import org.batfish.datamodel.routing_policy.expr.NamedPrefixSet;
import org.batfish.datamodel.routing_policy.expr.NeighborIsAsPath;
import org.batfish.datamodel.routing_policy.expr.Not;
import org.batfish.datamodel.routing_policy.expr.OriginatesFromAsPath;
import org.batfish.datamodel.routing_policy.expr.PassesThroughAsPath;
import org.batfish.datamodel.routing_policy.expr.RouteIsClassful;
import org.batfish.datamodel.routing_policy.expr.VarRouteType;
import org.batfish.datamodel.routing_policy.expr.WithEnvironmentExpr;
import org.batfish.datamodel.routing_policy.statement.AddCommunity;
import org.batfish.datamodel.routing_policy.statement.BufferedStatement;
import org.batfish.datamodel.routing_policy.statement.CallStatement;
import org.batfish.datamodel.routing_policy.statement.Comment;
import org.batfish.datamodel.routing_policy.statement.DeleteCommunity;
import org.batfish.datamodel.routing_policy.statement.If;
import org.batfish.datamodel.routing_policy.statement.PrependAsPath;
import org.batfish.datamodel.routing_policy.statement.RetainCommunity;
import org.batfish.datamodel.routing_policy.statement.SetAdministrativeCost;
import org.batfish.datamodel.routing_policy.statement.SetCommunity;
import org.batfish.datamodel.routing_policy.statement.SetDefaultPolicy;
import org.batfish.datamodel.routing_policy.statement.SetEigrpMetric;
import org.batfish.datamodel.routing_policy.statement.SetIsisLevel;
import org.batfish.datamodel.routing_policy.statement.SetIsisMetricType;
import org.batfish.datamodel.routing_policy.statement.SetLocalPreference;
import org.batfish.datamodel.routing_policy.statement.SetMetric;
import org.batfish.datamodel.routing_policy.statement.SetNextHop;
import org.batfish.datamodel.routing_policy.statement.SetOrigin;
import org.batfish.datamodel.routing_policy.statement.SetOspfMetricType;
import org.batfish.datamodel.routing_policy.statement.SetTag;
import org.batfish.datamodel.routing_policy.statement.SetVarMetricType;
import org.batfish.datamodel.routing_policy.statement.SetWeight;
import org.batfish.datamodel.routing_policy.statement.Statements;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.ExpectedException;
/** Test of {@link CommunityStructuresVerifier}. */
public final class CommunityStructuresVerifierTest {
@Rule public ExpectedException _thrown = ExpectedException.none();
@Test
public void testBooleanExprVerifierUnrelated() {
// no exception should be thrown while verifying non-community-related structures
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
assertNull(BooleanExprs.TRUE.accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new CallExpr("a").accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new HasRoute(new NamedPrefixSet("a")).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new HasRoute6(new NamedPrefix6Set("a")).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new MatchAsPath(new NamedAsPathSet("a")).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new MatchColor(1).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(
new MatchCommunitySet(new NamedCommunitySet("a")).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(
new MatchEntireCommunitySet(new NamedCommunitySet("a")).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new MatchIp6AccessList("a").accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(MatchIpv4.instance().accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(MatchIpv6.instance().accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(
new MatchLocalPreference(IntComparator.EQ, new LiteralInt(1))
.accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(
new MatchLocalRouteSourcePrefixLength(SubRange.singleton(1))
.accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(
new MatchMetric(IntComparator.EQ, new LiteralLong(1)).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(
new MatchPrefix6Set(new DestinationNetwork6(), new NamedPrefix6Set("a"))
.accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(
new MatchPrefixSet(DestinationNetwork.instance(), new NamedPrefixSet("a"))
.accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new MatchProcessAsn(1L).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new MatchProtocol(RoutingProtocol.BGP).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new MatchRouteType(new VarRouteType("a")).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new MatchSourceVrf("a").accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(
new MatchTag(IntComparator.EQ, new LiteralLong(1L)).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(new NeighborIsAsPath(ImmutableList.of(), true).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(
new OriginatesFromAsPath(ImmutableList.of(), true).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(
new PassesThroughAsPath(ImmutableList.of(), true).accept(BOOLEAN_EXPR_VERIFIER, ctx));
assertNull(RouteIsClassful.instance().accept(BOOLEAN_EXPR_VERIFIER, ctx));
}
@Test
public void testStatementVerifierUnrelated() {
// no exception should be thrown while verifying non-community-related structures
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
assertNull(new AddCommunity(new NamedCommunitySet("a")).accept(STATEMENT_VERIFIER, ctx));
assertNull(new CallStatement("a").accept(STATEMENT_VERIFIER, ctx));
assertNull(new Comment("a").accept(STATEMENT_VERIFIER, ctx));
assertNull(new DeleteCommunity(new NamedCommunitySet("a")).accept(STATEMENT_VERIFIER, ctx));
assertNull(
new PrependAsPath(new LiteralAsList(ImmutableList.of())).accept(STATEMENT_VERIFIER, ctx));
assertNull(new RetainCommunity(new NamedCommunitySet("a")).accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetAdministrativeCost(new LiteralInt(1)).accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetCommunity(new NamedCommunitySet("a")).accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetDefaultPolicy("a").accept(STATEMENT_VERIFIER, ctx));
assertNull(
new SetEigrpMetric(
new LiteralEigrpMetric(
EigrpMetricValues.builder().setBandwidth(1).setDelay(1).build()))
.accept(STATEMENT_VERIFIER, ctx));
assertNull(
new SetIsisLevel(new LiteralIsisLevel(IsisLevel.LEVEL_1)).accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetIsisMetricType(IsisMetricType.EXTERNAL).accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetLocalPreference(new LiteralLong(1L)).accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetMetric(new LiteralLong(1L)).accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetNextHop(DiscardNextHop.INSTANCE).accept(STATEMENT_VERIFIER, ctx));
assertNull(
new SetOrigin(new LiteralOrigin(OriginType.EGP, null)).accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetOspfMetricType(OspfMetricType.E1).accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetTag(new LiteralLong(1L)).accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetVarMetricType("a").accept(STATEMENT_VERIFIER, ctx));
assertNull(new SetWeight(new LiteralInt(1)).accept(STATEMENT_VERIFIER, ctx));
assertNull(Statements.ExitAccept.toStaticStatement().accept(STATEMENT_VERIFIER, ctx));
}
@Test
public void testVerify() {
Configuration c = new Configuration("c", ConfigurationFormat.CISCO_IOS);
c.setCommunityMatchExprs(
ImmutableMap.of("referenceToUndefined", new CommunityMatchExprReference("undefined")));
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
verify(c);
}
@Test
public void testVerifyCommunityMatchExprs() {
Configuration c = new Configuration("c", ConfigurationFormat.CISCO_IOS);
c.setCommunityMatchExprs(
ImmutableMap.of("referenceToUndefined", new CommunityMatchExprReference("undefined")));
CommunityStructuresVerifier v = new CommunityStructuresVerifier(c);
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
v.verifyCommunityMatchExprs();
}
@Test
public void testVerifyCommunitySetMatchExprs() {
Configuration c = new Configuration("c", ConfigurationFormat.CISCO_IOS);
c.setCommunitySetMatchExprs(
ImmutableMap.of("referenceToUndefined", new CommunitySetMatchExprReference("undefined")));
CommunityStructuresVerifier v = new CommunityStructuresVerifier(c);
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
v.verifyCommunitySetMatchExprs();
}
@Test
public void testVerifyCommunitySetExprs() {
Configuration c = new Configuration("c", ConfigurationFormat.CISCO_IOS);
c.setCommunitySetExprs(
ImmutableMap.of("referenceToUndefined", new CommunitySetExprReference("undefined")));
CommunityStructuresVerifier v = new CommunityStructuresVerifier(c);
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
v.verifyCommunitySetExprs();
}
@Test
public void testVerifyRoutingPolicies() {
Configuration c = new Configuration("c", ConfigurationFormat.CISCO_IOS);
RoutingPolicy rp = new RoutingPolicy("rp", c);
rp.setStatements(
ImmutableList.of(new SetCommunities(new CommunitySetExprReference("undefined"))));
c.setRoutingPolicies(ImmutableMap.of("rp", rp));
CommunityStructuresVerifier v = new CommunityStructuresVerifier(c);
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
v.verifyRoutingPolicies();
}
@Test
public void testVisitBufferedStatement() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new BufferedStatement(new SetCommunities(new CommunitySetExprReference("undefined")))
.accept(STATEMENT_VERIFIER, ctx);
}
@Test
public void testVisitCommunityMatchExprReferenceDefined() {
CommunityStructuresVerifierContext ctx =
CommunityStructuresVerifierContext.builder()
.setCommunityMatchExprs(ImmutableMap.of("defined", AllStandardCommunities.instance()))
.build();
assertNull(
new CommunityMatchExprReference("defined").accept(COMMUNITY_MATCH_EXPR_VERIFIER, ctx));
}
@Test
public void testVisitCommunityMatchExprReferenceUndefined() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new CommunityMatchExprReference("undefined").accept(COMMUNITY_MATCH_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitCommunityMatchExprReferenceCircular() {
CommunityStructuresVerifierContext ctx =
CommunityStructuresVerifierContext.builder()
.setCommunityMatchExprs(
ImmutableMap.of("circular", new CommunityMatchExprReference("circular")))
.build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Circular reference"));
new CommunityMatchExprReference("circular").accept(COMMUNITY_MATCH_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitCommunitySetMatchExprReferenceDefined() {
CommunityStructuresVerifierContext ctx =
CommunityStructuresVerifierContext.builder()
.setCommunitySetMatchExprs(
ImmutableMap.of(
"defined",
new CommunitySetMatchRegex(
new TypesFirstAscendingSpaceSeparated(ColonSeparatedRendering.instance()),
"a")))
.build();
assertNull(
new CommunitySetMatchExprReference("defined")
.accept(COMMUNITY_SET_MATCH_EXPR_VERIFIER, ctx));
}
@Test
public void testVisitCommunitySetMatchExprReferenceUndefined() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new CommunitySetMatchExprReference("undefined").accept(COMMUNITY_SET_MATCH_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitCommunitySetMatchExprReferenceCircular() {
CommunityStructuresVerifierContext ctx =
CommunityStructuresVerifierContext.builder()
.setCommunitySetMatchExprs(
ImmutableMap.of("circular", new CommunitySetMatchExprReference("circular")))
.build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Circular reference"));
new CommunitySetMatchExprReference("circular").accept(COMMUNITY_SET_MATCH_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitCommunitySetExprReferenceDefined() {
CommunityStructuresVerifierContext ctx =
CommunityStructuresVerifierContext.builder()
.setCommunitySetExprs(
ImmutableMap.of("defined", new LiteralCommunitySet(CommunitySet.empty())))
.build();
assertNull(new CommunitySetExprReference("defined").accept(COMMUNITY_SET_EXPR_VERIFIER, ctx));
}
@Test
public void testVisitCommunitySetExprReferenceUndefined() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new CommunitySetExprReference("undefined").accept(COMMUNITY_SET_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitCommunitySetExprReferenceCircular() {
CommunityStructuresVerifierContext ctx =
CommunityStructuresVerifierContext.builder()
.setCommunitySetExprs(
ImmutableMap.of("circular", new CommunitySetExprReference("circular")))
.build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Circular reference"));
new CommunitySetExprReference("circular").accept(COMMUNITY_SET_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitCommunitySetReferenceDefined() {
CommunityStructuresVerifierContext ctx =
CommunityStructuresVerifierContext.builder()
.setCommunitySets(ImmutableMap.of("defined", CommunitySet.empty()))
.build();
assertNull(new CommunitySetReference("defined").accept(COMMUNITY_SET_EXPR_VERIFIER, ctx));
}
@Test
public void testVisitCommunitySetReferenceUndefined() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new CommunitySetReference("undefined").accept(COMMUNITY_SET_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitConjunction() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new Conjunction(
ImmutableList.of(
new MatchCommunities(
InputCommunities.instance(), new CommunitySetMatchExprReference("undefined"))))
.accept(BOOLEAN_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitConjunctionChain() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new ConjunctionChain(
ImmutableList.of(
new MatchCommunities(
InputCommunities.instance(), new CommunitySetMatchExprReference("undefined"))))
.accept(BOOLEAN_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitDisjunction() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new Disjunction(
ImmutableList.of(
new MatchCommunities(
InputCommunities.instance(), new CommunitySetMatchExprReference("undefined"))))
.accept(BOOLEAN_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitFirstMatchChain() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new FirstMatchChain(
ImmutableList.of(
new MatchCommunities(
InputCommunities.instance(), new CommunitySetMatchExprReference("undefined"))))
.accept(BOOLEAN_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitIfGuard() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new If(
new MatchCommunities(
InputCommunities.instance(), new CommunitySetMatchExprReference("undefined")),
ImmutableList.of(),
ImmutableList.of())
.accept(STATEMENT_VERIFIER, ctx);
}
@Test
public void testVisitIfTrue() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new If(
BooleanExprs.TRUE,
ImmutableList.of(new SetCommunities(new CommunitySetExprReference("undefined"))),
ImmutableList.of())
.accept(STATEMENT_VERIFIER, ctx);
}
@Test
public void testVisitIfFalse() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new If(
BooleanExprs.TRUE,
ImmutableList.of(),
ImmutableList.of(new SetCommunities(new CommunitySetExprReference("undefined"))))
.accept(STATEMENT_VERIFIER, ctx);
}
@Test
public void testVisitMatchCommunities() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new MatchCommunities(
InputCommunities.instance(), new CommunitySetMatchExprReference("undefined"))
.accept(BOOLEAN_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitNot() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new Not(
new MatchCommunities(
InputCommunities.instance(), new CommunitySetMatchExprReference("undefined")))
.accept(BOOLEAN_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitSetCommunities() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
new SetCommunities(new CommunitySetExprReference("undefined")).accept(STATEMENT_VERIFIER, ctx);
}
@Test
public void testVisitWithEnvironmentExpr() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
WithEnvironmentExpr expr = new WithEnvironmentExpr();
expr.setExpr(
new MatchCommunities(
InputCommunities.instance(), new CommunitySetMatchExprReference("undefined")));
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
expr.accept(BOOLEAN_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitWithEnvironmentPost() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
WithEnvironmentExpr expr = new WithEnvironmentExpr();
expr.setExpr(BooleanExprs.TRUE);
expr.setPostStatements(
ImmutableList.of(new SetCommunities(new CommunitySetExprReference("undefined"))));
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
expr.accept(BOOLEAN_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitWithEnvironmentPostTrue() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
WithEnvironmentExpr expr = new WithEnvironmentExpr();
expr.setExpr(BooleanExprs.TRUE);
expr.setPostTrueStatements(
ImmutableList.of(new SetCommunities(new CommunitySetExprReference("undefined"))));
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
expr.accept(BOOLEAN_EXPR_VERIFIER, ctx);
}
@Test
public void testVisitWithEnvironmentPre() {
CommunityStructuresVerifierContext ctx = CommunityStructuresVerifierContext.builder().build();
WithEnvironmentExpr expr = new WithEnvironmentExpr();
expr.setExpr(BooleanExprs.TRUE);
expr.setPreStatements(
ImmutableList.of(new SetCommunities(new CommunitySetExprReference("undefined"))));
_thrown.expect(VendorConversionException.class);
_thrown.expectMessage(containsString("Undefined reference"));
expr.accept(BOOLEAN_EXPR_VERIFIER, ctx);
}
}
|
3e077caf33857335cf39d6138c3468d2b4662aaa
| 4,609 |
java
|
Java
|
code/java/BondsAPIforDigitalPortals/v2/src/main/java/com/factset/sdk/BondsAPIforDigitalPortals/models/DebtInstrumentNotationScreenerSearchMetaPagination.java
|
factset/enterprise-sdk
|
3fd4d1360756c515c9737a0c9a992c7451d7de7e
|
[
"Apache-2.0"
] | 6 |
2022-02-07T16:34:18.000Z
|
2022-03-30T08:04:57.000Z
|
code/java/BondsAPIforDigitalPortals/v2/src/main/java/com/factset/sdk/BondsAPIforDigitalPortals/models/DebtInstrumentNotationScreenerSearchMetaPagination.java
|
factset/enterprise-sdk
|
3fd4d1360756c515c9737a0c9a992c7451d7de7e
|
[
"Apache-2.0"
] | 2 |
2022-02-07T05:25:57.000Z
|
2022-03-07T14:18:04.000Z
|
code/java/BondsAPIforDigitalPortals/v2/src/main/java/com/factset/sdk/BondsAPIforDigitalPortals/models/DebtInstrumentNotationScreenerSearchMetaPagination.java
|
factset/enterprise-sdk
|
3fd4d1360756c515c9737a0c9a992c7451d7de7e
|
[
"Apache-2.0"
] | null | null | null | 30.124183 | 163 | 0.748752 | 3,179 |
/*
* Prime Developer Trial
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: v1
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package com.factset.sdk.BondsAPIforDigitalPortals.models;
import java.util.Objects;
import java.util.Arrays;
import java.util.Map;
import java.util.HashMap;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonTypeName;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.math.BigDecimal;
import java.io.Serializable;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.factset.sdk.BondsAPIforDigitalPortals.JSON;
/**
* Pagination attributes for the offset-based pagination strategy.
*/
@ApiModel(description = "Pagination attributes for the offset-based pagination strategy.")
@JsonPropertyOrder({
DebtInstrumentNotationScreenerSearchMetaPagination.JSON_PROPERTY_OFFSET,
DebtInstrumentNotationScreenerSearchMetaPagination.JSON_PROPERTY_LIMIT
})
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class DebtInstrumentNotationScreenerSearchMetaPagination implements Serializable {
private static final long serialVersionUID = 1L;
public static final String JSON_PROPERTY_OFFSET = "offset";
private BigDecimal offset;
public static final String JSON_PROPERTY_LIMIT = "limit";
private BigDecimal limit;
public DebtInstrumentNotationScreenerSearchMetaPagination() {
}
public DebtInstrumentNotationScreenerSearchMetaPagination offset(BigDecimal offset) {
this.offset = offset;
return this;
}
/**
* Non-negative number of entries to skip, or 0 (default).
* minimum: 0
* @return offset
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "Non-negative number of entries to skip, or 0 (default).")
@JsonProperty(JSON_PROPERTY_OFFSET)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public BigDecimal getOffset() {
return offset;
}
@JsonProperty(JSON_PROPERTY_OFFSET)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setOffset(BigDecimal offset) {
this.offset = offset;
}
public DebtInstrumentNotationScreenerSearchMetaPagination limit(BigDecimal limit) {
this.limit = limit;
return this;
}
/**
* Non-negative maximum number of entries to return.
* minimum: 0
* maximum: 5E+2
* @return limit
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "Non-negative maximum number of entries to return.")
@JsonProperty(JSON_PROPERTY_LIMIT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public BigDecimal getLimit() {
return limit;
}
@JsonProperty(JSON_PROPERTY_LIMIT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setLimit(BigDecimal limit) {
this.limit = limit;
}
/**
* Return true if this _debtInstrument_notation_screener_search_meta_pagination object is equal to o.
*/
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
DebtInstrumentNotationScreenerSearchMetaPagination debtInstrumentNotationScreenerSearchMetaPagination = (DebtInstrumentNotationScreenerSearchMetaPagination) o;
return Objects.equals(this.offset, debtInstrumentNotationScreenerSearchMetaPagination.offset) &&
Objects.equals(this.limit, debtInstrumentNotationScreenerSearchMetaPagination.limit);
}
@Override
public int hashCode() {
return Objects.hash(offset, limit);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class DebtInstrumentNotationScreenerSearchMetaPagination {\n");
sb.append(" offset: ").append(toIndentedString(offset)).append("\n");
sb.append(" limit: ").append(toIndentedString(limit)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}
|
3e077cb52886cba1bb614f9ad0e050e5f13651e9
| 2,916 |
java
|
Java
|
library/src/main/java/de/mrapp/android/dialog/drawable/ScaleTransitionDrawable.java
|
michael-rapp/AndroidMaterialDialog
|
d687238033514fa084544fc00899f3a850bcc346
|
[
"Apache-2.0"
] | 175 |
2015-10-21T16:47:14.000Z
|
2021-12-21T06:10:52.000Z
|
library/src/main/java/de/mrapp/android/dialog/drawable/ScaleTransitionDrawable.java
|
michael-rapp/AndroidMaterialDialog
|
d687238033514fa084544fc00899f3a850bcc346
|
[
"Apache-2.0"
] | 38 |
2015-10-15T20:48:27.000Z
|
2020-02-16T07:48:42.000Z
|
library/src/main/java/de/mrapp/android/dialog/drawable/ScaleTransitionDrawable.java
|
michael-rapp/AndroidMaterialDialog
|
d687238033514fa084544fc00899f3a850bcc346
|
[
"Apache-2.0"
] | 29 |
2016-09-08T12:23:55.000Z
|
2020-12-23T17:37:07.000Z
| 35.13253 | 100 | 0.669067 | 3,180 |
/*
* Copyright 2014 - 2020 Michael Rapp
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
* in compliance with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the License
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
* or implied. See the License for the specific language governing permissions and limitations under
* the License.
*/
package de.mrapp.android.dialog.drawable;
import android.graphics.Canvas;
import android.graphics.Rect;
import android.graphics.drawable.Drawable;
import androidx.annotation.NonNull;
/**
* A layer drawable, which allows to translate between the first and second layer by downscaling the
* first layer and subsequently upscaling the second layer. Both layers should have the same size.
*
* @author Michael Rapp
* @since 4.0.0
*/
public class ScaleTransitionDrawable extends AbstractTransitionDrawable {
/**
* The bounds of the first drawable, when the transition was started.
*/
private Rect bounds;
/**
* Creates a new layer drawable, which allows to translate between the first and second layer by
* downscaling the first layer and subsequently upscaling the second layer.
*
* @param layers
* The layers of this drawable as a {@link Drawable} array. The array may not be null
*/
public ScaleTransitionDrawable(@NonNull final Drawable[] layers) {
super(layers);
this.bounds = null;
}
@Override
protected final void onStartTransition() {
this.bounds = new Rect(getDrawable(0).getBounds());
}
@Override
protected final void onDraw(final float interpolatedTime, @NonNull final Canvas canvas) {
int width = bounds.width();
int height = bounds.height();
Drawable drawable;
int newWidth;
int newHeight;
if (interpolatedTime <= 0.5f) {
drawable = getDrawable(0);
newWidth = Math.round((1 - interpolatedTime * 2) * width);
newHeight = Math.round((1 - interpolatedTime * 2) * height);
} else {
drawable = getDrawable(1);
newWidth = Math.round((interpolatedTime - 0.5f) * 2 * width);
newHeight = Math.round((interpolatedTime - 0.5f) * 2 * height);
}
int newLeft = Math.round(bounds.left + (width - newWidth) / 2f);
int newTop = Math.round(bounds.top + (height - newHeight) / 2f);
drawable.setBounds(newLeft, newTop, newLeft + newWidth, newTop + newHeight);
drawable.draw(canvas);
}
@Override
protected final void onEndTransition() {
getDrawable(0).setBounds(bounds);
getDrawable(1).setBounds(bounds);
}
}
|
3e077d011386a689e41e287e050071d8fc540725
| 479 |
java
|
Java
|
spring-security/src/test/java/com/github/dactiv/framework/spring/security/ConfigureApplication.java
|
dactiv/framework-support
|
cf057561f1320963570422ff97427e0ceb67f4c0
|
[
"Apache-2.0"
] | null | null | null |
spring-security/src/test/java/com/github/dactiv/framework/spring/security/ConfigureApplication.java
|
dactiv/framework-support
|
cf057561f1320963570422ff97427e0ceb67f4c0
|
[
"Apache-2.0"
] | null | null | null |
spring-security/src/test/java/com/github/dactiv/framework/spring/security/ConfigureApplication.java
|
dactiv/framework-support
|
cf057561f1320963570422ff97427e0ceb67f4c0
|
[
"Apache-2.0"
] | 1 |
2022-03-08T09:09:32.000Z
|
2022-03-08T09:09:32.000Z
| 31.933333 | 79 | 0.822547 | 3,181 |
package com.github.dactiv.framework.spring.security;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
@SpringBootApplication(exclude = DataSourceAutoConfiguration.class)
public class ConfigureApplication {
public static void main(String[] args) {
SpringApplication.run(ConfigureApplication.class, args);
}
}
|
3e077f15829a4c2130fdeb091c2a225fb1c37336
| 2,542 |
java
|
Java
|
hazelcast/src/test/java/com/hazelcast/quorum/lock/LockWriteQuorumTest.java
|
deepstupid/hazelfast
|
bc43da980a0ae6c95848a00f98437a19cdba85e2
|
[
"Apache-2.0"
] | 2 |
2017-05-21T17:34:36.000Z
|
2017-05-21T19:30:44.000Z
|
hazelcast/src/test/java/com/hazelcast/quorum/lock/LockWriteQuorumTest.java
|
deepstupid/hazelfast
|
bc43da980a0ae6c95848a00f98437a19cdba85e2
|
[
"Apache-2.0"
] | null | null | null |
hazelcast/src/test/java/com/hazelcast/quorum/lock/LockWriteQuorumTest.java
|
deepstupid/hazelfast
|
bc43da980a0ae6c95848a00f98437a19cdba85e2
|
[
"Apache-2.0"
] | null | null | null | 30.626506 | 75 | 0.72974 | 3,182 |
/*
* Copyright (c) 2008-2017, Hazelcast, Inc. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.hazelcast.quorum.lock;
import com.hazelcast.instance.HazelcastInstanceFactory;
import com.hazelcast.quorum.QuorumException;
import com.hazelcast.quorum.QuorumType;
import com.hazelcast.test.HazelcastSerialClassRunner;
import com.hazelcast.test.annotation.QuickTest;
import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
import org.junit.experimental.categories.Category;
import org.junit.runner.RunWith;
@RunWith(HazelcastSerialClassRunner.class)
@Category(QuickTest.class)
public class LockWriteQuorumTest extends AbstractLockQuorumTest {
@BeforeClass
public static void initialize() {
initializeFiveMemberCluster(QuorumType.WRITE, 3);
cluster.splitFiveMembersThreeAndTwo();
}
@AfterClass
public static void killAllHazelcastInstances() {
HazelcastInstanceFactory.terminateAll();
}
@Test
public void testReadOnlyOkWhenQuorumSizeNotMet() {
l4.getRemainingLeaseTime();
l4.isLocked();
l4.isLockedByCurrentThread();
l5.getLockCount();
}
@Test(expected = QuorumException.class)
public void testTryLockFailsWhenQuorumSizeNotMet() {
l4.tryLock();
}
@Test(expected = QuorumException.class)
public void testLockFailsWhenQuorumSizeNotMet() {
l4.lock();
}
@Test(expected = QuorumException.class)
public void testForceUnlockFailsWhenQuorumSizeNotMet() {
l5.forceUnlock();
}
@Test(expected = QuorumException.class)
public void testUnlockFailsWhenQuorumSizeNotMet() {
l4.unlock();
}
@Test(expected = QuorumException.class)
public void testAwaitFailsWhenQuorumSizeNotMet() throws Exception {
l4.newCondition("condition").await();
}
@Test(expected = QuorumException.class)
public void testSignalFailsWhenQuorumSizeNotMet() {
l4.newCondition("condition").signal();
}
}
|
3e0781315a3c437e4d310b273207a66a04b8a81b
| 6,296 |
java
|
Java
|
src/main/java/net/fabricmc/loom/task/launch/GenerateDLIConfigTask.java
|
OrnitheMC/fabric-loom
|
6ecaa609e8d7571f6a86e6ea0e24b11ef935307d
|
[
"MIT"
] | null | null | null |
src/main/java/net/fabricmc/loom/task/launch/GenerateDLIConfigTask.java
|
OrnitheMC/fabric-loom
|
6ecaa609e8d7571f6a86e6ea0e24b11ef935307d
|
[
"MIT"
] | null | null | null |
src/main/java/net/fabricmc/loom/task/launch/GenerateDLIConfigTask.java
|
OrnitheMC/fabric-loom
|
6ecaa609e8d7571f6a86e6ea0e24b11ef935307d
|
[
"MIT"
] | 1 |
2022-03-05T19:26:56.000Z
|
2022-03-05T19:26:56.000Z
| 38.864198 | 159 | 0.738247 | 3,183 |
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
* Copyright (c) 2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
package net.fabricmc.loom.task.launch;
import java.io.File;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.StringJoiner;
import java.util.stream.Collectors;
import org.apache.commons.io.FileUtils;
import org.gradle.api.logging.configuration.ConsoleOutput;
import org.gradle.api.tasks.TaskAction;
import net.fabricmc.loom.configuration.providers.minecraft.MinecraftVersionMeta;
import net.fabricmc.loom.configuration.providers.minecraft.mapped.MappedMinecraftProvider;
import net.fabricmc.loom.task.AbstractLoomTask;
import net.fabricmc.loom.util.gradle.SourceSetHelper;
public abstract class GenerateDLIConfigTask extends AbstractLoomTask {
@TaskAction
public void run() throws IOException {
final String nativesPath = getExtension().getFiles().getNativesDirectory(getProject()).getAbsolutePath();
final MinecraftVersionMeta versionInfo = getExtension().getMinecraftProvider().getVersionInfo();
File assetsDirectory = new File(getExtension().getFiles().getUserCache(), "assets");
if (versionInfo.assets().equals("legacy")) {
assetsDirectory = new File(assetsDirectory, "/legacy/" + versionInfo.id());
}
final LaunchConfig launchConfig = new LaunchConfig()
.property("fabric.development", "true")
.property("fabric.remapClasspathFile", getExtension().getFiles().getRemapClasspathFile().getAbsolutePath())
.property("log4j.configurationFile", getAllLog4JConfigFiles())
.property("log4j2.formatMsgNoLookups", "true")
.property("client", "java.library.path", nativesPath)
.property("client", "org.lwjgl.librarypath", nativesPath)
.argument("client", "--assetIndex")
.argument("client", getExtension().getMinecraftProvider().getVersionInfo().assetIndex().fabricId(getExtension().getMinecraftProvider().minecraftVersion()))
.argument("client", "--assetsDir")
.argument("client", assetsDirectory.getAbsolutePath());
if (getExtension().areEnvironmentSourceSetsSplit()) {
launchConfig.property("client", "fabric.gameJarPath.client", getGameJarPath("client"));
launchConfig.property("fabric.gameJarPath", getGameJarPath("common"));
}
if (!getExtension().getMods().isEmpty()) {
launchConfig.property("fabric.classPathGroups", getClassPathGroups());
}
final boolean plainConsole = getProject().getGradle().getStartParameter().getConsoleOutput() == ConsoleOutput.Plain;
final boolean ansiSupportedIDE = new File(getProject().getRootDir(), ".vscode").exists()
|| new File(getProject().getRootDir(), ".idea").exists()
|| (Arrays.stream(getProject().getRootDir().listFiles()).anyMatch(file -> file.getName().endsWith(".iws")));
//Enable ansi by default for idea and vscode when gradle is not ran with plain console.
if (ansiSupportedIDE && !plainConsole) {
launchConfig.property("fabric.log.disableAnsi", "false");
}
FileUtils.writeStringToFile(getExtension().getFiles().getDevLauncherConfig(), launchConfig.asString(), StandardCharsets.UTF_8);
}
private String getAllLog4JConfigFiles() {
return getExtension().getLog4jConfigs().getFiles().stream()
.map(File::getAbsolutePath)
.collect(Collectors.joining(","));
}
private String getGameJarPath(String env) {
MappedMinecraftProvider.Split split = (MappedMinecraftProvider.Split) getExtension().getNamedMinecraftProvider();
return switch (env) {
case "client" -> split.getClientOnlyJar().toAbsolutePath().toString();
case "common" -> split.getCommonJar().toAbsolutePath().toString();
default -> throw new UnsupportedOperationException();
};
}
/**
* See: https://github.com/FabricMC/fabric-loader/pull/585.
*/
private String getClassPathGroups() {
return getExtension().getMods().stream()
.map(modSettings ->
SourceSetHelper.getClasspath(modSettings, getProject()).stream()
.map(File::getAbsolutePath)
.collect(Collectors.joining(File.pathSeparator))
)
.collect(Collectors.joining(File.pathSeparator+File.pathSeparator));
}
public static class LaunchConfig {
private final Map<String, List<String>> values = new HashMap<>();
public LaunchConfig property(String key, String value) {
return property("common", key, value);
}
public LaunchConfig property(String side, String key, String value) {
values.computeIfAbsent(side + "Properties", (s -> new ArrayList<>()))
.add(String.format("%s=%s", key, value));
return this;
}
public LaunchConfig argument(String value) {
return argument("common", value);
}
public LaunchConfig argument(String side, String value) {
values.computeIfAbsent(side + "Args", (s -> new ArrayList<>()))
.add(value);
return this;
}
public String asString() {
StringJoiner stringJoiner = new StringJoiner("\n");
for (Map.Entry<String, List<String>> entry : values.entrySet()) {
stringJoiner.add(entry.getKey());
for (String s : entry.getValue()) {
stringJoiner.add("\t" + s);
}
}
return stringJoiner.toString();
}
}
}
|
3e0781b7f0daeff4f9ff46c4da3b67777c7e808b
| 1,520 |
java
|
Java
|
src/test/java/com/chiwanpark/flume/plugins/RedisSubscribeDrivenSourceTest.java
|
philipphoffmann/flume-ng-redis
|
8912cecfaba753e5d325645b549937f4f4c81c42
|
[
"Apache-2.0"
] | 24 |
2015-01-15T07:04:58.000Z
|
2020-07-24T02:42:46.000Z
|
src/test/java/com/chiwanpark/flume/plugins/RedisSubscribeDrivenSourceTest.java
|
philipphoffmann/flume-ng-redis
|
8912cecfaba753e5d325645b549937f4f4c81c42
|
[
"Apache-2.0"
] | 18 |
2015-02-09T16:37:29.000Z
|
2018-05-09T04:59:45.000Z
|
src/test/java/com/chiwanpark/flume/plugins/RedisSubscribeDrivenSourceTest.java
|
philipphoffmann/flume-ng-redis
|
8912cecfaba753e5d325645b549937f4f4c81c42
|
[
"Apache-2.0"
] | 22 |
2015-02-06T20:24:20.000Z
|
2018-05-09T10:49:53.000Z
| 31.020408 | 94 | 0.743421 | 3,184 |
/*
* Copyright 2013 Chiwan Park
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.chiwanpark.flume.plugins;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.JUnit4;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@RunWith(JUnit4.class)
public class RedisSubscribeDrivenSourceTest extends RedisSourceTestBase {
private static final Logger LOG = LoggerFactory.getLogger(RedisSubscribeDrivenSource.class);
@Before
public void setUp() throws Exception {
context.put("redisChannel", "flume-ng-redis-test");
source = new RedisSubscribeDrivenSource();
super.setUp();
}
@Test
public void testSubscribe() throws Exception {
String message = "testSubscribeMessage!";
LOG.info("Try to send message to redis source.");
publishMessageToRedis("flume-ng-redis-test", message);
Thread.sleep(2000);
Assert.assertEquals(message, getMessageFromChannel());
}
}
|
3e0782d1f833b7187dd595768c6b730d54aa6472
| 3,365 |
java
|
Java
|
app/src/main/java/com/aghajari/app/waveanimation/MainActivity.java
|
Aghajari/AXWaveAnimation
|
6ee929f0a6996cc3f1333164b104bbef8b46a758
|
[
"Apache-2.0"
] | 14 |
2020-12-27T23:07:56.000Z
|
2022-03-09T03:47:33.000Z
|
app/src/main/java/com/aghajari/app/waveanimation/MainActivity.java
|
arahman0709/AXWaveAnimation
|
6ee929f0a6996cc3f1333164b104bbef8b46a758
|
[
"Apache-2.0"
] | null | null | null |
app/src/main/java/com/aghajari/app/waveanimation/MainActivity.java
|
arahman0709/AXWaveAnimation
|
6ee929f0a6996cc3f1333164b104bbef8b46a758
|
[
"Apache-2.0"
] | 3 |
2021-05-18T11:57:41.000Z
|
2022-03-09T03:47:34.000Z
| 35.052083 | 132 | 0.632689 | 3,185 |
package com.aghajari.app.waveanimation;
import androidx.appcompat.app.AppCompatActivity;
import android.graphics.RadialGradient;
import android.graphics.Shader;
import android.os.Build;
import android.os.Bundle;
import android.view.View;
import android.widget.FrameLayout;
import android.widget.SeekBar;
import com.aghajari.waveanimation.AXLineWaveView;
import com.aghajari.waveanimation.AXLineWeavingState;
import com.aghajari.waveanimation.AXWaveView;
import com.aghajari.waveanimation.AXWeavingState;
public class MainActivity extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
FrameLayout layout = findViewById(R.id.layout);
final AXWaveView waveView = findViewById(R.id.wave);
final AXLineWaveView lineWaveView = findViewById(R.id.line_wave);
waveView.addState(1, AXWeavingState.create(1,
new RadialGradient(200,200,200, new int[]{0xff2BCEFF,0xff0976E3}
,null, Shader.TileMode.CLAMP)));
waveView.addState(2, new AXWeavingState(2){
@Override
protected void updateTargets() {
targetX = 0.2f + 0.1f * random.nextInt(100) / 100f;
targetY = 0.7f + 0.1f * random.nextInt(100) / 100f;
}
@Override
public Shader createShader() {
return new RadialGradient(200,200,200, new int[]{0xff12B522,0xff00D6C1}
,null, Shader.TileMode.CLAMP);
}
});
lineWaveView.addState(1, AXLineWeavingState.create(1,AXWaveView.createLinearShader(1000,0xff0976E3,0xff0976E3,0xff0976E3)));
lineWaveView.addState(2, AXLineWeavingState.create(1,AXWaveView.createLinearShader(1000,0xff00D6C1,0xff00D6C1,0xff00D6C1)));
lineWaveView.setState(1);
setNavigationBarColor(0xff0976E3);
waveView.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
if (waveView.getCurrentState().getState() == 1) {
waveView.setState(2);
lineWaveView.setState(2);
setNavigationBarColor(0xff00D6C1);
} else {
waveView.setState(1);
lineWaveView.setState(1);
setNavigationBarColor(0xff0976E3);
}
}
});
SeekBar seekBar = findViewById(R.id.seek_bar);
seekBar.setMax((int) (AXWaveView.MAX_AMPLITUDE));
seekBar.setOnSeekBarChangeListener(new SeekBar.OnSeekBarChangeListener() {
@Override
public void onProgressChanged(SeekBar seekBar, int i, boolean b) {
waveView.setAmplitude(i);
lineWaveView.setAmplitude(Math.max(i,AXLineWaveView.MAX_AMPLITUDE/50));
}
@Override
public void onStartTrackingTouch(SeekBar seekBar) {
}
@Override
public void onStopTrackingTouch(SeekBar seekBar) {
}
});
}
private void setNavigationBarColor(int color) {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
getWindow().setNavigationBarColor(color);
}
}
}
|
3e0782db7fa310044c39c30a7637496e6ac932ce
| 3,962 |
java
|
Java
|
src/com/f454/graph/GraphingEngine.java
|
joechrisellis/F454
|
4e38f00db537b8470996ef1f547a836cc22d3af7
|
[
"MIT"
] | null | null | null |
src/com/f454/graph/GraphingEngine.java
|
joechrisellis/F454
|
4e38f00db537b8470996ef1f547a836cc22d3af7
|
[
"MIT"
] | null | null | null |
src/com/f454/graph/GraphingEngine.java
|
joechrisellis/F454
|
4e38f00db537b8470996ef1f547a836cc22d3af7
|
[
"MIT"
] | null | null | null | 25.727273 | 79 | 0.689298 | 3,186 |
package com.f454.graph;
import java.awt.Font;
import java.awt.Graphics2D;
import java.util.ArrayList;
import java.util.ListIterator;
import com.f454.graph.mathobject.MathematicalObject;
import com.f454.graph.mathobject.special.Axes;
import com.f454.graph.mathobject.special.Key;
import com.f454.gui.mainwindow.MainWindow;
import com.f454.gui.mainwindow.panel.GraphingPanel;
import com.f454.gui.setting.SetResolutionDialog;
/**
* The engine powering the rendering of mathematical objects.
* @author Joe Ellis
*
*/
public class GraphingEngine {
public static final Font FONT = new Font(null, Font.BOLD, 10);
// The graphingPanel object is a reference to the container so we can do
// things like get the width and height of it, etc.
private final GraphingPanel graphingPanel;
private ScalingManager sm;
private double resolution;
// A resizing array of all of the mathematical objects, visible or invisible.
private ArrayList<MathematicalObject> mathObjects;
private Key key;
public GraphingEngine(GraphingPanel graphingPanel) {
this.graphingPanel = graphingPanel;
sm = new ScalingManager(this);
resolution = SetResolutionDialog.getOptimumResolution();
// create the list of mathematical objects and add the axes.
mathObjects = new ArrayList<MathematicalObject>();
Axes axes = new Axes(sm);
mathObjects.add(axes);
key = new Key(mathObjects);
mathObjects.add(key);
}
/**
* Renders all of the visible mathematical objects using the parameter g.
* @param g The Graphics2D object used for rendering.
*/
public void render(Graphics2D g) {
g.setFont(FONT);
// iterate through all of the mathematical objects...
ListIterator<MathematicalObject> itr = mathObjects.listIterator();
while(itr.hasNext()) {
MathematicalObject o = itr.next();
// if the mathematical object o has been flagged as removed, delete
// it from the list of mathematical objects.
if(o.isRemoved()) {
itr.remove();
continue;
}
// if o is visible, render it.
if(o.isVisible()) {
o.render(g);
}
}
}
/**
* Clears the arraylist of mathematical objects (except for anything marked
* as not removable).
*/
public void clear() {
ListIterator<MathematicalObject> itr = mathObjects.listIterator();
while(itr.hasNext()) {
// if the object isn't the axes, delete it.
if(!itr.next().isRemovable()) continue;
else itr.remove();
}
// refresh the mathematical objects panel GUI element.
MainWindow m = MainWindow.getInstance();
m.getMathPanel().refreshAll();
}
/**
* Adds a mathematical object to the arraylist.
* @param o The mathematical object to be added.
*/
public void addMathObject(MathematicalObject o) {
mathObjects.add(o);
MainWindow m = MainWindow.getInstance();
m.getMathPanel().addMathObject(o);
}
public GraphingPanel getGraphingPanel() {
return graphingPanel;
}
public ScalingManager getScalingManager() {
return sm;
}
public ArrayList<MathematicalObject> getMathObjects() {
return mathObjects;
}
public void setMathObjects(ArrayList<MathematicalObject> mathObjects) {
this.mathObjects = mathObjects;
}
public Key getKey() {
return key;
}
public double getResolution() {
return resolution;
}
/**
* Sets a new value for the resolution and updates all of the mathematical
* objects to account for the change.
* @param resolution
*/
public void setResolution(double resolution) {
this.resolution = resolution;
refresh();
}
public void refresh() {
// iterate through all of the mathematical objects and ask them
// to reinitialise themselves.
ListIterator<MathematicalObject> itr = mathObjects.listIterator();
while(itr.hasNext()) {
MathematicalObject m = itr.next();
m.reinit();
}
}
}
|
3e0783e45f16b2589b8817df362e026aacf29a65
| 836 |
java
|
Java
|
hello-jni/src/com/example/hellojni/BootReceiver.java
|
informramiz/Android-Face-Recognition
|
d870ec458d3badf97a3bed54cf39d440e6546cc9
|
[
"MIT"
] | 2 |
2017-04-06T13:19:36.000Z
|
2017-04-06T16:53:31.000Z
|
hello-jni/src/com/example/hellojni/BootReceiver.java
|
informramiz/Android-Face-Recognition
|
d870ec458d3badf97a3bed54cf39d440e6546cc9
|
[
"MIT"
] | null | null | null |
hello-jni/src/com/example/hellojni/BootReceiver.java
|
informramiz/Android-Face-Recognition
|
d870ec458d3badf97a3bed54cf39d440e6546cc9
|
[
"MIT"
] | 2 |
2018-04-19T03:07:55.000Z
|
2018-07-21T15:32:30.000Z
| 27.866667 | 102 | 0.761962 | 3,187 |
package com.example.hellojni;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.media.FaceDetector.Face;
import android.net.Uri;
import android.provider.CallLog.Calls;
public class BootReceiver extends BroadcastReceiver {
@Override
public void onReceive(Context context , Intent intent )
{
SharedPreferences prefs = context.getSharedPreferences( Constant.PREF_NAME , Context.MODE_PRIVATE );
boolean lockStatus = prefs.getBoolean( Constant.FACE_LOCK_STATUS_PREF , false );
if ( lockStatus == false )
return;
Intent intentNew = new Intent ( context , FaceUnlockActivity.class );
intent.setFlags( Intent.FLAG_ACTIVITY_NEW_TASK );
context.startActivity ( intentNew );
}
}
|
3e078579131c62bc006511c869eaa6e2c482738f
| 7,872 |
java
|
Java
|
cas-server-support-osf/src/main/java/org/pac4j/oauth/client/OrcidClient.java
|
yacchin1205/cas-overlay
|
c640c841134d787d1e74477ea2baf7bb4452f7ee
|
[
"Apache-2.0"
] | null | null | null |
cas-server-support-osf/src/main/java/org/pac4j/oauth/client/OrcidClient.java
|
yacchin1205/cas-overlay
|
c640c841134d787d1e74477ea2baf7bb4452f7ee
|
[
"Apache-2.0"
] | null | null | null |
cas-server-support-osf/src/main/java/org/pac4j/oauth/client/OrcidClient.java
|
yacchin1205/cas-overlay
|
c640c841134d787d1e74477ea2baf7bb4452f7ee
|
[
"Apache-2.0"
] | 1 |
2019-06-21T07:34:59.000Z
|
2019-06-21T07:34:59.000Z
| 33.21519 | 133 | 0.632368 | 3,188 |
/*
Copyright 2012 - 2015 pac4j organization
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package org.pac4j.oauth.client;
import org.apache.http.HttpStatus;
import org.pac4j.core.context.WebContext;
import org.pac4j.core.exception.HttpCommunicationException;
import org.pac4j.oauth.client.exception.OAuthCredentialsException;
import org.pac4j.oauth.profile.OAuthAttributesDefinitions;
import org.pac4j.oauth.profile.XmlHelper;
import org.pac4j.oauth.profile.orcid.OrcidAttributesDefinition;
import org.pac4j.oauth.profile.orcid.OrcidProfile;
import org.scribe.builder.api.OrcidApi20;
import org.scribe.exceptions.OAuthException;
import org.scribe.model.OAuthConfig;
import org.scribe.model.SignatureType;
import org.scribe.model.Token;
import org.scribe.oauth.ProxyOAuth20ServiceImpl;
import org.scribe.tokens.OrcidToken;
import org.scribe.model.ProxyOAuthRequest;
import org.scribe.model.Response;
/**
* <p>This class is the OAuth client to authenticate users in ORCiD.</p>
* <p>It returns a {@link org.pac4j.oauth.profile.orcid.OrcidProfile}.</p>
* <p>More information at http://support.orcid.org/knowledgebase/articles/175079-tutorial-retrieve-data-from-an-orcid-record-with</p>
*
* @author Jens Tinglev
* @author Michael Haselton
* @author Longze Chen
* @see org.pac4j.oauth.profile.orcid.OrcidProfile
* @since 1.7.1
*/
public class OrcidClient extends BaseOAuth20Client<OrcidProfile> {
/** The default scope. */
protected static final String DEFAULT_SCOPE = "/orcid-profile/read-limited";
/** The scope. */
protected String scope = DEFAULT_SCOPE;
/** The member flag. */
protected Boolean member = Boolean.TRUE;
/**
* Create an instance of `OrcidClient` with given `key` and `secret`.
*
* @param key the key
* @param secret the secret
*/
public OrcidClient(final String key, final String secret) {
setKey(key);
setSecret(secret);
setTokenAsHeader(true);
}
/**
* Create an instance of `OrcidClient`.
*/
public OrcidClient() {
setTokenAsHeader(true);
}
/**
* @return Returns whether use the `state` parameter for OAuth request.
*/
@Override
protected boolean requiresStateParameter() {
return false;
}
/**
* Check whether user has denied permissions.
*
* @param context the web context
* @return if access has been denied by the user
*/
@Override
protected boolean hasBeenCancelled(final WebContext context) {
final String error = context.getRequestParameter(OAuthCredentialsException.ERROR);
final String errorDescription = context.getRequestParameter(OAuthCredentialsException.ERROR_DESCRIPTION);
// user has denied permissions
return ("access_denied".equals(error) && "User denied access".equals(errorDescription));
}
/**
* Get the oauth url to retrieve user profile.
*
* @param accessToken the access token
* @return profile uri
* @throws OAuthException if wrong token type
*/
@Override
protected String getProfileUrl(final Token accessToken) {
if (accessToken instanceof OrcidToken) {
return String.format("https://%s.orcid.org/v2.0/%s/record",
(this.getMember() ? "api" : "pub"), ((OrcidToken) accessToken).getOrcid());
} else {
throw new OAuthException("Token in getProfileUrl is not an OrcidToken");
}
}
/**
* The internal initialization.
*/
@Override
protected void internalInit() {
super.internalInit();
this.service = new ProxyOAuth20ServiceImpl(
new OrcidApi20(),
new OAuthConfig(
this.key,
this.secret,
this.callbackUrl,
SignatureType.Header,
this.getScope(),
null
),
this.connectTimeout,
this.readTimeout,
this.proxyHost, this.proxyPort,
false,
true
);
}
/**
* @return the oauth scope.
*/
public String getScope() {
return this.scope;
}
/**
* @param scope the oauth scope.
*/
public void setScope(final String scope) {
this.scope = scope;
}
/**
* @return the member flag.
*/
public Boolean getMember() {
return this.member;
}
/**
* @param member the member flag.
*/
public void setMember(final Boolean member) {
this.member = member;
}
/**
* Extract user profile.
*
* @param body the body
* @return the profile
*/
@Override
protected OrcidProfile extractUserProfile(final String body) {
final OrcidProfile profile = new OrcidProfile();
profile.setId(XmlHelper.get(body, OrcidAttributesDefinition.ORCID));
for(final String attribute : OAuthAttributesDefinitions.orcidDefinition.getAllAttributes()) {
final String value = XmlHelper.get(body, attribute);
switch (attribute) {
case OrcidAttributesDefinition.NORMALIZED_FAMILY_NAME:
break;
case OrcidAttributesDefinition.NORMALIZED_GIVEN_NAME:
break;
case OrcidAttributesDefinition.FAMILY_NAME:
profile.addAttribute(OrcidAttributesDefinition.NORMALIZED_FAMILY_NAME, value);
break;
case OrcidAttributesDefinition.GIVEN_NAME:
profile.addAttribute(OrcidAttributesDefinition.NORMALIZED_GIVEN_NAME, value);
break;
default:
profile.addAttribute(attribute, value);
break;
}
}
return profile;
}
/**
* Create a new `OrcidClient`.
* @return the new cient
*/
@Override
protected OrcidClient newClient() {
final OrcidClient newClient = new OrcidClient();
newClient.setScope(this.scope);
return newClient;
}
/**
* Make a request to get the data of the authenticated user for the provider.
*
* @param accessToken the access token
* @param dataUrl url of the data
* @return the user data response
* @throws HttpCommunicationException if fails to retrieve data
*/
@Override
protected String sendRequestForData(final Token accessToken, final String dataUrl) {
logger.debug("accessToken : {} / dataUrl : {}", accessToken, dataUrl);
final long t0 = System.currentTimeMillis();
final ProxyOAuthRequest request = createProxyRequest(dataUrl);
final Response response = request.send();
final int code = response.getCode();
final String body = response.getBody();
final long t1 = System.currentTimeMillis();
logger.debug(String.format("Request took : {} ms for : {} ", (t1 - t0), dataUrl));
logger.debug("response code : {} / response body : {}", code, body);
if (code != HttpStatus.SC_OK) {
logger.error("Failed to get data, code : {} / body : {}", code, body);
throw new HttpCommunicationException(code, body);
}
return body;
}
}
|
3e0786bcc4636b27acb303df89e72650be924160
| 778 |
java
|
Java
|
chapter_001/src/test/java/ru/job4j/array/FindLoopTest.java
|
AlexandarVysotskiy/AVysotskiy
|
9cc420250750bb8e6222de633fa5c93cdb78096f
|
[
"Apache-2.0"
] | null | null | null |
chapter_001/src/test/java/ru/job4j/array/FindLoopTest.java
|
AlexandarVysotskiy/AVysotskiy
|
9cc420250750bb8e6222de633fa5c93cdb78096f
|
[
"Apache-2.0"
] | 1 |
2019-03-05T12:36:41.000Z
|
2019-03-05T16:40:45.000Z
|
chapter_001/src/test/java/ru/job4j/array/FindLoopTest.java
|
AlexandarVysotskiy/AVysotskiy
|
9cc420250750bb8e6222de633fa5c93cdb78096f
|
[
"Apache-2.0"
] | 2 |
2018-07-04T15:19:27.000Z
|
2019-03-06T17:15:36.000Z
| 21.378378 | 64 | 0.556258 | 3,189 |
package ru.job4j.array;
import org.junit.Test;
import static org.hamcrest.core.Is.is;
import static org.junit.Assert.assertThat;
/**
* @author Aleksandr Vysotskiiy ([email protected])
* @version 1.0
* @since 0.1
*/
public class FindLoopTest {
@Test
public void findsAnElement() {
FindLoop finds = new FindLoop();
int[] r = new int[6];
r[0] = 1;
r[1] = 2;
r[2] = 3;
r[3] = 4;
r[4] = 5;
int result = finds.indexOf(r, 5);
assertThat(result, is(4));
}
@Test
public void doesNotFindAnItem() {
FindLoop haveNotFound = new FindLoop();
int[] r = new int[4];
r[2] = 3;
int result = haveNotFound.indexOf(r, 4);
assertThat(result, is(-1));
}
}
|
3e0786d14fdf790963e53f0dfc07136a3be05c7a
| 387 |
java
|
Java
|
chapter_003/src/main/java/ru/job4j/list/UserConvert.java
|
azicks/job4j
|
7e02795986880f788dafb5af6be6de96b9ac88ec
|
[
"Apache-2.0"
] | null | null | null |
chapter_003/src/main/java/ru/job4j/list/UserConvert.java
|
azicks/job4j
|
7e02795986880f788dafb5af6be6de96b9ac88ec
|
[
"Apache-2.0"
] | 8 |
2020-07-01T19:32:03.000Z
|
2022-02-16T01:04:08.000Z
|
chapter_003/src/main/java/ru/job4j/list/UserConvert.java
|
azicks/job4j
|
7e02795986880f788dafb5af6be6de96b9ac88ec
|
[
"Apache-2.0"
] | null | null | null | 25.8 | 81 | 0.679587 | 3,190 |
package ru.job4j.list;
import java.util.HashMap;
import java.util.List;
import java.util.function.Function;
import java.util.stream.Collectors;
public class UserConvert {
public HashMap<Integer, User> process(List<User> list) {
return (HashMap<Integer, User>) list.stream()
.collect(Collectors.toMap(User::getId, Function.identity()));
}
}
|
3e07887a5046dae5a30a3660858a7e4b98d4c22b
| 228 |
java
|
Java
|
slidinglayout/src/main/java/com/coffeebreakcodes/slidinglayout/StatusListener.java
|
kkartal/SlidingLayout3
|
c7cc2767f425b9142017dc06cf6b85050894eb9d
|
[
"Apache-2.0"
] | 3 |
2017-07-31T07:50:32.000Z
|
2017-08-15T14:53:44.000Z
|
slidinglayout/src/main/java/com/coffeebreakcodes/slidinglayout/StatusListener.java
|
kkartal/SlidingLayout3
|
c7cc2767f425b9142017dc06cf6b85050894eb9d
|
[
"Apache-2.0"
] | null | null | null |
slidinglayout/src/main/java/com/coffeebreakcodes/slidinglayout/StatusListener.java
|
kkartal/SlidingLayout3
|
c7cc2767f425b9142017dc06cf6b85050894eb9d
|
[
"Apache-2.0"
] | 1 |
2017-08-15T07:37:30.000Z
|
2017-08-15T07:37:30.000Z
| 17.538462 | 50 | 0.736842 | 3,191 |
package com.coffeebreakcodes.slidinglayout;
/**
* coffeebreakcodes.com - 2017
*
* Listener to handle the layout if it is expanded
* or collapsed
*/
public interface StatusListener {
void status(boolean isExpanded);
}
|
3e0788e8d89537212c5c463e9709c68fbd8fec7c
| 628 |
java
|
Java
|
src/web_server/codeine/servlets/RootServlet.java
|
ItamarBenjamin/codeine
|
714525bd6e5cbb7713240097964d3608e564b7ac
|
[
"Apache-2.0"
] | 19 |
2015-01-08T16:21:50.000Z
|
2019-11-21T21:46:32.000Z
|
src/web_server/codeine/servlets/RootServlet.java
|
ItamarBenjamin/codeine
|
714525bd6e5cbb7713240097964d3608e564b7ac
|
[
"Apache-2.0"
] | 146 |
2015-01-06T03:06:19.000Z
|
2020-12-02T18:36:54.000Z
|
src/web_server/codeine/servlets/RootServlet.java
|
ItamarBenjamin/codeine
|
714525bd6e5cbb7713240097964d3608e564b7ac
|
[
"Apache-2.0"
] | 5 |
2015-03-02T08:55:42.000Z
|
2019-03-20T14:25:39.000Z
| 27.304348 | 118 | 0.832803 | 3,192 |
package codeine.servlets;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import codeine.model.Constants;
import codeine.servlet.AbstractServlet;
public class RootServlet extends HttpServlet{
private static final long serialVersionUID = 1L;
@Override
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
AbstractServlet.setNoCache(response);
response.sendRedirect(Constants.ANGULAR_CONTEXT);
}
}
|
3e0789189bccaedc4173dfdb0bd8efa3c76945f1
| 3,932 |
java
|
Java
|
app/src/main/java/uk/ac/ebi/atlas/hcalandingpage/JsonHcaLandingPageController.java
|
ebi-gene-expression-group/atlas-web-single-cell
|
ae1511db7637d3de3c21c59a2f8a6dc7cc836dd2
|
[
"Apache-2.0"
] | null | null | null |
app/src/main/java/uk/ac/ebi/atlas/hcalandingpage/JsonHcaLandingPageController.java
|
ebi-gene-expression-group/atlas-web-single-cell
|
ae1511db7637d3de3c21c59a2f8a6dc7cc836dd2
|
[
"Apache-2.0"
] | 126 |
2019-06-17T09:59:30.000Z
|
2022-03-28T17:54:25.000Z
|
app/src/main/java/uk/ac/ebi/atlas/hcalandingpage/JsonHcaLandingPageController.java
|
ebi-gene-expression-group/atlas-web-single-cell
|
ae1511db7637d3de3c21c59a2f8a6dc7cc836dd2
|
[
"Apache-2.0"
] | 2 |
2019-07-12T12:43:35.000Z
|
2022-01-05T17:07:42.000Z
| 57.823529 | 226 | 0.49237 | 3,193 |
package uk.ac.ebi.atlas.hcalandingpage;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import uk.ac.ebi.atlas.controllers.JsonExceptionHandlingController;
import uk.ac.ebi.atlas.model.card.CardModel;
import uk.ac.ebi.atlas.model.card.CardModelAdapter;
import uk.ac.ebi.atlas.utils.GsonProvider;
import static uk.ac.ebi.atlas.model.card.CardIconType.IMAGE;
import static uk.ac.ebi.atlas.utils.UrlHelpers.getCustomUrl;
import static uk.ac.ebi.atlas.utils.UrlHelpers.getExperimentLink;
@RestController
public class JsonHcaLandingPageController extends JsonExceptionHandlingController {
protected static final String HCA_ACCESSION_PATTERN = "EHCA";
@GetMapping(value = {"/json/hca"}, produces = MediaType.APPLICATION_JSON_UTF8_VALUE)
public String jsonHca() {
return GsonProvider.GSON.toJson(
ImmutableMap.of("cards", CardModelAdapter.serialize(getHcaCards())));
}
private ImmutableList<CardModel> getHcaCards() {
return ImmutableList.of(
CardModel.create(
IMAGE,
getCustomUrl("www.ebi.ac.uk", "/resources/images/logos/hca_cell_logo.png"),
ImmutableList.of(
getExperimentLink(
"www.ebi.ac.uk",
"Mouse cells – Small intestinal epithelium",
"E-EHCA-2"),
getExperimentLink(
"www.ebi.ac.uk",
"Single cell transcriptome analysis of human pancreas",
"E-GEOD-81547"),
getExperimentLink(
"www.ebi.ac.uk",
"Single-cell RNA-seq analysis of 1,732 cells throughout a 125-day differentiation protocol that converted H1 human embryonic stem cells to a variety of ventrally-derived cell types",
"E-GEOD-93593"),
getExperimentLink(
"www.ebi.ac.uk",
"Single-cell RNA-seq analysis of human pancreas from healthy individuals and type 2 diabetes patients",
"E-MTAB-5061"),
getExperimentLink(
"www.ebi.ac.uk",
"Single-cell transcriptome analysis of precursors of human CD4+ cytotoxic T lymphocytes",
"E-GEOD-106540"),
getExperimentLink(
"www.ebi.ac.uk",
"Tabula Muris",
"E-ENAD-15"),
getExperimentLink(
"www.ebi.ac.uk",
"Reconstructing the human first trimester fetal-maternal interface using single cell transcriptomics – 10x data",
"E-MTAB-6701"),
getExperimentLink(
"www.ebi.ac.uk",
"Reconstructing the human first trimester fetal-maternal interface using single cell transcriptomics – Smartseq 2 data",
"E-MTAB-6678"))));
}
}
|
3e07892dbc7f2aff58ad3a3da20566a3505d4583
| 11,255 |
java
|
Java
|
adapters/santander-adapter/src/main/java/de/adorsys/xs2a/adapter/santander/SantanderAccountInformationService.java
|
golden-dimension/xs2a-adapter
|
abf9f8778f7b77c810b6038049429fc3eaa34367
|
[
"Apache-2.0"
] | 32 |
2019-05-09T12:28:56.000Z
|
2022-03-18T22:56:36.000Z
|
adapters/santander-adapter/src/main/java/de/adorsys/xs2a/adapter/santander/SantanderAccountInformationService.java
|
golden-dimension/xs2a-adapter
|
abf9f8778f7b77c810b6038049429fc3eaa34367
|
[
"Apache-2.0"
] | 54 |
2019-06-19T10:08:46.000Z
|
2022-01-25T12:24:07.000Z
|
adapters/santander-adapter/src/main/java/de/adorsys/xs2a/adapter/santander/SantanderAccountInformationService.java
|
golden-dimension/xs2a-adapter
|
abf9f8778f7b77c810b6038049429fc3eaa34367
|
[
"Apache-2.0"
] | 23 |
2019-02-18T16:14:28.000Z
|
2022-03-17T12:03:00.000Z
| 49.581498 | 143 | 0.546602 | 3,194 |
/*
* Copyright 2018-2018 adorsys GmbH & Co KG
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package de.adorsys.xs2a.adapter.santander;
import de.adorsys.xs2a.adapter.api.RequestHeaders;
import de.adorsys.xs2a.adapter.api.RequestParams;
import de.adorsys.xs2a.adapter.api.Response;
import de.adorsys.xs2a.adapter.api.http.HttpClientFactory;
import de.adorsys.xs2a.adapter.api.link.LinksRewriter;
import de.adorsys.xs2a.adapter.api.model.*;
import de.adorsys.xs2a.adapter.impl.BaseAccountInformationService;
import de.adorsys.xs2a.adapter.santander.model.SantanderTransactionResponse200Json;
import org.mapstruct.factory.Mappers;
import java.util.Map;
public class SantanderAccountInformationService extends BaseAccountInformationService {
private final SantanderMapper santanderMapper = Mappers.getMapper(SantanderMapper.class);
private final SantanderOauth2Service oauth2Service;
private final SantanderRequestHandler requestHandler = new SantanderRequestHandler();
public SantanderAccountInformationService(Aspsp aspsp,
SantanderOauth2Service oauth2Service,
HttpClientFactory httpClientFactory,
LinksRewriter linksRewriter) {
super(aspsp,
SantanderHttpClientFactory.getHttpClient(aspsp.getAdapterId(), httpClientFactory),
linksRewriter,
httpClientFactory.getHttpClientConfig().getLogSanitizer());
this.oauth2Service = oauth2Service;
}
@Override
public Response<ConsentsResponse201> createConsent(RequestHeaders requestHeaders,
RequestParams requestParams,
Consents body) {
Map<String, String> updatedHeaders = addBearerHeader(requestHeaders.toMap());
return super.createConsent(RequestHeaders.fromMap(updatedHeaders), requestParams, body);
}
@Override
public Response<StartScaprocessResponse> startConsentAuthorisation(String consentId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
throw new UnsupportedOperationException();
}
@Override
public Response<StartScaprocessResponse> startConsentAuthorisation(String consentId,
RequestHeaders requestHeaders,
RequestParams requestParams,
UpdatePsuAuthentication updatePsuAuthentication) {
throw new UnsupportedOperationException();
}
@Override
public Response<UpdatePsuAuthenticationResponse> updateConsentsPsuData(String consentId,
String authorisationId,
RequestHeaders requestHeaders,
RequestParams requestParams,
UpdatePsuAuthentication updatePsuAuthentication) {
throw new UnsupportedOperationException();
}
@Override
public Response<SelectPsuAuthenticationMethodResponse> updateConsentsPsuData(String consentId,
String authorisationId,
RequestHeaders requestHeaders,
RequestParams requestParams,
SelectPsuAuthenticationMethod selectPsuAuthenticationMethod) {
throw new UnsupportedOperationException();
}
@Override
public Response<ScaStatusResponse> updateConsentsPsuData(String consentId,
String authorisationId,
RequestHeaders requestHeaders,
RequestParams requestParams,
TransactionAuthorisation transactionAuthorisation) {
throw new UnsupportedOperationException();
}
@Override
public Response<ConsentInformationResponse200Json> getConsentInformation(String consentId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
requestHandler.validateRequest(requestHeaders);
return super.getConsentInformation(consentId, requestHeaders, requestParams);
}
@Override
public Response<ConsentStatusResponse200> getConsentStatus(String consentId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
requestHandler.validateRequest(requestHeaders);
return super.getConsentStatus(consentId, requestHeaders, requestParams);
}
@Override
public Response<Void> deleteConsent(String consentId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
requestHandler.validateRequest(requestHeaders);
return super.deleteConsent(consentId, requestHeaders, requestParams);
}
@Override
public Response<AccountList> getAccountList(RequestHeaders requestHeaders,
RequestParams requestParams) {
requestHandler.validateRequest(requestHeaders);
return super.getAccountList(requestHeaders, requestParams);
}
@Override
public Response<OK200AccountDetails> readAccountDetails(String accountId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
requestHandler.validateRequest(requestHeaders);
return super.readAccountDetails(accountId, requestHeaders, requestParams);
}
@Override
public Response<ReadAccountBalanceResponse200> getBalances(String accountId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
requestHandler.validateRequest(requestHeaders);
return super.getBalances(accountId, requestHeaders, requestParams);
}
@Override
public Response<TransactionsResponse200Json> getTransactionList(String accountId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
requestHandler.validateRequest(requestHeaders);
return super.getTransactionList(accountId,
requestHeaders,
requestParams,
SantanderTransactionResponse200Json.class,
santanderMapper::toTransactionsResponse200Json);
}
@Override
public Response<OK200TransactionDetails> getTransactionDetails(String accountId,
String transactionId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
throw new UnsupportedOperationException();
}
@Override
public Response<Authorisations> getConsentAuthorisation(String consentId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
throw new UnsupportedOperationException();
}
@Override
public Response<CardAccountList> getCardAccountList(RequestHeaders requestHeaders,
RequestParams requestParams) {
throw new UnsupportedOperationException();
}
@Override
public Response<OK200CardAccountDetails> getCardAccountDetails(String accountId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
throw new UnsupportedOperationException();
}
@Override
public Response<ReadCardAccountBalanceResponse200> getCardAccountBalances(String accountId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
throw new UnsupportedOperationException();
}
@Override
public Response<CardAccountsTransactionsResponse200> getCardAccountTransactionList(String accountId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
throw new UnsupportedOperationException();
}
@Override
public Response<ScaStatusResponse> getConsentScaStatus(String consentId,
String authorisationId,
RequestHeaders requestHeaders,
RequestParams requestParams) {
throw new UnsupportedOperationException();
}
private Map<String, String> addBearerHeader(Map<String, String> headers) {
headers.put("Authorization", "Bearer " + oauth2Service.getClientCredentialsAccessToken());
return headers;
}
@Override
protected Map<String, String> resolvePsuIdHeader(Map<String, String> headers) {
headers.remove(RequestHeaders.PSU_ID); // will actually fail if PSU-ID is provided
return headers;
}
}
|
3e07894f30ecd08f9bb3658d7c865d364588d5dd
| 1,482 |
java
|
Java
|
AuthenticatorApp/src/main/java/com/google/android/apps/authenticator/config/AuthenticConfig.java
|
xwc1125/Droid-GoogleAuthenticator
|
9be98b3164288e24d379a13f1c24379ce1bfb46f
|
[
"Apache-2.0"
] | null | null | null |
AuthenticatorApp/src/main/java/com/google/android/apps/authenticator/config/AuthenticConfig.java
|
xwc1125/Droid-GoogleAuthenticator
|
9be98b3164288e24d379a13f1c24379ce1bfb46f
|
[
"Apache-2.0"
] | null | null | null |
AuthenticatorApp/src/main/java/com/google/android/apps/authenticator/config/AuthenticConfig.java
|
xwc1125/Droid-GoogleAuthenticator
|
9be98b3164288e24d379a13f1c24379ce1bfb46f
|
[
"Apache-2.0"
] | null | null | null | 29.64 | 99 | 0.665317 | 3,195 |
package com.google.android.apps.authenticator.config;
/**
* Description: TODO <br>
*
* @author xwc1125 <br>
* @version V1.0
* @Copyright: Copyright (c) 2017 <br>
* @date 2017/6/28 12:05 <br>
*/
public class AuthenticConfig {
/**
* 默认30秒更改一次
* <p>
* Default passcode timeout period (in seconds)
*/
public static final int DEFAULT_INTERVAL = 30;
/**
* The maximum amount of time (milliseconds) for which a HOTP code is displayed after it's been
* generated.
*/
public static final long HOTP_DISPLAY_TIMEOUT = 2 * 60 * 1000;
/**
* Minimum amount of time (milliseconds) that has to elapse from the moment a HOTP code is
* generated for an account until the moment the next code can be generated for the account.
* This is to prevent the user from generating too many HOTP codes in a short period of time.
*/
public static final long HOTP_MIN_TIME_INTERVAL_BETWEEN_CODES = 5000;
/**
* Scale to use for the text displaying the PIN numbers.
*/
public static final float PIN_TEXT_SCALEX_NORMAL = 1.0f;
/**
* Underscores are shown slightly smaller.
*/
public static final float PIN_TEXT_SCALEX_UNDERSCORE = 0.87f;
/**
* Frequency (milliseconds) with which TOTP countdown indicators are updated.
*/
public static final long TOTP_COUNTDOWN_REFRESH_PERIOD = 100;
/**
* 震动的频率
*/
public static final long VIBRATE_DURATION = 200L;
}
|
3e078984a36427241508cbda475abb715d9e8b73
| 6,088 |
java
|
Java
|
src/main/java/com/toornament/concepts/Permissions.java
|
BrentonPoke/ToornamentClient
|
bac7ab60d52ed7d688a476bfa63766e4302ec272
|
[
"Apache-2.0"
] | 4 |
2018-06-27T15:18:49.000Z
|
2020-06-06T11:47:26.000Z
|
src/main/java/com/toornament/concepts/Permissions.java
|
BrentonPoke/ToornamentClient
|
bac7ab60d52ed7d688a476bfa63766e4302ec272
|
[
"Apache-2.0"
] | 20 |
2019-06-22T15:45:43.000Z
|
2021-09-26T10:56:12.000Z
|
src/main/java/com/toornament/concepts/Permissions.java
|
BrentonPoke/ToornamentClient
|
bac7ab60d52ed7d688a476bfa63766e4302ec272
|
[
"Apache-2.0"
] | 3 |
2019-12-07T05:12:26.000Z
|
2021-01-22T22:42:00.000Z
| 37.580247 | 100 | 0.688732 | 3,196 |
package com.toornament.concepts;
import com.toornament.ToornamentClient;
import com.toornament.exception.ToornamentException;
import com.toornament.model.Permission;
import com.toornament.model.enums.Attribute;
import com.toornament.model.enums.Scope;
import com.toornament.model.request.PermissionsQuery;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
import java.io.IOException;
import java.util.List;
import okhttp3.HttpUrl.Builder;
import okhttp3.MediaType;
import okhttp3.Request;
import okhttp3.RequestBody;
import org.slf4j.LoggerFactory;
public class Permissions extends Concept {
private String tournamentID;
public Permissions(ToornamentClient client, String tournamentID) {
super(client);
this.tournamentID = tournamentID;
logger = LoggerFactory.getLogger(this.getClass());
}
List<Permission> getPermissions() {
Builder urlBuilder = new Builder();
if (client.getScope().contains(Scope.ORGANIZER_PERMISSION)) {
urlBuilder
.scheme("https")
.host("api.toornament.com")
.addEncodedPathSegment("organizer")
.addEncodedPathSegment("v2")
.addEncodedPathSegment("tournaments")
.addEncodedPathSegment(tournamentID)
.addEncodedPathSegment("permissions");
}
logger.debug("url: {}", urlBuilder.build().toString());
Request request = client.getAuthenticatedRequestBuilder().get().url(urlBuilder.build()).build();
try {
String responseBody = client.executeRequest(request).body().string();
return mapper.readValue(
responseBody,
mapper
.getTypeFactory()
.constructCollectionType(List.class, Permission.class));
} catch (IOException | NullPointerException e) {
logger.error(e.getMessage());
throw new ToornamentException("Got IOException getting Permissions");
}
}
Permission getPermission(String permissionID) {
Builder url = new Builder();
if (client.getScope().contains(Scope.ORGANIZER_PERMISSION)) {
url.scheme("https")
.host("api.toornament.com")
.addEncodedPathSegment("organizer")
.addEncodedPathSegment("v2")
.addEncodedPathSegment("tournaments")
.addEncodedPathSegment(tournamentID)
.addEncodedPathSegment("permissions")
.addEncodedPathSegment(permissionID);
}
Request request = client.getRequestBuilder().get().url(url.build()).build();
try {
String responseBody = client.executeRequest(request).body().string();
return mapper.readValue(
responseBody,
mapper.getTypeFactory().constructType(com.toornament.model.Permission.class));
} catch (IOException | NullPointerException e) {
logger.error(e.getMessage());
throw new ToornamentException("Got IOException getting Permission.");
}
}
Permission createPermission(PermissionsQuery query) {
Builder url = new Builder();
if (client.getScope().contains(Scope.ORGANIZER_PERMISSION)) {
url.scheme("https")
.host("api.toornament.com")
.addEncodedPathSegment("organizer")
.addEncodedPathSegment("v2")
.addEncodedPathSegment("tournaments")
.addEncodedPathSegment(tournamentID)
.addEncodedPathSegment("permissions");
}
RequestBody body = RequestBody.create(ToornamentClient.JSON, query.toString());
Request request = client.getRequestBuilder().post(body).url(url.build()).build();
try {
String responseBody = client.executeRequest(request).body().string();
return mapper.readValue(
responseBody,
mapper.getTypeFactory().constructType(Permission.class));
} catch (IOException | NullPointerException e) {
logger.error(e.getMessage());
throw new ToornamentException("Error creating new permission");
}
}
Permission updatePermissions(
List<Attribute> attributes, String permissionID) {
Builder url = new Builder();
if (client.getScope().contains(Scope.ORGANIZER_PERMISSION)) {
url.scheme("https")
.host("api.toornament.com")
.addEncodedPathSegment("organizer")
.addEncodedPathSegment("v2")
.addEncodedPathSegment("tournaments")
.addEncodedPathSegment(tournamentID)
.addEncodedPathSegment("permissions")
.addEncodedPathSegment(permissionID);
}
String attributeString = "";
try {
attributeString =
new ObjectMapper()
.setSerializationInclusion(JsonInclude.Include.NON_NULL)
.writeValueAsString(attributes);
} catch (JsonProcessingException e) {
throw new ToornamentException(
"Couldn't create string from List of Attributes: " + e.getMessage());
}
RequestBody body = RequestBody.create(ToornamentClient.JSON, attributeString);
Request request = client.getRequestBuilder().patch(body).url(url.build()).build();
try {
String responseBody = client.executeRequest(request).body().string();
return mapper.readValue(
responseBody,
mapper.getTypeFactory().constructType(Permission.class));
} catch (IOException | NullPointerException e) {
logger.error(e.getMessage());
throw new ToornamentException("Error updating new permission");
}
}
Integer removePermission(String permissionsID) {
Builder url = new Builder();
if (client.getScope().contains(Scope.ORGANIZER_PERMISSION)) {
url.scheme("https")
.host("api.toornament.com")
.addEncodedPathSegment("organizer")
.addEncodedPathSegment("v2")
.addEncodedPathSegment("tournaments")
.addEncodedPathSegment(tournamentID)
.addEncodedPathSegment("permissions")
.addEncodedPathSegment(permissionsID);
}
Request request = client.getAuthenticatedRequestBuilder().delete().url(url.build()).build();
return client.executeRequest(request).code();
}
}
|
3e078a2a7ef0574121d16397f76398a6be314dd8
| 7,112 |
java
|
Java
|
jel-server/src/main/java/se/liquidbytes/jel/database/impl/actions/NewClass.java
|
trycoon/JEL
|
8da266dd3e4324c123411186f9abe9b423c73cdd
|
[
"Apache-2.0"
] | 1 |
2018-04-14T08:10:26.000Z
|
2018-04-14T08:10:26.000Z
|
jel-server/src/main/java/se/liquidbytes/jel/database/impl/actions/NewClass.java
|
trycoon/JEL
|
8da266dd3e4324c123411186f9abe9b423c73cdd
|
[
"Apache-2.0"
] | null | null | null |
jel-server/src/main/java/se/liquidbytes/jel/database/impl/actions/NewClass.java
|
trycoon/JEL
|
8da266dd3e4324c123411186f9abe9b423c73cdd
|
[
"Apache-2.0"
] | null | null | null | 34.862745 | 130 | 0.65734 | 3,197 |
/*
* Copyright 2015 Henrik Östman.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package se.liquidbytes.jel.database.impl.actions;
/**
*
* @author Henrik Östman
*/
public class NewClass {
/*
===========================================================================
| SITE - implementation
===========================================================================
*/
/*
@Override
public void getSite(String id, Handler<AsyncResult<String>> resultHandler) {
logger.debug("getSite(id=%s)", id);
try { OSQLSynchQuery<ODocument> query = new OSQLSynchQuery<>("select from Site where id = ?");
List<ODocument> list = dbDoc.command(query).execute(id);
String result = "";
if (!result.isEmpty()) {
result = list.get(0).toJSON();
}
resultHandler.handle(Future.succeededFuture(result));
} catch (Exception ex) {
resultHandler.handle(Future.failedFuture(new JelException("Failed to get site with id=" + id, ex)));
}
resultHandler.handle(Future.succeededFuture("test"));
}
@Override
public void getSites(Handler<AsyncResult<String>> resultHandler) {
logger.debug("getSites()");
throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
}
@Override
public void addSite(JsonObject document, Handler<AsyncResult<String>> resultHandler) {
logger.debug("addSite()");
throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
ODocument site = new ODocument("Sites");
site.field("name", "My site");
site.field("description", "");
site.field("gpsPosition", "");
site.field("sensors", new ODocument("City").field("name", "Rome").field("country", "Italy"));
site.save();
Id [string]("1234567890")
Name [string]("solar1")
Description [string]("My solar panel sensor")
GPS-position [string]("57.6378669 18.284855")
ACL_UserRoles [
userId:string
roles ["role1", "role2"]
ACL_Rights [string-array]("role1", "role2")
PublicVisible [boolean]
Sensors [
Id [string]("1234567890")
Name [string]("solar1")
Description [string]("My solar panel sensor")
GPS-position [string]("57.6378669 18.284855")
CurrentValue
Value [number(depending on ValueType)](24.0)
Time [date]("2014-12-24 18:23:20.212")
PreviousValue
Value [number(depending on ValueType)](24.3)
Time [date]("2014-12-24 18:23:20.212")
MaxValue
Value [number(depending on ValueType)](123.5)
Time [date]("2014-12-24 18:23:20.212")
MinValue
Value [number(depending on ValueType)](-55.0)
Time [date]("2014-12-24 18:23:20.212")
State [string]("connected"|"disconnected")
SampleDelay [number](10000)
Hardware
Id [string]
VendorId [string]
Port [string] ("/dev/USB2"|"/dev/ttyS0"|..)
ValueTransformation [string]("=i*0.5")
ValueType [string]("number"|"string")
ACL_Rights [string]("role1", "role2")
SmallPresentation:
Type [string]("text"|"gauge"|...)
Settings
MediumPresentation:
Type [string]("text"|"gauge"|...)
Settings
LargePresentation:
Type [string]("text"|"gauge"|...)
Settings
]
Actuators [
Id [string]("1234567890")
Name [string]("motor1")
Description [string]("My solar panel pump")
GPS-position [string]("57.6378669 18.284855")
CurrentValue
Value [number(depending on ValueType)]("on")
Time [date]("2014-12-24 18:23:20.212")
PreviousValue
Value [number(depending on ValueType)]("off")
Time [date]("2014-12-24 18:23:20.212")
State [string]("connected"|"disconnected")
Hardware
Id [string]
VendorId [string]
Port [string] ("/dev/USB2"|"/dev/ttyS0"|..)
ValueType [string]("number"|"string")
ACL_Rights [string]("role1", "role2")
SmallPresentation:
Type [string]("text"|"switch"|...)
Settings
MediumPresentation:
Type [string]("text"|"switch"|...)
Settings
LargePresentation:
Type [string]("text"|"switch"|...)
Settings
]
}
@Override
public void updateSite(JsonObject document, Handler<AsyncResult<String>> resultHandler) {
logger.debug("updateSite()");
throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
}
@Override
public void removeSite(String id, Handler<AsyncResult<String>> resultHandler) {
logger.debug("removeSite()");
OSQLSynchQuery<ODocument> query = new OSQLSynchQuery<>("select from Site where id = ?");
List<ODocument> list = dbDoc.command(query).execute(id);
Iterator<ODocument> iter = list.iterator();
while (iter.hasNext()) {
iter.next().delete();
}
resultHandler.handle(Future.succeededFuture("test"));
}*/
/*
===========================================================================
| USER - implementation
===========================================================================
*/
/* @Override
public void getUser(String id, Handler<AsyncResult<String>> resultHandler) {
logger.debug("getUser()");
throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
}
@Override
public void getUserByUsername(String username, Handler<AsyncResult<String>> resultHandler) {
logger.debug("getUserByUsername()");
throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
}
@Override
public void getUsers(Handler<AsyncResult<String>> resultHandler) {
logger.debug("getUsers()");
throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
}
@Override
public void addUser(JsonObject document, Handler<AsyncResult<String>> resultHandler) {
logger.debug("addUser()");
throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
}
@Override
public void updateUser(JsonObject document, Handler<AsyncResult<String>> resultHandler) {
logger.debug("updateUser()");
throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
}
@Override
public void removeUser(String id, Handler<AsyncResult<String>> resultHandler) {
logger.debug("removeUser()");
throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
}*/
}
|
3e078a55a5be9ced74154b7157b0eb2c85ade8a9
| 87,691 |
java
|
Java
|
Magit code/magit-engine/src/magitEngine/MagitEngine.java
|
shaniyu/MAGit-WebApp
|
ae1044440a38f174206c81e014fcfd3431897b5f
|
[
"MIT"
] | null | null | null |
Magit code/magit-engine/src/magitEngine/MagitEngine.java
|
shaniyu/MAGit-WebApp
|
ae1044440a38f174206c81e014fcfd3431897b5f
|
[
"MIT"
] | null | null | null |
Magit code/magit-engine/src/magitEngine/MagitEngine.java
|
shaniyu/MAGit-WebApp
|
ae1044440a38f174206c81e014fcfd3431897b5f
|
[
"MIT"
] | null | null | null | 47.196448 | 223 | 0.653203 | 3,198 |
package magitEngine;
import DataStructures.CommitChanges;
import DataStructures.MagitCommitNode;
import DataStructures.Tree;
import DataStructures.TreeNode;
import Exceptions.BranchAlreadyInUseException;
import Exceptions.FileNotInTree;
import Utils.Files.FilesOperations;
import Utils.SHA1;
import magitObjects.*;
import org.apache.commons.io.FileUtils;
import puk.team.course.magit.ancestor.finder.AncestorFinder;
import puk.team.course.magit.ancestor.finder.CommitRepresentative;
import xmlObjects.*;
import javax.xml.bind.JAXBContext;
import javax.xml.bind.JAXBException;
import javax.xml.bind.Marshaller;
import java.io.File;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.*;
import java.util.stream.Collectors;
import java.util.stream.Stream;
// this class the core of magit ("the game")
public class MagitEngine {
private Repository currentRepo;
private String userName;
//CommitChanges openChangesLists;
private List<String> deletedFiles;
private List<String> newFiles;
private List<String> changedFiles;
private XmlValidation xmlValidator;
private Dictionary<String, String> commitsSha1ToIdForExport;
// private Dictionary<String, String> foldersSha1ToIdForExport;
// private Dictionary<String, String> blobsSha1ToIdForExport;
private Dictionary<GitObject, String> foldersSha1ToIdForExport;
private Dictionary<GitObject, String> blobsSha1ToIdForExport;
// ctor for creating a new repository
public MagitEngine() {
//In case the program started and first thing i do is load repository from existing repository
//it couldn't execute loadRepositoryFromPath because repository was null in the beginning
//so i created an empty default constructor for Repository and Branch to initialize the repository.
currentRepo = null;
userName = "Administrator";
this.deletedFiles = new ArrayList<>();
this.newFiles = new ArrayList<>();
this.changedFiles = new ArrayList<>();
//openChangesLists = new CommitChanges(); //The constructor initializes the 3 lists
}
public List<Branch> getBranches()
{
return currentRepo.getAllOfTheBranches();
}
// public magitEngine.MagitEngine(MagitRepository magitRepository, String userName) {
// xmlValidator = new magitEngine.XmlValidation(magitRepository);
// currentRepo = null;
// this.userName = userName;
// deletedFiles = new ArrayList<>();
// newFiles = new ArrayList<>();
// changedFiles = new ArrayList<>();
// } // replaced by setXmlValidator
public void setXmlValidator(String userName, MagitRepository magitRepository)
{
xmlValidator = new XmlValidation(magitRepository);
currentRepo = null;
this.userName = userName;
this.deletedFiles = new ArrayList<>();
this.newFiles = new ArrayList<>();
this.changedFiles = new ArrayList<>();
}
// public void overrideRepoInLocation(MagitRepository magitRepository) throws IOException, Exception{
//
// String xmlRepositoryLocation = magitRepository.getLocation();
//
// if(currentRepo == null){
// currentRepo = new Repository();
// }
// //Clearing the existing repository from the WC, and branches + objects content
// currentRepo.clearRepository(xmlRepositoryLocation);
//
// currentRepo.spreadRepositoryFromXml(magitRepository);
// }
// public void createAndSpreadRepositoryFromXml(MagitRepository magitRepository) throws Exception{
//
// File repoFolder = new File(magitRepository.getLocation());
//
// if(!repoFolder.mkdir()){ //if creating the repository directory fails{
// throw new IOException("Could not create the folder " + repoFolder.getPath() + "\nCheck your permittions."); }
//
// if(currentRepo == null){
// currentRepo = new Repository();
// }
//
// currentRepo.spreadRepositoryFromXml(magitRepository);
// }
public void pushNewCommitsToRemoteTargetBranch(String targetBranch, HashSet<String> commitsDelta) throws Exception
{
// the remote repo of repoName by userName, has already the branch targetBranch, just push to it the new commit
// that tagetBranch has in the LR repoName by userName
// should get the current commit of the RTB of remoteBranch and get all the delta from the RTB in out repository to the remoteBranch
// including zip files of commits, folders, files, branches
// get the sha1 of the LR target branch
File targetBranchFileInLocal = new File(currentRepo.getBranchesPath() + File.separator + targetBranch);
String branchSha1 = FileUtils.readFileToString(targetBranchFileInLocal, StandardCharsets.UTF_8);
// zip file representing a commit in the remote repository
File sha1ZipFile = new File(currentRepo.getRemoteRepoPath() + File.separator
+ ".magit" + File.separator
+ "objects" + File.separator
+ branchSha1 + ".zip");
if (sha1ZipFile.exists()){// we already have this commit in the remote repo
//Still need to add it to the commits that were changed in the PR (even if the commit itself exists in the repository)
commitsDelta.add(branchSha1);
return;
}
else
{
// we don't have this commit and its files on the remote repo, lets bring it
reccursiveFetchCommitFromLocalToRemote(branchSha1, commitsDelta);
}
}
public boolean isBranchRTB(String inputBranchName) throws IOException{
// check if we have a RTB for the branch in the file RTB
String RTBFilePath = currentRepo.getMagitPath() + File.separator + "RTB";
ArrayList<String> RTBContent = FilesOperations.readAllContentFromFileByStrings(RTBFilePath);
for (int i = 0 ; i < RTBContent.size(); i+=3)
{
String branchName = RTBContent.get(i);
if (branchName.equals(inputBranchName))
return true;
}
return false;
}
//This method accepts one commit and one commit sha1 (commitToCalculateChanges and commitSha1Original)
//and calculates the open changes of commitToCalculateChanges relatively to commitSha1Original)
//It spreads the WC of commitToCalculateChanges in a temp folder in .magit folder, and builds a git object tree from commitSha1Original
//then calculates the open changes the same way as calculated on the WC with updateAllOpenChangesOfWC
//This method doesn't check if commitChangesToUpdate is null!!!!!!!!
// the list that are created contains relative path of each file, starting *after* the fullPathToSpreadTo
public void calculateChangesBetween2Commits(Commit commitToCalculateChanges, String commitSha1Original, CommitChanges commitChangesToUpdate, String fullPathToSpreadTo, String pathNameToSpread) throws Exception{
//File tempFolder = new File(currentRepo.getMagitPath() + File.separator + "temp");
File tempFolder = new File(fullPathToSpreadTo);
//Creating the temp folder in which we spread the "WC" of commitToCalculateChanges
spreadCommitToCheckInTemp(tempFolder, commitToCalculateChanges.getSha1());
//Getting all files of commitToCalculateChanges from temp folder
Stream<Path> fileWalk = Files.walk(Paths.get(tempFolder.getPath()));
List<String> allFilePathsInCommitToCalculateChanges = fileWalk.filter(Files::isRegularFile)//Getting all text files in repository folder
.map(x -> x.toString())
.collect(Collectors.toList());//Getting list of the files paths
clearAllChangesOfCommit(commitChangesToUpdate);
//Calculating gitObjectTree of commitSha1Original
Tree originalCommitGitObjectTree = currentRepo.initializeGitObjectTreeForCommit(commitSha1Original);
//Checking changes in files between commitToCalculateChanges and commitSha1Original
for(String filePathToCheck : allFilePathsInCommitToCalculateChanges){
try{
//If the file exists in the tree but it was changed
if(currentRepo.checkIfFileOrFolderChangedForCommit(filePathToCheck,"", originalCommitGitObjectTree, pathNameToSpread))
{
String relativePath = filePathToCheck.substring(fullPathToSpreadTo.length() +1);
commitChangesToUpdate.addToChangedFiles(relativePath);
}
}
// if the file wasn't in the tree, it is new, then we get FileNotInTree exception
//If the file didn't exist in the tree- it's a new file
catch (FileNotInTree e){
String relativePath = filePathToCheck.substring(fullPathToSpreadTo.length() +1);
commitChangesToUpdate.addToNewFiles(relativePath);
}
catch (IOException e){
throw new IOException("Couldn't read from file " + filePathToCheck + ". Please check your permissions");
}
}
//Getting deleted files between commitToCalculateChanges and commitSha1Original
if(originalCommitGitObjectTree != null) {
findAndSetDeletedFilesInGitObjectTree(originalCommitGitObjectTree.getRoot(), commitChangesToUpdate.getDeletedFiles());
}
}
public void spreadCommitToCheckInTemp(File tempFolder, String commitSha1ToCalculateChanges) throws Exception{
//Initializing the temp folder
if(tempFolder.exists()) {
if (!deleteTempFolder(tempFolder)){
throw new IOException("Could not delete some of the files in the temp folder");
}
}
if(!tempFolder.mkdir()){
throw new Exception("Couldn't create temp folder in .magit folder");
}
//Spreading commitSha1ToCalculateChanges files to temp folder
currentRepo.putCommitContentOnTempFolder(commitSha1ToCalculateChanges, tempFolder);
}
//This function is exactly like FilesOperations.deleteFolder
//but i needed to know if the deletion succeeded and didn't want to change the existing one
// (FilesOperations.deleteFolder doesn't return true/false)
private boolean deleteTempFolder(File folder) {
File[] files = folder.listFiles();
if (files != null) { //some JVMs return null for empty dirs
for (File f : files) {
if (f.isDirectory()) {
if (!deleteTempFolder(f)) {
return false;
}
} else {
if (!f.delete()) {
return false;
}
}
}
}
if(!folder.delete()){
return false;
}
return true;
}
public void updateAllOpenChangesOfWC() throws Exception {
Stream<Path> fileWalk = Files.walk(Paths.get(currentRepo.getRepositoryLocation()));
clearAllOpenChangesOfWC();
if(currentRepo.getGitObjectTree() != null){
//Need to reset all git objects' wasChecked flags before checking status
resetGitObjectTreeWasChecked(currentRepo.getGitObjectTree().getRoot());
}
List<String> allFilePathsInWC = fileWalk.filter(Files::isRegularFile) //Getting all text files in repository folder
.filter(x-> !(x.toAbsolutePath().toString().contains(".magit"))) //Excluding any file paths that contain ".magit"
.map(x -> x.toString()).collect(Collectors.toList()); //Getting list of the files paths
//If there is no commit in the repository then all files in the WC are new
if(!currentRepo.isThereAnyCommitInTheRepository(currentRepo.getRepositoryLocation())){
for(String filePathToCheck : allFilePathsInWC){
newFiles.add(filePathToCheck);
}
}
else{ //If there is at least one commit in the repository then we need to check
//all new/changes/deleted files relatively to the current commit.
for(String filePathToCheck : allFilePathsInWC){
try{
//If the file exists in the tree but it was changed
if(currentRepo.checkIfFileOrFolderChanged(filePathToCheck,""))
{
changedFiles.add(filePathToCheck);
}
// if the file wasn't in the tree, it is new, then we get FileNotInTree exception
}
//If the file didn't exist in the tree- it's a new file
catch (FileNotInTree e){
newFiles.add(filePathToCheck);
}
catch (IOException e){
throw new IOException("Couldn't read from file " + filePathToCheck + ". Please check your permissions");
}
}
}
if(currentRepo.getGitObjectTree() != null) {
findAndSetDeletedFilesInGitObjectTree(currentRepo.getGitObjectTree().getRoot(), deletedFiles);
}
}
private void clearAllOpenChangesOfWC(){
deletedFiles.clear();
newFiles.clear();
changedFiles.clear();
}
private void clearAllChangesOfCommit(CommitChanges commitChangesToUpdate){
commitChangesToUpdate.getDeletedFiles().clear();
commitChangesToUpdate.getNewFiles().clear();
commitChangesToUpdate.getChangedFiles().clear();
}
private void resetGitObjectTreeWasChecked(TreeNode root) {
if(root == null){
return;
}
else if (root.getmChildren() == null){
root.getmNode().setWasChecked(false);
}
else{
for(TreeNode child : root.getmChildren()){
if(child.getmNode().getmFolderType() == FolderType.FOLDER){
child.getmNode().setWasChecked(false);
resetGitObjectTreeWasChecked(child);
}
else{ //child is a file
child.getmNode().setWasChecked(false);
}
}
}
}
private void findAndSetDeletedFilesInGitObjectTree(TreeNode root, List<String> deletedFiles) {
if (root == null){
return;
}
else if(root.getmChildren() == null){
//Since when performing git status we go through all of the files (not directories)
//in the WC- then the assumption is that if there's a file in the GitObject tree
//that we haven't proccessed- then it was at some point in the WC (because it's in the tree)
//but was deleted later on so we won't look for it in the tree. In this case- the wasChecked
//flag will be false for this gitObject that represents a file, and we want to add it to deletedFiles.
if(root.getmNode().getmFolderType() == FolderType.FILE && !(root.getmNode().getWasChecked())){
// Important! we skip the first word, which is the repository directory name, and add only the relayive path od the file in the repo
// for example : WRONG: /test1/1/2/yuval.txt. CORRECT: 1/2/yuval.txt
String nameOfFileWithoudRepoName = root.getmNode().getmPath().substring(currentRepo.getRepoFolderName().length() +1);
deletedFiles.add(nameOfFileWithoudRepoName);
}
}
else{
for(TreeNode child : root.getmChildren()){
if (child.getmNode().getmFolderType() == FolderType.FOLDER){
findAndSetDeletedFilesInGitObjectTree(child, deletedFiles);
}
else{ //if current git object is a file
if (!(child.getmNode().getWasChecked())){
String nameOfFileWithoudRepoName = child.getmNode().getmPath().substring(currentRepo.getRepoFolderName().length() +1);
deletedFiles.add(nameOfFileWithoudRepoName);
}
}
}
}
}
// private String fullPathFromPartialRepoPath(String partialPath)
// {
// int indexWithoutRepoFolder = partialPath.indexOf(File.separator) +1;
// String fullPathOfObject = getRepositoryLocation() + File.separator + partialPath.substring(indexWithoutRepoFolder);
// return fullPathOfObject;
// }
public static boolean isPathAlreadyARepo(String path) {
// true <=> existing folder .magit -> objects & branches
File repositoryPath = new File(path);
if (!repositoryPath.exists()) {
// this path doesn't exist, so it is not a magit repository.
return false;
} else {
// path does exist
File magitFolder = new File(path + File.separator + ".magit");
if (!magitFolder.exists())
return false;
}
return true;
}
public String getUserName() {
return userName;
}
public void setUserName(String userName) {
this.userName = userName;
}
public String getRepositoryLocation() {
if (currentRepo == null) {
return "N\\A";
}
return currentRepo.getRepositoryLocation();
}
public String showAllBranches() throws IOException{
String allBranchesInfo = "";
for (Branch branch : currentRepo.getAllOfTheBranches()) {
allBranchesInfo += getBranchInfo(branch);
allBranchesInfo += "\n";
}
return allBranchesInfo;
}
public String showAllBranchesNames()
{
String allBranchesNames = ("");
for (Branch branch : currentRepo.getAllOfTheBranches()) {
allBranchesNames += branch.getName() + "\n";
}
return allBranchesNames;
}
public ArrayList<String> getAllBranchesNames()
{
ArrayList<String> allBranchesNames = new ArrayList<>();
for (Branch branch : currentRepo.getAllOfTheBranches())
{
allBranchesNames.add(branch.getName());
}
return allBranchesNames;
}
private String getBranchInfo(Branch branch) throws IOException{
String informationToShow = null;
if (branch != null) {
// branch name + sha1 of its commit
informationToShow= branch.getName();
// if there is a commit on the branch ( the only case there isn't, is on new repository)
if (branch.getCommit() != null && branch.getCommit().getSha1() != null && ! branch.getCommit().getSha1().isEmpty()) {
String branchSha1 = branch.getCommit().getSha1();
informationToShow += " : " + branchSha1 + ", ";
//read the fourth line in the commit zip file, that has the commit message
informationToShow += (FilesOperations.readAllContentFromZipFileByStrings(currentRepo.getObjectsPath() + File.separator + branchSha1 + ".zip")).get(3);
}
// put a sign on the current branch
if (currentRepo.getHeadBranch().getName().equals(branch.getName())) {
informationToShow += " <--- HEAD";
}
}
return(informationToShow);
}
public boolean isBranchTheHeadBranch(String branchName)
{
return currentRepo.getHeadBranch().getName().equals(branchName);
}
public void addNewBranch(String newBranchName) throws BranchAlreadyInUseException, IOException {
// creating a new branch on the head commit, if there isn't branch with this name
Branch newBranch = new Branch(newBranchName, currentRepo.getHeadBranch().getCommit());
if (!currentRepo.getAllOfTheBranches().contains(newBranch)) {
currentRepo.addNewBranch(newBranch);
String newBranchPath = currentRepo.getRepositoryLocation() + File.separator + ".magit" + File.separator +
"branches" + File.separator + newBranchName;
File newBranchFile = new File(newBranchPath);
if ( ! newBranchFile.exists())
{
boolean success = newBranchFile.createNewFile();
if (newBranch.getCommit() != null)
{
FilesOperations.writeTextToFile(newBranch.getCommit().getSha1(), newBranchPath);
}
}
}
else
throw new BranchAlreadyInUseException(newBranchName);
}
public void addNewBranchOnSpecificCommit(String newBranchName, Commit commit) throws BranchAlreadyInUseException, IOException {
// creating a new branch on the commit, if there isn't branch with this name
Branch newBranch = new Branch(newBranchName, commit);
if (!currentRepo.getAllOfTheBranches().contains(newBranch)) {
currentRepo.addNewBranchOnSpecificCommit(newBranch, commit);
String newBranchPath = currentRepo.getRepositoryLocation() + File.separator + ".magit" + File.separator +
"branches" + File.separator + newBranchName;
File newBranchFile = new File(newBranchPath);
if ( ! newBranchFile.exists())
{
boolean success = newBranchFile.createNewFile();
if (newBranch.getCommit() != null)
{
FilesOperations.writeTextToFile(newBranch.getCommit().getSha1(), newBranchPath);
}
}
}
else
throw new BranchAlreadyInUseException(newBranchName);
}
public void setCurrentRepo(Repository currentRepo) {
this.currentRepo = currentRepo;
}
public Repository getCurrentRepo() {
return currentRepo;
}
public ArrayList<String> getHistoryOfActiveBranch() throws IOException
{
ArrayList<String> history = currentRepo.getHistoryOfActiveBranch();
return history;
}
public List<String> getDeletedFiles() {
return deletedFiles;
}
public void setDeletedFiles(List<String> deletedFiles) {
this.deletedFiles = deletedFiles;
}
public List<String> getNewFiles() {
return newFiles;
}
public void setNewFiles(List<String> newFiles) {
this.newFiles = newFiles;
}
public List<String> getChangedFiles() {
return changedFiles;
}
public void setChangedFiles(List<String> changedFiles) {
this.changedFiles = changedFiles;
}
public void checkOutToBranch(String branchNameToCheckout) throws Exception
{
currentRepo.checkOutToBranch(branchNameToCheckout);
}
public void deleteBranch(String branchToDelete) throws IOException, Exception
{
currentRepo.deleteBranch(branchToDelete);
}
public String createCommit( String messageFromUser, String secondParentSha1 ) throws Exception
{
String newCommitSha1 = null ;
if (!(currentRepo.isThereAnyCommitInTheRepository(currentRepo.getRepositoryLocation()))){
//Do first commit for repository
newCommitSha1 = currentRepo.CreateFirstCommit(userName, messageFromUser);
}
else{
//Do commit for repository, merge commits is only a not-first commit
newCommitSha1 = currentRepo.CreateCommitNotFirst(userName, messageFromUser, secondParentSha1);
}
return newCommitSha1;
}
public boolean isThereOpenChangesInRepository() throws Exception
{
if (currentRepo.getGitObjectTree() == null)
{
Stream<Path> fileWalk = Files.walk(Paths.get(currentRepo.getRepositoryLocation()));
List<String> allFilePathsInWC = fileWalk.filter(x-> !(x.toAbsolutePath().toString().contains(".magit")))//Excluding any file paths that contain ".magit"
.filter(Files::isRegularFile)//Excluding any folders that don't contain regular files (which are empty folders to the system)
.map(x -> x.toString()).collect(Collectors.toList()); //Getting list of the files paths
return !(allFilePathsInWC.size() == 0); // if there are no regular files in the repository then we don't have open changes
}
else
{
updateAllOpenChangesOfWC();
// some of the files has been changed somehow, so there are changes
return (deletedFiles.size() > 0 || newFiles.size() > 0 || changedFiles.size() > 0);
}
}
public void createEmptyRepository(String repoPath, String repoName) throws IOException
{
setCurrentRepo(new Repository(repoPath, repoName));
}
public String getRepositoryName()
{
return currentRepo.getRepositoryName();
}
public boolean isACommit(String sha1ToCheck) throws IOException
{
//check if the sha1 is one of the commits, by iterating over all the sha1's in .magit/branches/commits file
ArrayList<String> commitsSha1List =getAllCommitsSha1();
return commitsSha1List.contains(sha1ToCheck);
}
public ArrayList<String> getAllCommitsSha1() throws IOException
{
// read all sha1's in commits file
String commitsFilePath = currentRepo.getBranchesPath() + File.separator + "commits";
ArrayList<String> commitsSha1List = FilesOperations.readAllContentFromFileByStrings(commitsFilePath);
return commitsSha1List;
}
public void resetBranchSha1(String sha1ToReset) throws Exception
{
currentRepo.resetHeadBranchSha1(sha1ToReset);
}
public void continueWithExistingReposotory(String repositoryPath) throws Exception{
if(currentRepo == null){
setCurrentRepo(new Repository());
}
// set the repository
currentRepo.loadRepositoryFromPath(repositoryPath);
}
public XmlValidation getXmlValidator() {
return xmlValidator;
}
public void exportRepoToXml(String pathOfXmlFileToExport) throws JAXBException, IOException
{
MagitRepository thisRepo = buildMagitRepositoryFromCurrentRepo();
File file = new File(pathOfXmlFileToExport);
JAXBContext jaxbContext = JAXBContext.newInstance(MagitRepository.class);
Marshaller jaxbMarshaller = jaxbContext.createMarshaller();
// output pretty printed
jaxbMarshaller.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, true);
jaxbMarshaller.marshal(thisRepo, file);
jaxbMarshaller.marshal(thisRepo, System.out);
}
private MagitRepository buildMagitRepositoryFromCurrentRepo() throws IOException
{
commitsSha1ToIdForExport = new Hashtable<>(); // dictionary for sha1-id pairs for commits
foldersSha1ToIdForExport = new Hashtable<>(); // dictionary for sha1-id pairs for folders
blobsSha1ToIdForExport = new Hashtable<>(); // dictionary for sha1-id pairs for blobs
// set all commit id from the commits text file
String commitsFilePath = currentRepo.getBranchesPath() + File.separator + "commits";
// list of sha1s
ArrayList<String> allOfRepositoryCommitsSha1 = FilesOperations.readAllContentFromFileByStrings(commitsFilePath);
initializeCommitsDictionary(allOfRepositoryCommitsSha1);
MagitRepository res = new MagitRepository();
// set name and location
res.setName(currentRepo.getRepositoryName());
res.setLocation(currentRepo.getRepositoryLocation());
//set branches
MagitBranches repositoryBranches = getMagitBranches();
res.setMagitBranches(repositoryBranches);
// set commits, and also set folders and blobs dictionary
MagitCommits allRepoCommits = getMagitCommits(allOfRepositoryCommitsSha1);
res.setMagitCommits(allRepoCommits);
// set folders and blobs of every commit in the repoistory
MagitBlobs blobs = new MagitBlobs();
MagitFolders folders = new MagitFolders();
setFoldersAndBlobs(allOfRepositoryCommitsSha1, blobs, folders);
res.setMagitBlobs(blobs);
res.setMagitFolders(folders);
return res;
}
//
private void setFoldersAndBlobs(ArrayList<String> allOfRepositoryCommits, MagitBlobs blobs, MagitFolders folders)
throws IOException
{
for ( String sha1OfCommit : allOfRepositoryCommits)
{
// for each commit. update blobs and folders objects
String commitPath = getObjectsPath() + File.separator + sha1OfCommit + ".zip";
ArrayList<String > commitDetails = FilesOperations.readAllContentFromZipFileByStrings(commitPath);
String currCommitRootFolderSha1 = commitDetails.get(0);
// add the root folder itself to folders
MagitSingleFolder rootFolder = new MagitSingleFolder();
rootFolder.setIsRoot(true);
rootFolder.setName("");
rootFolder.setLastUpdateDate(commitDetails.get(4));
rootFolder.setLastUpdater(commitDetails.get(5));
// get the root folder id , using only name,sha1 and type of GitObject
GitObject folderObject = new GitObject("",null, currCommitRootFolderSha1, FolderType.FOLDER, null, null);
rootFolder.setId(foldersSha1ToIdForExport.get(folderObject));
// add all the items of the root folder to its items
addItemsToFolder(currCommitRootFolderSha1, rootFolder);
// root folder is now initialized, add it to folders
// no need to check existence, because root folders must be uniqe
folders.addFolderToFolders(rootFolder);
// call recursive to any other folders and blobs
recursiveSetFoldersAndBlobsOfRepo(currCommitRootFolderSha1, blobs, folders);
}
}
// add values to blobs and folders Magit objects
private void recursiveSetFoldersAndBlobsOfRepo(String folderSha1, MagitBlobs blobs, MagitFolders folders) throws IOException
{
// gets a sha1 of folder, and recursively changing blobs and folders
String folderSha1FilePath= getObjectsPath() + File.separator + folderSha1 + ".zip";
File folderDescriptionFile = new File(folderSha1FilePath);
// list all of the obejcts in this dir
ArrayList<GitObject> objectsOfCurrentDir = Repository.getAllObjectsOfDirectory(folderDescriptionFile);
for ( GitObject object : objectsOfCurrentDir)
{
if (object.getmFolderType().equals(FolderType.FILE))
{
// this object is a file, we don't need a recursive call
MagitBlob blob = new MagitBlob();
String blobId = blobsSha1ToIdForExport.get(object);
// perform this part only if this blob wasn't added yet to blobs
if ( ! blobs.isBlobInTheList(blobId))
{
blob.setId(blobId);
blob.setName(object.getmName());
blob.setLastUpdater(object.getmLastModifiedBy());
blob.setLastUpdateDate(object.getmLastModifiedDate());
// set content
String fileContentPath = getObjectsPath() + File.separator + object.getmSHA1() + ".zip";
blob.setContent(FilesOperations.readAllContentFromZipFile(fileContentPath)); // read from file
// add blob to the list only if it is not already in ( might happen by another commit)
blobs.addBlobToBlobs(blob);
}
}
else if (object.getmFolderType().equals(FolderType.FOLDER))
{
MagitSingleFolder folder = new MagitSingleFolder();
String folderId = foldersSha1ToIdForExport.get(object);
// perform this part only if this folder wasn't added yet to folders
if (! folders.isFolderInTheList(folderId))
{
folder.setId(folderId);
folder.setName(object.getmName());
folder.setLastUpdater(object.getmLastModifiedBy());
folder.setLastUpdateDate(object.getmLastModifiedDate());
folder.setIsRoot(false);
// initialize items of this folder
addItemsToFolder(object.getmSHA1() , folder);
folders.addFolderToFolders(folder);
// call recursively on this folder
recursiveSetFoldersAndBlobsOfRepo(object.getmSHA1(), blobs, folders);
}
}
}
}
// this method add to the magit single folder argument, all of its items, based on the list of GitObject it has
private void addItemsToFolder( String folderSha1, MagitSingleFolder folder) throws IOException
{
// the file of the folder description
File currFolderFile = new File(getObjectsPath() + File.separator + folderSha1 + ".zip");
ArrayList<GitObject> objectsList = Repository.getAllObjectsOfDirectory(currFolderFile); // might throws IOException
// iterate over this folder objects
for (GitObject objectOfFolder : objectsList)
{
// add contained item ( folder\blob) to the current folder items list
Item item = new Item();
if (objectOfFolder.getmFolderType().equals(FolderType.FILE)) {
item.setType("blob");
item.setId(blobsSha1ToIdForExport.get(objectOfFolder));
}
else {
item.setType("folder");
item.setId(foldersSha1ToIdForExport.get(objectOfFolder));
}
folder.addItemToItems(item);
}
}
// also sets folders and blobs dictionaries
private MagitCommits getMagitCommits(ArrayList<String> allOfRepositoryCommits) throws IOException
{
MagitCommits res = new MagitCommits();
for ( String commitSha1 : allOfRepositoryCommits) // iterate over commits
{
MagitSingleCommit currCommit = new MagitSingleCommit();
currCommit.setId(commitsSha1ToIdForExport.get(commitSha1)); // set commit id by dictionary
String commitPath = getObjectsPath() + File.separator + commitSha1 + ".zip";
ArrayList<String > commitDetails = FilesOperations.readAllContentFromZipFileByStrings(commitPath);
String commitMsg;
String commitAuthor;
String dateOfCreating;
// initialize root folder id
String sha1OfRoot = commitDetails.get(0);
// initialize preceding commits
String firstParentSha1 = commitDetails.get(1);
String secondParentSha1 = commitDetails.get(2);
// initializ simple fields
commitMsg = commitDetails.get(3);
dateOfCreating = commitDetails.get(4);
commitAuthor = commitDetails.get(5);
currCommit.setMessage(commitMsg);
currCommit.setDateOfCreation(dateOfCreating);
currCommit.setAuthor(commitAuthor);
//initialize preceding commits
PrecedingCommits parentsOfThisCommit = new PrecedingCommits();
if (!firstParentSha1.equals("null"))
{
String idOfCommitFirstParent = commitsSha1ToIdForExport.get(firstParentSha1);
parentsOfThisCommit.addPrecedingCommit(idOfCommitFirstParent);
}
if (!secondParentSha1.equals("null"))
{
String idOfCommitSecondParent = commitsSha1ToIdForExport.get(secondParentSha1);
parentsOfThisCommit.addPrecedingCommit(idOfCommitSecondParent);
}
currCommit.setPrecedingCommits(parentsOfThisCommit);
// initialize root folder id of current commit, and also all of the blobs and folders of this commit
//adding root folder to foldersSha1ToIdForExport dictionary
GitObject rootFolderObject = new GitObject("",
null,
commitDetails.get(0),
FolderType.FOLDER,
dateOfCreating,
commitAuthor);
foldersSha1ToIdForExport.put(rootFolderObject, Integer.toString(foldersSha1ToIdForExport.size()+1));
initializeFoldersAndBlobsDictionary(commitDetails.get(0));
// set id of root folder, by using the folders dictionary
currCommit.getRootFolder().setId(foldersSha1ToIdForExport.get(rootFolderObject));
// add to the list of res
res.addCommitToList(currCommit);
}
return res;
}
private String getObjectsPath()
{
return currentRepo.getObjectsPath();
}
private void initializeCommitsDictionary(ArrayList<String> allCommitsSha1)
{
// add all sha1-id pairs to dictionary
int id = 1;
for (String sha1 : allCommitsSha1)
{
commitsSha1ToIdForExport.put(sha1, Integer.toString(id));
id++;
}
}
// recursive function to initialize blobs and folders dictionaries
// first called with the root folder sha1
private void initializeFoldersAndBlobsDictionary(String folderSha1) throws IOException
{
String workingCopyFilePAth = getObjectsPath() + File.separator + folderSha1 + ".zip";
File workingCopyDescriptionFile = new File(workingCopyFilePAth); // the path to the file that describes the WC
// get all the objects in the root folder of the current commit and add to the dictionaries
ArrayList<GitObject> objectsOfCurrentRoot = Repository.getAllObjectsOfDirectory(workingCopyDescriptionFile);
for ( GitObject object : objectsOfCurrentRoot)
{
if (object.getmFolderType().equals(FolderType.FOLDER))
{
if (foldersSha1ToIdForExport.get(object) == null)
{
// key not in the hashmap - put it now
// insert key with id value that depends on the dictionary size, starting from 1
String newId = Integer.toString(foldersSha1ToIdForExport.size()+1);
foldersSha1ToIdForExport.put(object, newId );
// recursive call to this function with the current folder sha1
initializeFoldersAndBlobsDictionary(object.getmSHA1());
}
}
else if (object.getmFolderType().equals(FolderType.FILE))
{
if (blobsSha1ToIdForExport.get(object) == null )
{
// key not in the hashmap - put it now
// insert key with id value that depends on the dictionary size, starting from 1
String newId = Integer.toString(blobsSha1ToIdForExport.size() +1);
blobsSha1ToIdForExport.put(object, newId);
}
}
}
}
private MagitBranches getMagitBranches()
{
// not relevant for exercise 2, only bonus at ex 1
MagitBranches res = new MagitBranches();
ArrayList<MagitSingleBranch> singleBranches = new ArrayList<>();
res.setHead(currentRepo.getHeadBranch().getName()); // initialize head name
// initialize all the single branches
for (Branch branch : currentRepo.getAllOfTheBranches())
{
MagitSingleBranch currBranch = new MagitSingleBranch();
currBranch.setName(branch.getName()); // set name
// set id of pointed commit
if (branch.getCommit() != null)
{
currBranch.getPointedCommit().setId(commitsSha1ToIdForExport.get(branch.getCommit().getSha1()));
}
else
{
currBranch.getPointedCommit().setId("");
}
// not tracking and not remote
currBranch.setIsRemote(false);
currBranch.setTracking(false);
singleBranches.add(currBranch);
}
res.setMagitSingleBranch(singleBranches);
return res;
}
//This method accepts 2 commit sha1s and finds the most recent common ancestor of them
//It uses Aviad's AncestorFinder library
public Commit getMostRecentCommonAncestor(String firstCommitSha1, String secondCommitSha1)throws Exception{
//AncestorFinder accepts a function that accepts SHA1 (String) and its return value is CommitRepresentative
//which is an interface that is defined in AncestorFinder library
//Our Commit class implements this interface
AncestorFinder ancestorFinder = new AncestorFinder(this::mapSha1ToCommitRepresentative);
String ancestorCommitSha1 = ancestorFinder.traceAncestor(firstCommitSha1, secondCommitSha1);
//returning the commit object of the most recent common ancestor
return currentRepo.getCommitTree().getSha1ToNodesDictionary().get(ancestorCommitSha1).getCommit();
}
//The function sent to AncestorFinder
public CommitRepresentative mapSha1ToCommitRepresentative(String commitSHA1){ //throws Exception{
//Find the MagitCommitNode by sha1 in the dictionary, and return the commit held in is which implements CommitRepresentative
MagitCommitNode magitCommitNode = currentRepo.getCommitTree().getSha1ToNodesDictionary().get(commitSHA1);
return magitCommitNode.getCommit();
}
public Dictionary<String, MagitCommitNode> getTreeNodesDictinary()
{
return currentRepo.getCommitTree().getSha1ToNodesDictionary();
}
// we can assume the sha1 of the two commits are different
public Boolean mergeIsFastForward(String sha1OfCommit1, String sha1OfCommit2, String sha1OfAncenstor)
{
return (sha1OfCommit1.equals(sha1OfAncenstor) || sha1OfCommit2.equals(sha1OfAncenstor));
}
// this method initialize headCommitChangesToAncenstor and theirsCommitChangesToAncenstor with
// the differences between each branch top to the ancenstor commit, the result is a union of the 6 lists
// the method also spread ansenstor commit to a ancenstor folder under .magit folder
public HashSet<String> createListOfChangedFilesInTwoBranches(Commit commitOfBRanchToMerge, String ancenstorSha1, CommitChanges headCommitChangesToAncenstor, CommitChanges theirsCommitChangesToAncenstor) throws Exception
{
// compare "theirs" with ancenstor
calculateChangesBetween2Commits(commitOfBRanchToMerge , ancenstorSha1, theirsCommitChangesToAncenstor, getCurrentRepo().getMagitPath() + File.separator + "theirs", "theirs");
calculateChangesBetween2Commits(getCurrentRepo().getHeadBranch().getCommit(), ancenstorSha1, headCommitChangesToAncenstor, getCurrentRepo().getMagitPath() + File.separator + "head", "head");
// spread the ancenstor commit to a path in magit folder
File pathToSpreadAncenstor = new File(getCurrentRepo().getMagitPath() + File.separator + "ancenstor");
if (pathToSpreadAncenstor.exists())
{
// delete this temp folder from last time
FilesOperations.deleteFolder(pathToSpreadAncenstor);
}
pathToSpreadAncenstor.mkdirs(); // create the folder
getCurrentRepo().putCommitContentOnTempFolder(ancenstorSha1, pathToSpreadAncenstor);
// unite all the lists of any kind of changes to one big list, from both ancenstor-head, ancenstor-theirs calculations
HashSet<String> filesThatChangesAndMightCauseConflicts = new HashSet<>();
filesThatChangesAndMightCauseConflicts.addAll(headCommitChangesToAncenstor.getDeletedFiles());
filesThatChangesAndMightCauseConflicts.addAll(headCommitChangesToAncenstor.getChangedFiles());
filesThatChangesAndMightCauseConflicts.addAll(headCommitChangesToAncenstor.getNewFiles());
filesThatChangesAndMightCauseConflicts.addAll(theirsCommitChangesToAncenstor.getDeletedFiles());
filesThatChangesAndMightCauseConflicts.addAll(theirsCommitChangesToAncenstor.getChangedFiles());
filesThatChangesAndMightCauseConflicts.addAll(theirsCommitChangesToAncenstor.getNewFiles());
// return the union
return filesThatChangesAndMightCauseConflicts;
}
public ArrayList<String> calculateConflictedFilesListAndHandleNonConflictedFiles(HashSet<String> filesThatChangesAndMightCauseConflicts, CommitChanges headCommitChangesToAncenstor,
CommitChanges theirsCommitChangesToAncenstor, String branchToMergeWith) throws Exception {
ArrayList<String> filesWithConflicts = new ArrayList<>();
// iterate all the files in filesThatChangesAndMightCauseConflicts and define the match case of it - conflict or not
for (String filePath : filesThatChangesAndMightCauseConflicts) {
if (isFileHasConflict(filePath, headCommitChangesToAncenstor, theirsCommitChangesToAncenstor)) {
filesWithConflicts.add(filePath);
} else {
// this file was changed, but this changes doesn't make a conflict
// no conflict on this file, take the file from where it was changed - theirs or head, and put on WC
// the file is the the list of files that was changed, so one of the commits must have changed it
putUpdatedFileOnWc(filePath, headCommitChangesToAncenstor, theirsCommitChangesToAncenstor);
// ENGINE CODE
// if a file wasn't changed at all from ancenstor to both commits, it won't be in the hasSet
// and it is already in the WC so no need to update it
}
}
return filesWithConflicts;
}
private Boolean isFileHasConflict(String filePath, CommitChanges headCommitChangesToAncenstor, CommitChanges theirsCommitChangesToAncenstor) throws Exception
{
// find the match case to each file that has changed somehow by one of the branches
// use xor to tell if the file was changed *only* in one branch, so it is not a conflict
if (headCommitChangesToAncenstor.isFileInTheListsUnion(filePath) ^ theirsCommitChangesToAncenstor.isFileInTheListsUnion(filePath))
{
return false;
}
else if(headCommitChangesToAncenstor.getDeletedFiles().contains(filePath) && theirsCommitChangesToAncenstor.getDeletedFiles().contains(filePath))
{
return false;
// because both of the branches deleted this file in some point, this is not a conflict
}
else if ((headCommitChangesToAncenstor.getNewFiles().contains(filePath) ||
headCommitChangesToAncenstor.getChangedFiles().contains(filePath))
&& ( theirsCommitChangesToAncenstor.getNewFiles().contains(filePath) ||
theirsCommitChangesToAncenstor.getChangedFiles().contains(filePath)))
{
String pathOfFileInHeadDir = getRepositoryLocation() + File.separator + ".magit" + File.separator + "head" + File.separator + filePath;
String pathOfFileInTheirsDir = getRepositoryLocation() + File.separator + ".magit" + File.separator + "theirs" + File.separator + filePath;
String sha1OfFileInHead = SHA1.createSha1(new File(pathOfFileInHeadDir));
String sha1OfFileInTheirs = SHA1.createSha1(new File(pathOfFileInTheirsDir));
if (sha1OfFileInHead.equals(sha1OfFileInTheirs))
{
return false; // the file has the same sha1 in both branches, this is the same file after all the changed.
}
else
return true;
}
else
return true;
}
// this method gets a file that was changed in one of the branches, and doesn't have a conflict
// just need to determine which branch changed it, and use the changed file on WC
private void putUpdatedFileOnWc(String filePath, CommitChanges headCommitChangesToAncenstor, CommitChanges theirsCommitChangesToAncenstor) throws Exception
{
// we know for sure this file was changed only by one of the branches
if (headCommitChangesToAncenstor.isFileInTheListsUnion(filePath))
{
// this file was changed by the head branch only, it is already on the WC in it final version
// nothing to do
}
else // changed by "theirs"
{
// this file was changed by "theirs" branch
// put what was on "theirs" branch to the WC
if (theirsCommitChangesToAncenstor.getDeletedFiles().contains(filePath))
{
// the change is - "theirs" deleted the file. need to delete it on WC ( head didn't change it)
File fileToDelete = new File( getRepositoryLocation() + File.separator + filePath);
if (fileToDelete.exists())
{
if ( fileToDelete.delete() == false)
{
throw new Exception("Can't delete the file " + fileToDelete.getPath());
}
}
}
else
{
// changed or added by "theirs", so copy this file from there to the WC
// there might be also new folders to include this file, that were added
// the new file path on the WC
String filePathOnWC = getRepositoryLocation() + File.separator + filePath;
File changedFile = new File(filePathOnWC);
if (changedFile.exists())
{
changedFile.delete();
}
// copy the file from theirs to head
// if folder of this file doesn't exist, create it
if (! changedFile.getParentFile().exists())
{
changedFile.getParentFile().mkdirs();
}
changedFile.createNewFile();
String theirsFile = getRepositoryLocation() + File.separator + ".magit" +
File.separator + "theirs" + File.separator + filePath;
String theirsFileContent = FileUtils.readFileToString(new File(theirsFile), StandardCharsets.UTF_8);
FilesOperations.writeTextToFile(theirsFileContent, filePathOnWC);
}
}
}
public void handleFastForwardMerge(String sha1OfHead, String sha1OfTheirs, String sha1OfAncenstor) throws Exception {
if (sha1OfHead.equals(sha1OfAncenstor)) {
getCurrentRepo().resetHeadBranchSha1(sha1OfTheirs);
} else {
// do nothing, the other branch commits are already included in the head branch
}
}
public Repository clone(String pathOfRepoToCloneFrom, String pathOfNewRepo, String newDir, String newRepoName, String remoteRepoUser) throws Exception
{
String repoPath = pathOfNewRepo + File.separator + newDir;
// first copy the directory to the new repository location
copyRemoteRepoToLocal(pathOfRepoToCloneFrom, pathOfNewRepo + File.separator + newDir );
// fix new repo name file to the newRepoName string insread of the remote name
String nameFilePath = repoPath + File.separator + ".magit" + File.separator + "name";
String remoteRepoName = FileUtils.readFileToString(new File(nameFilePath), StandardCharsets.UTF_8);
FilesOperations.writeTextToFile(newRepoName, nameFilePath);
// load the new cloned repository to our system
if(getCurrentRepo() == null){
Repository newRepo = new Repository();
newRepo.setRemoteRepoUsername(remoteRepoUser);
setCurrentRepo(newRepo);
}
currentRepo.setRemoteRepoPath(pathOfRepoToCloneFrom);
currentRepo.setRepositoryLogicalNameForUser(newRepoName);
currentRepo.writeRemoteNameAndPathToFile(pathOfRepoToCloneFrom, repoPath, remoteRepoName);
// create files for every remote branch, in clone every local branch has a remote branch
currentRepo.cretaeRemoteBranchesFilesAndDeleteLocalBranchesThatAreNotHead(repoPath, remoteRepoName);
// create the RTB file and write the head (local and remote couplt) branch to it.
currentRepo.createHeadRemoteTrackingBranchFile(repoPath, remoteRepoName);
// in this step, the file system has all the new files that are relevant for the new repo
currentRepo.loadRepositoryFromPath(pathOfNewRepo + File.separator + newDir);
removeUnwantedFolders();
return currentRepo;
}
private void copyRemoteRepoToLocal(String repoToClonePath, String whereToClonePath) throws IOException
{
try
{
if (!new File(whereToClonePath).exists())
{
new File(whereToClonePath).mkdirs();
}
File srcDir = new File(repoToClonePath);
File destDir = new File(whereToClonePath);
FileUtils.copyDirectory(srcDir, destDir);
}
catch (IOException e)
{
throw new IOException("Could not copy " + repoToClonePath + " to " + whereToClonePath);
}
}
//This method gets a commit Sha1 and returns an ArrayList of all the remote branches pointing to that commit
public ArrayList<String> getAllRemoteBranchesOnCommit(String commitSha1)
{
ArrayList<String> remoteBranchesOnCommit = new ArrayList<>();
for (Branch b: currentRepo.getAllOfTheBranches())
{
if (b.getIsRemote() && b.getCommit().getSha1().equals(commitSha1))
{
remoteBranchesOnCommit.add(b.getName());
}
}
return remoteBranchesOnCommit;
}
public ArrayList<String> getAllBranchesOnCommit(String commitSha1){
ArrayList<String> branchesOnCommit = new ArrayList<>();
for (Branch b: currentRepo.getAllOfTheBranches())
{
if (b.getCommit().getSha1().equals(commitSha1))
{
branchesOnCommit.add(b.getName());
}
}
return branchesOnCommit;
}
public void addRTBranch(String remoteBranchToTrack) throws Exception
{
// this metod gets a remote branch name ( full name, for example: repo1/shani)
// and add a new RT Branch with the same name ( but without the remote name, for example: shani)
// that follows the RB
// cut the name of the RB without the repo name
String newBranchName = remoteBranchToTrack.substring(remoteBranchToTrack.lastIndexOf(File.separator) +1);
if ( ! getAllBranchesNames().contains(newBranchName))
addNewBranch(newBranchName);
addRTBToRTBFile(newBranchName);
}
private void addRTBToRTBFile(String remoteBranchToTrack) throws IOException
{
String remoteTrackingBranchesFilePath = getRepositoryLocation() + File.separator + ".magit" + File.separator +"RTB";
String stringToAppend = remoteBranchToTrack + System.lineSeparator()
+ currentRepo.getRemoteRepoName() + File.separator +
remoteBranchToTrack + System.lineSeparator() + ";"
+ System.lineSeparator();
FilesOperations.appendTextToFile(stringToAppend, remoteTrackingBranchesFilePath);
}
private void removeUnwantedFolders()
{
// in case we cloned from a repo that has the "head" "theirs" and "ancenstor" directories, we delete them
String headFolderPath = currentRepo.getMagitPath() + File.separator + "head";
String theirsFolderPath = currentRepo.getMagitPath() + File.separator + "theirs";
String ancenstorFolderPath = currentRepo.getMagitPath() + File.separator + "ancenstor";
File headFolder = new File(headFolderPath);
File theirsFolder = new File(theirsFolderPath);
File ancenstorFolder = new File(ancenstorFolderPath);
if (headFolder.exists())
{
FilesOperations.deleteFolder(headFolder);
}
if (theirsFolder.exists())
{
FilesOperations.deleteFolder(theirsFolder);
}
if (ancenstorFolder.exists())
{
FilesOperations.deleteFolder(ancenstorFolder);
}
}
public String addRTBForRBAndCheckoutToIt(String branchNameToCheckout) throws Exception
{
// branchNameToCheckout is a remote branch name (for example : repo1/yuvalBranch
// we checkout to the RB, and then add a new RTB
// finally we checkout to it
checkOutToBranch(branchNameToCheckout);
addRTBranch(branchNameToCheckout);
String newBranchName = branchNameToCheckout.substring(branchNameToCheckout.lastIndexOf(File.separator)+1);
checkOutToBranch(newBranchName);
return newBranchName;
}
public ArrayList<Branch> getAllRemoteBranches()
{
ArrayList<Branch> remoteBranches = new ArrayList<>();
for (Branch b: currentRepo.getAllOfTheBranches())
{
if (b.getIsRemote())
{
remoteBranches.add(b);
}
}
return remoteBranches;
}
// this method get a full name of a branch ( for RB: repo1/yuvalBranch for example)
private boolean isBrnachInTheRemoteBranches(String branchName)
{
for (Branch b: currentRepo.getAllOfTheBranches())
{
if (b.getIsRemote() && b.getName().equals(branchName))
return true;
}
return false;
}
public Boolean isRepoHasARemote()
{
return (currentRepo.getRemoteRepoName() != null && currentRepo.getRemoteRepoPath() != null);
}
public void fetch() throws IOException
{
// first we fetch all the existing remote branches, and update them
ArrayList<Branch> remoteBranches = getAllRemoteBranches();
for (Branch b: remoteBranches)
{
String branchName = b.getName().substring(b.getName().lastIndexOf(File.separator) +1);
File remoteBranchFileInRemote = new File(currentRepo.getRemoteRepoPath() +
File.separator + ".magit" + File.separator+
"branches" + File.separator + branchName);
// get the remote sha1 of the branch and update the branch in this repo
String branchSha1InRemote = FileUtils.readFileToString(remoteBranchFileInRemote, StandardCharsets.UTF_8);
b.setCommit(new Commit(branchSha1InRemote));
// write the file to the RB in this repo
String remoteBranchPathInThisRepo = currentRepo.getBranchesPath()+File.separator + b.getName();
FilesOperations.writeTextToFile(branchSha1InRemote, remoteBranchPathInThisRepo);
fetchRemoteBranch(b);
}
// and now we also get new branches from the remote and add to this repos RB
getAllNewRemoteBranchesFromRemoteRepo();
currentRepo.initializeMagitCommitTree();
}
private void getAllNewRemoteBranchesFromRemoteRepo() throws IOException
{
// this method iterates all over the branches in the remote repository
// and add each new branch in the remote, to be a RB in this repo
String remoteBranchesPathInRemote = currentRepo.getRemoteRepoPath() + File.separator + ".magit" + File.separator + "branches";
// all the files in the remote repo, under branches folder
File[] branchesInRemote = new File (remoteBranchesPathInRemote).listFiles();
for (File f : branchesInRemote)
{
if (! f.isDirectory() && !f.getName().equals("HEAD") &&
!f.getName().equals("commits"))
{
String remoteBranchName = currentRepo.getRemoteRepoName() + File.separator + f.getName();
// If this file is a local branch in the *remote* repository, that we don't have a RB for-
// then create a new RB for it
if (! isBrnachInTheRemoteBranches(remoteBranchName))
{
createAndfetchRemoteBranchToThisRepo(remoteBranchName);
}
}
}
}
// this method gets a full name of a RB that isn't in this repo yet
// need to create its file and also bring all the data of it overtime
public void createAndfetchRemoteBranchToThisRepo(String remoteBranchName) throws IOException
{
// first, creat a new file for this RB in under .magit/branches/remoteName
Branch newRB = createNewRBInThisRepo(remoteBranchName);
// second, we want to bring all the data of the new RB - commits, files & folders to objects
fetchRemoteBranch(newRB);
}
// updates file system and also the branches list
// this method create a new file for a RB in the .magit/branches/remoteName folder, and write the sha1 to it
// this method returns the new RB
private Branch createNewRBInThisRepo(String remoteBranchName) throws IOException
{
String branchInRemotePath = currentRepo.getRemoteRepoPath() + File.separator + ".magit" + File.separator + "branches";
String newRBPath = currentRepo.getBranchesPath() ;
// create new file for new RB
File newRBFile = new File(newRBPath + File.separator + remoteBranchName);
if (! newRBFile.exists())
newRBFile.createNewFile();
// read SHA1 from the branch in the remote
String branchName = remoteBranchName.substring(remoteBranchName.lastIndexOf(File.separator)+1);
File branchFileInRemote = new File(branchInRemotePath + File.separator + branchName);
String sha1OfBranchInRemote = FileUtils.readFileToString(branchFileInRemote, StandardCharsets.UTF_8);
// write this SHA1 to the new RB
FilesOperations.writeTextToFile(sha1OfBranchInRemote, newRBPath+ File.separator + remoteBranchName);
// add the new RB to the branches list
Branch newBranch = new Branch(remoteBranchName, new Commit(sha1OfBranchInRemote));
newBranch.setIsRemote(true);
currentRepo.addNewBranch(newBranch);
return newBranch;
}
private void fetchRemoteBranch(Branch b) throws IOException
{
// should get the current commit of the RB of b and get all the delta from the branch in the remote to the branch b
// including zip files of commits, folders, files, branches
String branchSha1 = b.getCommit().getSha1(); // we can assume there is a sha1, cause collaborations doesn't work with rmpty repo
// zip file representing a commit
File sha1ZipFile = new File(currentRepo.getObjectsPath() + File.separator + branchSha1 + ".zip");
if (sha1ZipFile.exists()) // we already have this commit in our repo
return;
else
{
// we don't have this commit and its files on our repo, lets bring it
reccursiveFetchCommitFromRemote(b.getCommit().getSha1());
}
}
// is called with non-null value only
// copy commit and all its zip files from the remote
// copy the zip files to the objects path and also add to the commit file the new SHA1
private void reccursiveFetchCommitFromRemote(String remoteSha1OfACommit) throws IOException
{
String commitZipPathInRemote = currentRepo.getRemoteRepoPath() + File.separator +
".magit" + File.separator + "objects" + File.separator + remoteSha1OfACommit + ".zip";
String commitZipFileInThisRepo = currentRepo.getObjectsPath() + File.separator +
remoteSha1OfACommit + ".zip";
// first copy the commit zip file from the romte to local
File commitInThisRepo = new File(commitZipFileInThisRepo);
File commitInRemote = new File(commitZipPathInRemote);
if (! commitInThisRepo.exists())
{
// we dont have this commit, copy its zip file
FileUtils.copyFile(commitInRemote, commitInThisRepo);
// add the new commit SHA1 to the commits file
currentRepo.writeSha1ToCommitsFile(remoteSha1OfACommit);
ArrayList<String> commitInfo = FilesOperations.readAllContentFromZipFileByStrings(commitZipFileInThisRepo);
String firstParentSha1 = commitInfo.get(1);
String secondParentSha1 = commitInfo.get(2);
File firstParentCommitZipInThisRepo = new File(currentRepo.getObjectsPath() + File.separator + firstParentSha1 + ".zip");
File secondParentCommitZipInThisRepo = new File(currentRepo.getObjectsPath() + File.separator + secondParentSha1 + ".zip");
if (! firstParentSha1.equals("null") && !firstParentCommitZipInThisRepo.exists())
{
// need to call function with first parent
reccursiveFetchCommitFromRemote(firstParentSha1);
}
if (! secondParentSha1.equals("null") && !secondParentCommitZipInThisRepo.exists())
{
// need to call function with second parent
reccursiveFetchCommitFromRemote(secondParentSha1);
}
// do anyway, also for commit with no parents
String rootFolderSha1 = commitInfo.get(0);
File rootFolderZipFile = new File(currentRepo.getObjectsPath() +
File.separator + rootFolderSha1 + ".zip");
if (! rootFolderZipFile.exists())
{
// we don't have a zip file of the root folder of this commit, recurssive add it and all its content files
recurssiveFetchFolderFromRemote(rootFolderSha1);
}
}
}
// this method is called with a folderSha1 we don't have on this repo, but have on the remote
private void recurssiveFetchFolderFromRemote(String folderSha1) throws IOException
{
File folderZipFileInThisRepo = new File(currentRepo.getObjectsPath() + File.separator + folderSha1 + ".zip");
File folderZipInRemote = new File(currentRepo.getRemoteRepoPath() + File.separator
+ ".magit" + File.separator + "objects" + File.separator +
folderSha1 + ".zip");
// first copy the folder zip file to this repo
FileUtils.copyFile(folderZipInRemote, folderZipFileInThisRepo);
ArrayList<GitObject> foldersObjects = currentRepo.getAllObjectsOfDirectory(folderZipFileInThisRepo);
for (GitObject object : foldersObjects)
{
String newObjectPath = currentRepo.getObjectsPath() + File.separator + object.getmSHA1() + ".zip";
File newObjectFile = new File(newObjectPath);
if (object.getmFolderType().equals(FolderType.FOLDER))
{
// the current object is folder, if we don't have its sha1 in the local repo, call recurssivly
if (!newObjectFile.exists())
{
recurssiveFetchFolderFromRemote(object.getmSHA1());
}
}
else
{
// the current object is a file, copy if we don't have it
if (! newObjectFile.exists())
{
// just copy from the remote
File objectInRemote = new File(currentRepo.getRemoteRepoPath()
+ File.separator + ".magit" + File.separator + "objects" +
File.separator + object.getmSHA1() + ".zip");
FileUtils.copyFile(objectInRemote, newObjectFile);
}
}
}
}
// check if we have a RTB for the head branch in the file RTB
public Boolean checkHeadIsRTB() throws IOException
{
String headName = currentRepo.getHeadBranch().getName();
String RTBFilePath = currentRepo.getMagitPath() + File.separator + "RTB";
ArrayList<String> RTBContent = FilesOperations.readAllContentFromFileByStrings(RTBFilePath);
for (int i = 0 ; i < RTBContent.size(); i+=3)
{
String branchName = RTBContent.get(i);
if (branchName.equals(headName))
return true;
}
return false;
}
public void pull() throws Exception
{
// fetching only the RB that head branch is tracking after
File remoteBranchFileInRemote = new File(currentRepo.getRemoteRepoPath() +
File.separator + ".magit" + File.separator +
"branches" + File.separator + currentRepo.getHeadBranch().getName());
// get the remote sha1 of the branch and update the branch in this repo
String branchSha1InRemote = FileUtils.readFileToString(remoteBranchFileInRemote, StandardCharsets.UTF_8);
String remoteBranchName = currentRepo.getRemoteRepoName() + File.separator + currentRepo.getHeadBranch().getName();
Branch b = currentRepo.getBranchByName(remoteBranchName);
b.setCommit(new Commit(branchSha1InRemote));
//Writing the sha1 of the commit in the remote branch in RR to the remote branch in this repo (LR)
String remoteBranchPathInThisRepo = currentRepo.getBranchesPath()+File.separator + b.getName();
FilesOperations.writeTextToFile(branchSha1InRemote, remoteBranchPathInThisRepo);
// fetching the remote branch that fits the head (which is a RTB)
fetchRemoteBranch(b);
// in this exercise we won't have conflicts in pull
// in this exercise the RTB is the ancenstor of the RB commit
handleFastForwardMerge(currentRepo.getHeadBranch().getCommit().getSha1(),
b.getCommit().getSha1(), currentRepo.getHeadBranch().getCommit().getSha1());
}
public boolean isRemoteBranchAndBranchInRemoteAreOnSameCommit() throws IOException{
//path of branch file in remote repository
String branchInRemotePath = currentRepo.getRemoteRepoPath() + File.separator + ".magit" +
File.separator + "branches" + File.separator + currentRepo.getHeadBranch().getName();
//path of remote branch file in local repository
String remoteBranchName = currentRepo.getRemoteRepoName() + File.separator + currentRepo.getHeadBranch().getName();
String remoteBranchInLocalPath = currentRepo.getBranchesPath() + File.separator + remoteBranchName;
//reading the commit pointed by the branch in remote that is tracked by the head branch in this repo
String commitSha1PointedByBranchInRemote = FileUtils.readFileToString(new File(branchInRemotePath), StandardCharsets.UTF_8);
//reading the commit pointed by the remote branch in the local repo
String commitSha1PointedByRemoteBranchInLocal = FileUtils.readFileToString(new File(remoteBranchInLocalPath), StandardCharsets.UTF_8);
return(commitSha1PointedByRemoteBranchInLocal.equals(commitSha1PointedByBranchInRemote));
}
public boolean isThereOpenChangesOnRemoteRepo() throws Exception{
//We will load the remote repository later to check if there are open changes-
// so we need to save the current repository location in order to get bach to it
String currentLocalRepoPath = currentRepo.getRepositoryLocation();
//We need to load the remote repository in order to check if there are any open changes there
currentRepo.loadRepositoryFromPath(currentRepo.getRemoteRepoPath());
boolean isThereOpenChangesInRemoteRepository = isThereOpenChangesInRepository();
//loading back the current local repository
currentRepo.loadRepositoryFromPath(currentLocalRepoPath);
return isThereOpenChangesInRemoteRepository;
}
public void push(boolean isBranchToPushRTB) throws Exception
{
// IMPLEMENT!
String branchName = currentRepo.getHeadBranch().getName();
String remoteBranchName = currentRepo.getRemoteRepoName() + File.separator + branchName;
String branchesInRemotePath = currentRepo.getRemoteRepoPath() + File.separator + ".magit" + File.separator + "branches";
// fetching only the RTB in the LR head that tracks the branch in the RR
File rtbBranchFileInLocal = new File(currentRepo.getBranchesPath() + File.separator + branchName);
// get the sha1 of the LR rtb in head and update the branch in the RR, and the RB in the LR
String branchSha1InLocalHeadRTB = FileUtils.readFileToString(rtbBranchFileInLocal, StandardCharsets.UTF_8);
File branchInRemote = new File ( branchesInRemotePath + File.separator + branchName);
File remoteBranchInLocal = new File(currentRepo.getRepositoryLocation() +
File.separator + ".magit" + File.separator +
"branches" + File.separator + remoteBranchName);
//Writing branch sha1 to branch in RR and to remote branch in LR
//The only case in which the branch file in remote/ remote branch file in local doesn't exist-
// is if we're pushing a new branch to RR (Bonus 4)
if(!branchInRemote.exists()){
branchInRemote.createNewFile();
}
FileUtils.writeStringToFile(branchInRemote, branchSha1InLocalHeadRTB, StandardCharsets.UTF_8);
if(!remoteBranchInLocal.exists()){
remoteBranchInLocal.createNewFile();
}
FileUtils.writeStringToFile(remoteBranchInLocal, branchSha1InLocalHeadRTB, StandardCharsets.UTF_8);
//If the branch to push isn't RTB- then we want to add it to the RTB file in LR (Bonus 4)
Branch remoteBranch = null;
if(!isBranchToPushRTB){
String rtbFileInLRPath = currentRepo.getMagitPath() + File.separator + "RTB";
String strForRTB = branchName + System.lineSeparator()
+ remoteBranchName + System.lineSeparator() +
";" + System.lineSeparator();
// append the branch to RTB file
FilesOperations.appendTextToFile(strForRTB, rtbFileInLRPath);
//Adding the new remote branch to the allOfTheBranches list
remoteBranch = new Branch(remoteBranchName, new Commit(branchSha1InLocalHeadRTB));
remoteBranch.setIsRemote(true);
currentRepo.getAllOfTheBranches().add(remoteBranch);
}
else {
//Setting the remote branch in this repository with the new RTB sha1
remoteBranch = currentRepo.getBranchByName(remoteBranchName);
remoteBranch.setCommit(new Commit(branchSha1InLocalHeadRTB));
}
// fetching the RTB branch that fits branch in RR
fetchRTBBranchToRR(remoteBranch);
//Need to spread new commit content on WC in the remote repo only if the head in the remote is the remote branch!!!
File headFileInRemote = new File (branchesInRemotePath + File.separator + "HEAD");
String headBranchInRemote = FileUtils.readFileToString(headFileInRemote, StandardCharsets.UTF_8);
if(headBranchInRemote.equals(branchName)){
putCommitContentOnWorkingCopyOfRemote(branchSha1InLocalHeadRTB);
}
currentRepo.resetAndUpdateAllOfTheBranches(); // update branches list
currentRepo.initializeMagitCommitTree();
}
public void fetchRTBBranchToRR(Branch remoteBranch) throws IOException{
// should get the current commit of the RTB of remoteBranch and get all the delta from the RTB in out repository to the remoteBranch
// including zip files of commits, folders, files, branches
String branchSha1 = currentRepo.getHeadBranch().getCommit().getSha1(); // we can assume there is a sha1, cause collaborations doesn't work with empty repo
// zip file representing a commit in the remote repository
File sha1ZipFile = new File(currentRepo.getRemoteRepoPath() + File.separator
+ ".magit" + File.separator
+ "objects" + File.separator
+ branchSha1 + ".zip");
if (sha1ZipFile.exists()) // we already have this commit in the remote repo
return;
else
{
// we don't have this commit and its files on the remote repo, lets bring it
reccursiveFetchCommitFromLocalToRemote(branchSha1, null);
}
}
// is called with non-null value only
// copy commit and all its zip files from local to remote
// copy the zip files to the objects path and also add to the commit file the new SHA1
public void reccursiveFetchCommitFromLocalToRemote(String rtbSha1OfACommit, HashSet<String> commitsDelta) throws IOException
{
String remoteRepoObjectsPath = currentRepo.getRemoteRepoPath() + File.separator
+ ".magit" + File.separator
+ "objects";
String commitZipPathInLocalRepo = currentRepo.getRepositoryLocation() + File.separator +
".magit" + File.separator + "objects" + File.separator + rtbSha1OfACommit + ".zip";
String commitZipFileInRemoteRepo = remoteRepoObjectsPath + File.separator + rtbSha1OfACommit + ".zip";
// first copy the commit zip file from the local repo to remote repo
File commitInThisRepo = new File(commitZipPathInLocalRepo);
File commitInRemote = new File(commitZipFileInRemoteRepo);
//Will be used for calculating the commits delta for each PR
commitsDelta.add(rtbSha1OfACommit);
if (! commitInRemote.exists())
{
// the remote doesn't have this commit, copy the local repo's zip file
FileUtils.copyFile(commitInThisRepo, commitInRemote);
// add the new commit SHA1 to the commits file in the remote repository
writeSha1ToCommitsFileInRemoteRepo(rtbSha1OfACommit);
ArrayList<String> commitInfo = FilesOperations.readAllContentFromZipFileByStrings(commitZipFileInRemoteRepo);
String firstParentSha1 = commitInfo.get(1);
String secondParentSha1 = commitInfo.get(2);
File firstParentCommitZipInThisRepo = new File(remoteRepoObjectsPath + File.separator + firstParentSha1 + ".zip");
File secondParentCommitZipInThisRepo = new File(remoteRepoObjectsPath + File.separator + secondParentSha1 + ".zip");
if (! firstParentSha1.equals("null") && !firstParentCommitZipInThisRepo.exists())
{
// need to call function with first parent
reccursiveFetchCommitFromLocalToRemote(firstParentSha1, commitsDelta);
}
if (! secondParentSha1.equals("null") && !secondParentCommitZipInThisRepo.exists())
{
// need to call function with second parent
reccursiveFetchCommitFromLocalToRemote(secondParentSha1, commitsDelta);
}
// do anyway, also for commit with no parents
String rootFolderSha1 = commitInfo.get(0);
File rootFolderZipFile = new File(remoteRepoObjectsPath +
File.separator + rootFolderSha1 + ".zip");
if (! rootFolderZipFile.exists())
{
// we don't have a zip file of the root folder of this commit, recurssive add it and all its content files
recurssiveFetchFolderFromLocalToRemote(rootFolderSha1);
}
}
}
// this method is called with a folderSha1 we don't have on the remote repo, but have on this repo
public void recurssiveFetchFolderFromLocalToRemote(String folderSha1) throws IOException
{
String remoteRepoObjectsPath = currentRepo.getRemoteRepoPath() + File.separator + ".magit" + File.separator + "objects";
File folderZipFileInThisRepo = new File(currentRepo.getObjectsPath() + File.separator + folderSha1 + ".zip");
File folderZipInRemote = new File(remoteRepoObjectsPath + File.separator + folderSha1 + ".zip");
// first copy the folder zip file from this repo to the remote repo
FileUtils.copyFile(folderZipFileInThisRepo, folderZipInRemote);
ArrayList<GitObject> foldersObjects = currentRepo.getAllObjectsOfDirectory(folderZipInRemote);
for (GitObject object : foldersObjects)
{
String newObjectPath = remoteRepoObjectsPath + File.separator + object.getmSHA1() + ".zip";
File newObjectFile = new File(newObjectPath);
if (object.getmFolderType().equals(FolderType.FOLDER))
{
// the current object is folder, if we don't have its sha1 in the remote repo, call recurssivly
if (!newObjectFile.exists())
{
recurssiveFetchFolderFromLocalToRemote(object.getmSHA1());
}
}
else
{
// the current object is a file, copy if we don't have it
if (! newObjectFile.exists())
{
// just copy to the remote
File objectInLocal = new File(currentRepo.getObjectsPath()
+ File.separator + object.getmSHA1() + ".zip");
FileUtils.copyFile(objectInLocal, newObjectFile);
}
}
}
}
public void writeSha1ToCommitsFileInRemoteRepo(String commitSha1) throws IOException
{
String commitsFilePath = currentRepo.getRemoteRepoPath()
+ File.separator + ".magit"
+ File.separator + "branches"
+ File.separator + "commits";
File commitsFile = new File(commitsFilePath);
if (!commitsFile.exists())
{
commitsFile.createNewFile();
}
FilesOperations.appendTextToFile(commitSha1 + "\n", commitsFilePath);
}
public void putCommitContentOnWorkingCopyOfRemote(String commitSha1) throws IOException
{
// the file that describes the commit
String remoteRepoObjectsPath =currentRepo.getRemoteRepoPath() + File.separator + ".magit" + File.separator + "objects";
String commitFilePath = remoteRepoObjectsPath + File.separator + commitSha1 + ".zip";
String workingCopySha1;
try
{
// read first line, where the root folder sha1 is
ArrayList<String> stringsOfCommitFile = FilesOperations.readAllContentFromZipFileByStrings(commitFilePath);
workingCopySha1 = stringsOfCommitFile.get(0);
// first must delete all the working copy files and directories, except the folder .magit
if (! currentRepo.deleteWorkingCopy(currentRepo.getRemoteRepoPath()))
throw new IOException("Could not delete some of the files in the remote working copy.");
// read from the given working copy zip file all the root objects
File workingCopyDescriptionFile = new File(remoteRepoObjectsPath + File.separator + workingCopySha1 + ".zip"); // the path to the file that describes the WC
ArrayList<GitObject> filesOfRoot = currentRepo.getAllObjectsOfDirectory(workingCopyDescriptionFile);
// extract each git object content to the working tree recursively, starting from the repository path
for (GitObject obj : filesOfRoot)
{
currentRepo.putContentOfGitObjectToDir(obj, currentRepo.getRemoteRepoPath());
}
}
// might be thrown by readStringFromFileUntilEnter or getAllObjectsOfDirectory
catch (IOException e)
{
throw e;
}
}
public HashSet<String> getAllSha1InHistoryOfCommit(Commit commitToListHistory) throws IOException
{
HashSet<String> res = new HashSet<>();
res.add(commitToListHistory.getSha1());
recursiveAddParentCommitsToSet(commitToListHistory, res);
return res;
}
private void recursiveAddParentCommitsToSet(Commit commitToListHistory, HashSet<String> commitsInHistory) throws IOException
{
if (!commitToListHistory.getFirstParentSha1().equals("null"))
{
commitsInHistory.add(commitToListHistory.getFirstParentSha1());
recursiveAddParentCommitsToSet(currentRepo.getCommitBySHA1(commitToListHistory.getFirstParentSha1()), commitsInHistory);
}
if (! commitToListHistory.getSecondParentSha1().equals("null"))
{
commitsInHistory.add(commitToListHistory.getSecondParentSha1());
recursiveAddParentCommitsToSet(currentRepo.getCommitBySHA1(commitToListHistory.getSecondParentSha1()), commitsInHistory);
}
}
// returns null on non exsiting file
public String getFileContent(String filePath) throws IOException
{
File f = new File(filePath);
if (!f.exists())
return null;
return FilesOperations.readFileContent(new File(filePath));
}
public void approvePullRequest(String targetBranchName, String baseBranchName) throws Exception
{
// in pull request in our exercise we can assume that base is the ancenstor of target
// so this approval will always be a FF-merge, so we can use reset
Branch targetBranch = currentRepo.getBranchByName(targetBranchName);
Branch baseBranch = currentRepo.getBranchByName(baseBranchName);
String sha1OfTarget = targetBranch.getCommit().getSha1();
if(baseBranch.getName().equals(currentRepo.getHeadBranch().getName()))
{
// the base is the head, reset the head to the new commit, of the target branch
// reset head and also put on WC
currentRepo.resetHeadBranchSha1(sha1OfTarget);
}
else
{
// target is not the head
currentRepo.resetBranchThatIsNotHead(baseBranchName, sha1OfTarget);
}
}
public boolean isThereCommitsToUpdate(PullRequest pullRequestToUpdate)
{
Repository remoteRepo = pullRequestToUpdate.getRemoteRepository();
Repository localRepo = currentRepo;
// calculate the name of the target branch in the RR (without the repo name + '/'
int indexOfLastSlashInTargetBranchName = pullRequestToUpdate.getTargetBranchName().lastIndexOf(File.separator);
String targetBranchNameInRR = pullRequestToUpdate.getTargetBranchName().substring(indexOfLastSlashInTargetBranchName+ 1);
Branch remoteTargetBranch = remoteRepo.getBranchByName(targetBranchNameInRR);
Branch localTargetBranch = localRepo.getBranchByName(targetBranchNameInRR);
return (! remoteTargetBranch.getCommit().getSha1().equals(localTargetBranch.getCommit().getSha1()));
}
public void deleteRTBFromFile(String branchToDelete) throws IOException
{
String pathOfRTBFile = currentRepo.getMagitPath() + File.separator + "RTB";
ArrayList<String> linesInRTBFile = FilesOperations.readAllContentFromFileByStrings(pathOfRTBFile);
// empty the file
FileUtils.writeStringToFile(new File(pathOfRTBFile), "", StandardCharsets.UTF_8);
for (int i = 0 ; i < linesInRTBFile.size(); i++)
{
if (linesInRTBFile.get(i).equals(branchToDelete))
{
i += 2;
}
else
{
FilesOperations.appendTextToFile(linesInRTBFile.get(i) + System.lineSeparator(), pathOfRTBFile);
}
}
}
}
|
3e078a7510ca34c222779df8f99a775299ef6745
| 5,325 |
java
|
Java
|
main/plugins/org.talend.repository/src/main/java/org/talend/repository/model/migration/AddPortForTCassandraConfigurationSpark.java
|
coheigea/tdi-studio-se
|
c4cd4df0fc841c497b51718e623145d29d0bf030
|
[
"Apache-2.0"
] | 114 |
2015-03-05T15:34:59.000Z
|
2022-02-22T03:48:44.000Z
|
main/plugins/org.talend.repository/src/main/java/org/talend/repository/model/migration/AddPortForTCassandraConfigurationSpark.java
|
coheigea/tdi-studio-se
|
c4cd4df0fc841c497b51718e623145d29d0bf030
|
[
"Apache-2.0"
] | 1,137 |
2015-03-04T01:35:42.000Z
|
2022-03-29T06:03:17.000Z
|
main/plugins/org.talend.repository/src/main/java/org/talend/repository/model/migration/AddPortForTCassandraConfigurationSpark.java
|
coheigea/tdi-studio-se
|
c4cd4df0fc841c497b51718e623145d29d0bf030
|
[
"Apache-2.0"
] | 219 |
2015-01-21T10:42:18.000Z
|
2022-02-17T07:57:20.000Z
| 43.292683 | 138 | 0.577653 | 3,199 |
// ============================================================================
//
// Copyright (C) 2006-2021 Talend Inc. - www.talend.com
//
// This source code is available under agreement available at
// %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt
//
// You should have received a copy of the agreement
// along with this program; if not, write to Talend SA
// 9 rue Pages 92150 Suresnes, France
//
// ============================================================================
package org.talend.repository.model.migration;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Date;
import java.util.GregorianCalendar;
import java.util.List;
import org.talend.commons.exception.ExceptionHandler;
import org.talend.commons.exception.PersistenceException;
import org.talend.core.model.components.ComponentUtilities;
import org.talend.core.model.components.ModifyComponentsAction;
import org.talend.core.model.components.conversions.IComponentConversion;
import org.talend.core.model.components.filters.IComponentFilter;
import org.talend.core.model.components.filters.NameComponentFilter;
import org.talend.core.model.migration.AbstractAllJobMigrationTask;
import org.talend.core.model.properties.Item;
import org.talend.designer.core.model.utils.emf.talendfile.ElementParameterType;
import org.talend.designer.core.model.utils.emf.talendfile.NodeType;
import org.talend.designer.core.model.utils.emf.talendfile.ProcessType;
import org.talend.designer.core.model.utils.emf.talendfile.impl.ElementValueTypeImpl;
/**
* created by bchen on Jul 20, 2015 Detailled comment
*
*/
public class AddPortForTCassandraConfigurationSpark extends AbstractAllJobMigrationTask {
/*
* (non-Javadoc)
*
* @see org.talend.migration.IMigrationTask#getOrder()
*/
@Override
public Date getOrder() {
GregorianCalendar gc = new GregorianCalendar(2015, 6, 27, 12, 0, 0);
return gc.getTime();
}
/*
* (non-Javadoc)
*
* @see org.talend.core.model.migration.AbstractItemMigrationTask#execute(org.talend.core.model.properties.Item)
*/
@Override
public ExecutionResult execute(Item item) {
final ProcessType processType = getProcessType(item);
String[] compNames = { "tCassandraConfiguration" }; //$NON-NLS-1$
IComponentConversion conversion = new IComponentConversion() {
@Override
public void transform(NodeType node) {
if (node == null) {
return;
}
ElementParameterType parameter = ComponentUtilities.getNodeProperty(node, "PORT"); //$NON-NLS-1$
List<Object> needRemovedList = new ArrayList<Object>();
if (parameter == null) {
// get the value of native port if the user defined it on the configuration table
String portValue = null;
ElementParameterType configTable = ComponentUtilities.getNodeProperty(node, "CASSANDRA_CONFIGURATION"); //$NON-NLS-1$
boolean findNative = false;
boolean findRpc = false;
for (Object e : configTable.getElementValue()) {
ElementValueTypeImpl el = (ElementValueTypeImpl) e;
if (findNative && "VALUE".equals(el.getElementRef())) { //$NON-NLS-1$
portValue = el.getValue();
needRemovedList.add(e);
findNative = false;
}
if (findRpc && "VALUE".equals(el.getElementRef())) { //$NON-NLS-1$
needRemovedList.add(e);
findRpc = false;
}
if ("KEY".equals(el.getElementRef())) { //$NON-NLS-1$
if ("connection_native_port".equals(el.getValue())) { //$NON-NLS-1$
findNative = true;
needRemovedList.add(e);
}
if ("connection_rpc_port".equals(el.getValue())) { //$NON-NLS-1$
findRpc = true;
needRemovedList.add(e);
}
}
}
configTable.getElementValue().removeAll(needRemovedList);
ComponentUtilities.addNodeProperty(node, "PORT", "TEXT"); //$NON-NLS-1$ //$NON-NLS-2$
ComponentUtilities.setNodeValue(node, "PORT", portValue == null ? "\"9042\"" : portValue); //$NON-NLS-1$ //$NON-NLS-2$
}
}
};
for (String name : compNames) {
IComponentFilter filter = new NameComponentFilter(name);
try {
ModifyComponentsAction.searchAndModify(item, processType, filter,
Arrays.<IComponentConversion> asList(conversion));
} catch (PersistenceException e) {
// TODO Auto-generated catch block
ExceptionHandler.process(e);
return ExecutionResult.FAILURE;
}
}
return ExecutionResult.SUCCESS_NO_ALERT;
}
}
|
3e078a92f1e68aafa99ed4b8b12b11d77726052b
| 75 |
java
|
Java
|
classpy-gui/src/main/java/com/github/zxh/classpy/gui/events/OpenNewWindow.java
|
smallclover/classpy
|
85ff48a351a4907aacfde856350605ed38e35b17
|
[
"MIT"
] | 985 |
2015-03-14T07:47:54.000Z
|
2022-03-29T02:54:23.000Z
|
classpy-gui/src/main/java/com/github/zxh/classpy/gui/events/OpenNewWindow.java
|
smallclover/classpy
|
85ff48a351a4907aacfde856350605ed38e35b17
|
[
"MIT"
] | 19 |
2016-05-08T07:16:06.000Z
|
2022-03-29T11:32:11.000Z
|
classpy-gui/src/main/java/com/github/zxh/classpy/gui/events/OpenNewWindow.java
|
smallclover/classpy
|
85ff48a351a4907aacfde856350605ed38e35b17
|
[
"MIT"
] | 269 |
2015-03-15T00:50:33.000Z
|
2022-03-29T06:54:10.000Z
| 15 | 42 | 0.786667 | 3,200 |
package com.github.zxh.classpy.gui.events;
public class OpenNewWindow {
}
|
3e078ab9e84715711dad55274305de3d01594b3a
| 1,448 |
java
|
Java
|
alchemy-sqlite/src/main/java/alchemy/sqlite/Binder.java
|
DanielSerdyukov/RxSQLite
|
aedd17d3ac1992c6cc1b21e8f28809696f70c758
|
[
"Apache-2.0"
] | null | null | null |
alchemy-sqlite/src/main/java/alchemy/sqlite/Binder.java
|
DanielSerdyukov/RxSQLite
|
aedd17d3ac1992c6cc1b21e8f28809696f70c758
|
[
"Apache-2.0"
] | null | null | null |
alchemy-sqlite/src/main/java/alchemy/sqlite/Binder.java
|
DanielSerdyukov/RxSQLite
|
aedd17d3ac1992c6cc1b21e8f28809696f70c758
|
[
"Apache-2.0"
] | null | null | null | 33.674419 | 75 | 0.650552 | 3,201 |
/*
* Copyright (C) 2017 exzogeni.com
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package alchemy.sqlite;
import alchemy.AlchemyException;
import alchemy.sqlite.platform.SQLiteStmt;
class Binder {
static void bind(SQLiteStmt stmt, int index, Object value) {
if (value == null) {
stmt.bindNull(index);
} else if (value instanceof Integer
|| value instanceof Long
|| value instanceof Short) {
stmt.bindLong(index, ((Number) value).longValue());
} else if (value instanceof Number) {
stmt.bindDouble(index, ((Number) value).doubleValue());
} else if (value instanceof String) {
stmt.bindString(index, (String) value);
} else if (value instanceof byte[]) {
stmt.bindBlob(index, (byte[]) value);
} else {
throw new AlchemyException("Unsupported SQLite type");
}
}
}
|
3e078cda93a2672d8b2f1ecfa0bc314942c14bd7
| 568 |
java
|
Java
|
src/main/java/cn/huanzi/qch/baseadmin/sys/sysuser/service/SysUserService.java
|
Linece/base-admin
|
3ad3251f52fbc2ce0417754513cc62c354355ee3
|
[
"MIT"
] | 2,218 |
2019-09-17T08:50:51.000Z
|
2022-03-28T08:49:34.000Z
|
src/main/java/cn/huanzi/qch/baseadmin/sys/sysuser/service/SysUserService.java
|
849029780/base-admin
|
b048a676bf041b36c027174b9427b4db7e0c3aa8
|
[
"MIT"
] | 21 |
2020-01-22T06:56:04.000Z
|
2022-02-10T10:03:31.000Z
|
src/main/java/cn/huanzi/qch/baseadmin/sys/sysuser/service/SysUserService.java
|
849029780/base-admin
|
b048a676bf041b36c027174b9427b4db7e0c3aa8
|
[
"MIT"
] | 1,063 |
2019-09-17T08:51:58.000Z
|
2022-03-31T08:40:36.000Z
| 43.692308 | 92 | 0.829225 | 3,202 |
package cn.huanzi.qch.baseadmin.sys.sysuser.service;
import cn.huanzi.qch.baseadmin.common.pojo.Result;
import cn.huanzi.qch.baseadmin.common.service.CommonService;
import cn.huanzi.qch.baseadmin.sys.sysuser.pojo.SysUser;
import cn.huanzi.qch.baseadmin.sys.sysuser.vo.SysUserVo;
import org.springframework.security.web.authentication.rememberme.PersistentTokenRepository;
public interface SysUserService extends CommonService<SysUserVo, SysUser, String> {
Result<SysUserVo> findByLoginName(String username);
Result<SysUserVo> resetPassword(String userId);
}
|
3e078d0a753764562378d3f708fa4bfab4548807
| 4,072 |
java
|
Java
|
hnclient-v2/src/test/java/ca/bc/gov/hlth/hnclientv2/RouteTest.java
|
bcgov/moh-hnclient-v2
|
de701db68c7546525b42d40733299e12c9923ea3
|
[
"Apache-2.0"
] | 1 |
2021-03-05T20:33:12.000Z
|
2021-03-05T20:33:12.000Z
|
hnclient-v2/src/test/java/ca/bc/gov/hlth/hnclientv2/RouteTest.java
|
bcgov/moh-hnclient-v2
|
de701db68c7546525b42d40733299e12c9923ea3
|
[
"Apache-2.0"
] | 16 |
2020-07-17T17:20:55.000Z
|
2021-07-08T15:54:12.000Z
|
hnclient-v2/src/test/java/ca/bc/gov/hlth/hnclientv2/RouteTest.java
|
bcgov/moh-hnclient-v2
|
de701db68c7546525b42d40733299e12c9923ea3
|
[
"Apache-2.0"
] | null | null | null | 47.818182 | 684 | 0.736586 | 3,203 |
package ca.bc.gov.hlth.hnclientv2;
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.mockito.Mockito.doNothing;
import static org.mockito.Mockito.spy;
import org.apache.camel.EndpointInject;
import org.apache.camel.Exchange;
import org.apache.camel.Processor;
import org.apache.camel.Produce;
import org.apache.camel.ProducerTemplate;
import org.apache.camel.builder.AdviceWithRouteBuilder;
import org.apache.camel.component.mock.MockEndpoint;
import org.apache.camel.spi.PropertiesComponent;
import org.apache.camel.test.junit5.CamelTestSupport;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
public class RouteTest extends CamelTestSupport {
private static final String fhirJsonRequest = "{\"content\":[{\"attachment\":{\"data\":\"949d1u22cbffbrarjh182eig55721odj",\"contentType\":\"x-application\\/hl7-v2+er7\"}}],\"resourceType\":\"DocumentReference\",\"status\":\"current\"}";
private static final String fhirJsonResponse = "{\"content\":[{\"attachment\":{\"data\":\"caf86f4uutaoxfysmf7anj01xl6sv3ps",\"contentType\":\"x-application\\/hl7-v2+er7\"}}],\"resourceType\":\"DocumentReference\",\"status\":\"current\"}";
private static final String v2Request = "00000352MSH|^~\\&|HNWEB|VIHA|RAIGT-PRSN-DMGR|BC00001013|20170125122125|train96|R03|20170125122125|D|2.4||\n"
+ "ZHD|20170125122125|^^00000010|HNAIADMINISTRATION||||2.4\n"
+ "PID||1234567890^^^BC^PH";
private static final String v2Response = "MSH|^~\\&|RAIGT-PRSN-DMGR|BC00002041|HNWeb|BC01000030|20200206123841|train96|E45|1819924|D|2.4^M\n"
+ "MSA|AA|20200206123840|HJMB001ISUCCESSFULLY COMPLETED^M\n"
+ "ERR|^^^HJMB001I&SUCCESSFULLY COMPLETED^M\n"
+ "PID||123456789^^^BC^PH^MOH|||||19840225|M^M\n"
+ "ZIA|||||||||||||||LASTNAME^FIRST^S^^^^L|912 VIEW ST^^^^^^^^^^^^^^^^^^^VICTORIA^BC^V8V3M2^CAN^H^^^^N|^PRN^PH^^^250^1234568";
@Produce("direct:start")
private ProducerTemplate mockRouteStart;
@EndpointInject("mock:hnsecure")
private MockEndpoint hnSecureEndpoint;
@EndpointInject("mock:output")
private MockEndpoint outputEndpoint;
@Override
public boolean isUseAdviceWith() {
return true;
}
@BeforeEach
public void configureRoutes() throws Exception {
//Since we're not running from the main we need to set the properties
PropertiesComponent pc = context.getPropertiesComponent();
pc.setLocation("classpath:application.properties");
// Skip the init() steps
Route routeMock = spy(Route.class);
doNothing().when(routeMock).init();
context.addRoutes(routeMock);
// Skip the retrieve access token step and the send to HnSecure step
AdviceWithRouteBuilder.adviceWith(context, "hnclient-route", a -> {
a.replaceFromWith("direct:start");
a.weaveById("RetrieveAccessToken").replace().to("mock:RetrieveAccessToken");
a.weaveById("ToHnSecure").replace().to("mock:hnsecure");
a.weaveAddLast().to("mock:output");
});
}
@Test
public void testSuccessfulMessage() throws Exception {
context.start();
// We expect a single base64 encoded message like HnSecure would get
hnSecureEndpoint.expectedMessageCount(1);
hnSecureEndpoint.expectedBodiesReceived(fhirJsonRequest);
hnSecureEndpoint.whenAnyExchangeReceived(new Processor() {
@Override
public void process(Exchange exchange) throws Exception {
exchange.getMessage().setBody(fhirJsonResponse);
}
});
// Send a message (include a 200 response code so it passes the error processor)
mockRouteStart.sendBodyAndHeader(v2Request, Exchange.HTTP_RESPONSE_CODE, 200);
// Verify our expectations were met
assertMockEndpointsSatisfied();
// Verify that the response is converted from FHIR JSON to HL7v2
assertEquals(v2Response, outputEndpoint.getExchanges().get(0).getIn().getBody());
context.stop();
}
}
|
3e078e190e33e9b069221bc86dcadd93f6b21748
| 2,068 |
java
|
Java
|
src/main/java/org/openecomp/dmaapbc/aaf/AafDecrypt.java
|
onap/dcae-dmaapbc
|
fe6ea9caf37d877e6df91ec5ac58a8b8c3cfe654
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/org/openecomp/dmaapbc/aaf/AafDecrypt.java
|
onap/dcae-dmaapbc
|
fe6ea9caf37d877e6df91ec5ac58a8b8c3cfe654
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/org/openecomp/dmaapbc/aaf/AafDecrypt.java
|
onap/dcae-dmaapbc
|
fe6ea9caf37d877e6df91ec5ac58a8b8c3cfe654
|
[
"Apache-2.0"
] | null | null | null | 36.280702 | 108 | 0.62911 | 3,204 |
/*-
* ============LICENSE_START=======================================================
* OpenECOMP - org.openecomp.dmaapbc
* ================================================================================
* Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
* ============LICENSE_END=========================================================
*/
package org.openecomp.dmaapbc.aaf;
import java.io.IOException;
import org.openecomp.dmaapbc.logging.BaseLoggingClass;
import org.openecomp.dmaapbc.logging.DmaapbcLogMessageEnum;
import org.openecomp.dmaapbc.util.DmaapConfig;
public class AafDecrypt extends BaseLoggingClass {
String dClass = null;
DecryptionInterface dec = null;
public AafDecrypt() {
DmaapConfig p = (DmaapConfig)DmaapConfig.getConfig();
dClass = p.getProperty( "AafDecryption.Class", "org.openecomp.dmaapbc.aaf.ClearDecrypt");
try {
dec = (DecryptionInterface) (Class.forName(dClass).newInstance());
dec.init( p.getProperty("CredentialCodecKeyfile", "LocalKey"));
} catch (Exception ee ) {
errorLogger.error(DmaapbcLogMessageEnum.UNEXPECTED_CONDITION, "attempting to instantiate " + dClass );
}
}
public String decrypt( String encPwd ) {
String pwd = "notDecrypted";
try {
pwd = dec.decrypt( encPwd );
} catch( IOException io ) {
errorLogger.error(DmaapbcLogMessageEnum.DECRYPT_IO_ERROR, dClass, encPwd );
}
return pwd;
}
}
|
3e078e25effe4be93454c201cd49d03ccbb27010
| 1,907 |
java
|
Java
|
src/main/java/seedu/address/logic/commands/EdeleteCommand.java
|
Samuel-bit-prog/tp
|
d133d2caa5dcc376efc48068534227ee6635e3f6
|
[
"MIT"
] | null | null | null |
src/main/java/seedu/address/logic/commands/EdeleteCommand.java
|
Samuel-bit-prog/tp
|
d133d2caa5dcc376efc48068534227ee6635e3f6
|
[
"MIT"
] | null | null | null |
src/main/java/seedu/address/logic/commands/EdeleteCommand.java
|
Samuel-bit-prog/tp
|
d133d2caa5dcc376efc48068534227ee6635e3f6
|
[
"MIT"
] | null | null | null | 35.314815 | 102 | 0.71054 | 3,205 |
package seedu.address.logic.commands;
import static java.util.Objects.requireNonNull;
import java.util.List;
import seedu.address.commons.core.Messages;
import seedu.address.commons.core.index.Index;
import seedu.address.logic.commands.exceptions.CommandException;
import seedu.address.model.Model;
import seedu.address.model.module.event.Event;
/**
* Deletes a member identified using it's displayed index from the address book.
*/
public class EdeleteCommand extends Command {
public static final String COMMAND_WORD = "edelete";
public static final String MESSAGE_USAGE = COMMAND_WORD
+ ": Deletes the event identified by the index number used in the displayed event list.\n"
+ "Parameters: INDEX (must be a positive integer)\n"
+ "Example: " + COMMAND_WORD + " 1";
public static final String MESSAGE_DELETE_EVENT_SUCCESS = "Deleted Event: %1$s";
private final Index targetIndex;
public EdeleteCommand(Index targetIndex) {
this.targetIndex = targetIndex;
}
@Override
public CommandResult execute(Model model) throws CommandException {
requireNonNull(model);
List<Event> lastShownList = model.getFilteredEventList();
if (targetIndex.getZeroBased() >= lastShownList.size()) {
throw new CommandException(Messages.MESSAGE_INVALID_EVENT_DISPLAYED_INDEX);
}
Event eventToDelete = lastShownList.get(targetIndex.getZeroBased());
model.deleteEvent(eventToDelete);
return new CommandResult(String.format(MESSAGE_DELETE_EVENT_SUCCESS, eventToDelete));
}
@Override
public boolean equals(Object other) {
return other == this // short circuit if same object
|| (other instanceof EdeleteCommand // instanceof handles nulls
&& targetIndex.equals(((EdeleteCommand) other).targetIndex)); // state check
}
}
|
3e078ee659f97fef932d9ee8de9fc11863b26e04
| 4,272 |
java
|
Java
|
src/main/java/com/metaquanta/opencvexamples/MotionExampleJava.java
|
metaquanta/jove
|
bc8323e7edbc756880f7d5d48345c62a13217098
|
[
"BSD-3-Clause"
] | 2 |
2015-07-20T13:43:50.000Z
|
2021-01-17T20:02:31.000Z
|
src/main/java/com/metaquanta/opencvexamples/MotionExampleJava.java
|
metaquanta/jove
|
bc8323e7edbc756880f7d5d48345c62a13217098
|
[
"BSD-3-Clause"
] | 2 |
2015-01-17T04:11:39.000Z
|
2018-10-03T01:16:19.000Z
|
src/main/java/com/metaquanta/opencvexamples/MotionExampleJava.java
|
metaquanta/jove
|
bc8323e7edbc756880f7d5d48345c62a13217098
|
[
"BSD-3-Clause"
] | null | null | null | 37.80531 | 111 | 0.561798 | 3,206 |
package com.metaquanta.opencvexamples;
import org.opencv.core.*;
import java.util.ArrayList;
import java.util.List;
import static org.opencv.core.Core.*;
import static org.opencv.core.Core.LINE_AA;
import static org.opencv.imgproc.Imgproc.*;
import static org.opencv.video.Video.*;
/**
* Created by matthew on 4/6/14.
*/
public class MotionExampleJava {
// Source: https://gist.github.com/b95505017/6862032
int last = 0;
// number of cyclic frame buffer used for motion detection
// (should, probably, depend on FPS)
static final int N = 4;
static final double MHI_DURATION = 1;
static final double MAX_TIME_DELTA = 0.5;
static final double MIN_TIME_DELTA = 0.05;
Mat mhi, orient, mask, segmask;
Mat[] buf;
double magnitude, startTime = 0;
static final int diff_threshold = 30;
public Mat update_mhi(Mat img) {
//System.out.println("Processing Frame " + img);
Size size = new Size(img.width(), img.height());
if(buf == null) {
buf = new Mat[N];
for (int i = 0; i < N; i++) {
buf[i] = Mat.zeros(size, CvType.CV_8UC1);
}
mhi = Mat.zeros(size, CvType.CV_32FC1);
segmask = Mat.zeros(size, CvType.CV_32FC1);
mask = Mat.zeros(size, CvType.CV_8UC1);
orient = Mat.zeros(size, CvType.CV_32FC1);
startTime = System.nanoTime();
}
Mat dst = Mat.zeros(size, CvType.CV_8UC3);
double timestamp = (System.nanoTime() - startTime) / 1e9;
int idx1 = last, idx2;
Mat silh;
cvtColor(img, buf[last], COLOR_BGR2GRAY);
double angle, count;
idx2 = (last + 1) % N; // index of (last - (N-1))th frame
last = idx2;
silh = buf[idx2];
absdiff(buf[idx1], buf[idx2], silh);
threshold(silh, silh, diff_threshold, 1, THRESH_BINARY);
updateMotionHistory(silh, mhi, timestamp, MHI_DURATION);
mhi.convertTo(mask, mask.type(), 255.0 / MHI_DURATION,
(MHI_DURATION - timestamp) * 255.0 / MHI_DURATION);
dst.setTo(new Scalar(0));
List<Mat> list = new ArrayList<Mat>(3);
list.add(mask);
list.add(Mat.zeros(mask.size(), mask.type()));
list.add(Mat.zeros(mask.size(), mask.type()));
merge(list, dst);
calcMotionGradient(mhi, mask, orient, MAX_TIME_DELTA, MIN_TIME_DELTA, 3);
MatOfRect roi = new MatOfRect();
segmentMotion(mhi, segmask, roi, timestamp, MAX_TIME_DELTA);
int total = roi.toArray().length;
Rect[] rois = roi.toArray();
Rect comp_rect;
Scalar color;
for (int i = -1; i < total; i++) {
if (i < 0) {
comp_rect = new Rect(0, 0, img.width(), img.height());
color = new Scalar(255, 255, 255);
magnitude = 100;
} else {
comp_rect = rois[i];
if (comp_rect.width + comp_rect.height < 100) // reject very small components
continue;
color = new Scalar(0, 0, 255);
magnitude = 30;
}
Mat silhROI = silh.submat(comp_rect);
Mat mhiROI = mhi.submat(comp_rect);
Mat orientROI = orient.submat(comp_rect);
Mat maskROI = mask.submat(comp_rect);
angle = calcGlobalOrientation(orientROI, maskROI, mhiROI, timestamp, MHI_DURATION);
angle = 360.0 - angle;
count = Core.norm(silhROI, NORM_L1);
silhROI.release();
mhiROI.release();
orientROI.release();
maskROI.release();
if (count < comp_rect.height * comp_rect.width * 0.05) {
continue;
}
Point center = new Point((comp_rect.x + comp_rect.width / 2),
(comp_rect.y + comp_rect.height / 2));
circle(dst, center, (int) Math.round(magnitude * 1.2), color, 3, LINE_AA, 0);
Core.line(dst, center, new Point(
Math.round(center.x + magnitude * Math.cos(angle * Math.PI / 180)),
Math.round(center.y - magnitude * Math.sin(angle * Math.PI / 180))), color, 3, LINE_AA, 0);
}
return dst;
}
}
|
3e078f9afd95af6c5e14ff9b70ce7a17a51fe1fa
| 211 |
java
|
Java
|
src/main/java/quarkus/bookstore/application/dto/BooksDto.java
|
Pio-Trek/Quarkus-Bookstore-Back
|
bcdc8dbfec8a7b144d2f979eaa724bbc2be13307
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/quarkus/bookstore/application/dto/BooksDto.java
|
Pio-Trek/Quarkus-Bookstore-Back
|
bcdc8dbfec8a7b144d2f979eaa724bbc2be13307
|
[
"Apache-2.0"
] | null | null | null |
src/main/java/quarkus/bookstore/application/dto/BooksDto.java
|
Pio-Trek/Quarkus-Bookstore-Back
|
bcdc8dbfec8a7b144d2f979eaa724bbc2be13307
|
[
"Apache-2.0"
] | 1 |
2022-03-18T07:17:38.000Z
|
2022-03-18T07:17:38.000Z
| 12.411765 | 42 | 0.744076 | 3,207 |
package quarkus.bookstore.application.dto;
import lombok.*;
import java.util.List;
@Getter
@Setter
@Builder
@ToString
public class BooksDto {
private List<BookDto> books;
private long booksCount;
}
|
3e078fbfbedec17663fcd35d70c4f1640d07ac21
| 820 |
java
|
Java
|
platform/com.subgraph.vega.api/src/com/subgraph/vega/api/crawler/IWebCrawlerFactory.java
|
BudBundi/Vega
|
c732de3d3fe5be83a27ee1838d9aeb8132b1f9e2
|
[
"MIT"
] | 267 |
2015-01-08T21:17:48.000Z
|
2022-03-20T15:23:20.000Z
|
platform/com.subgraph.vega.api/src/com/subgraph/vega/api/crawler/IWebCrawlerFactory.java
|
BudBundi/Vega
|
c732de3d3fe5be83a27ee1838d9aeb8132b1f9e2
|
[
"MIT"
] | 104 |
2015-01-08T21:26:56.000Z
|
2022-03-28T10:42:06.000Z
|
platform/com.subgraph.vega.api/src/com/subgraph/vega/api/crawler/IWebCrawlerFactory.java
|
BudBundi/Vega
|
c732de3d3fe5be83a27ee1838d9aeb8132b1f9e2
|
[
"MIT"
] | 95 |
2015-02-17T00:58:29.000Z
|
2022-02-23T04:46:18.000Z
| 41 | 80 | 0.637805 | 3,208 |
/*******************************************************************************
* Copyright (c) 2011 Subgraph.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Subgraph - initial API and implementation
******************************************************************************/
package com.subgraph.vega.api.crawler;
import com.subgraph.vega.api.http.requests.IHttpRequestEngine;
import com.subgraph.vega.api.model.requests.IRequestOrigin;
public interface IWebCrawlerFactory {
IWebCrawler create(IRequestOrigin requestOrigin);
IWebCrawler create(IHttpRequestEngine requestEngine);
}
|
3e079099c581a8db98cb2baacd95cd1d4053fd82
| 4,874 |
java
|
Java
|
src/test/java/warikan/domain/model/PartyTest.java
|
KanameMotoyama/warikan-domain-java
|
a18aef363e13cd900a5125c1d4944b18a81c06d9
|
[
"MIT"
] | 18 |
2020-02-18T05:22:57.000Z
|
2021-12-07T02:57:30.000Z
|
src/test/java/warikan/domain/model/PartyTest.java
|
KanameMotoyama/warikan-domain-java
|
a18aef363e13cd900a5125c1d4944b18a81c06d9
|
[
"MIT"
] | null | null | null |
src/test/java/warikan/domain/model/PartyTest.java
|
KanameMotoyama/warikan-domain-java
|
a18aef363e13cd900a5125c1d4944b18a81c06d9
|
[
"MIT"
] | 10 |
2020-11-01T05:03:45.000Z
|
2022-01-18T01:14:15.000Z
| 41.65812 | 95 | 0.724661 | 3,209 |
package warikan.domain.model;
import static org.hamcrest.CoreMatchers.is;
import static org.junit.Assert.assertThat;
import static org.junit.Assert.assertTrue;
import io.vavr.control.Option;
import java.math.BigDecimal;
import org.junit.Test;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import warikan.domain.model.amount.*;
import warikan.domain.model.amount.Money;
import warikan.domain.model.amount.rate.AmountRate;
import warikan.domain.model.amount.rate.PaymentTypeAmountRate;
import warikan.domain.model.amount.rate.PaymentTypeAmountRates;
import warikan.domain.model.amount.types.MemberPaymentType;
import warikan.domain.model.amount.types.MemberPaymentTypes;
import warikan.domain.model.members.Member;
import warikan.domain.model.members.MemberName;
import warikan.domain.model.members.Members;
import warikan.domain.model.members.SecretaryType;
import warikan.domain.model.payment_type.PaymentType;
public class PartyTest {
private final Logger logger = LoggerFactory.getLogger(getClass());
Member kato = Member.of(MemberName.of("加藤"), SecretaryType.Secretary);
Member shaka = Member.of(MemberName.of("村上"), SecretaryType.Secretary);
Member fujii = Member.of(MemberName.of("藤井"));
PartyName name = PartyName.of("TEST");
@Test
public void expectToWarikan_FractionalSharingType_幹事負担() {
MemberPaymentTypes memberPaymentTypes =
MemberPaymentTypes.of(
MemberPaymentType.of(kato, PaymentType.WARIKAN),
MemberPaymentType.of(shaka, PaymentType.WARIKAN));
Party party =
Party.of(
name,
Members.of(kato, shaka),
memberPaymentTypes,
Option.some(DifferenceAmountAdjustmentType.幹事));
// 請求金額
BillingAmount billing = BillingAmount.of(Money.of(BigDecimal.valueOf(33333), Money.JPY));
// 割り勘の設定
PaymentTypeAmountRates paymentTypeAmountRates =
PaymentTypeAmountRates.of(
AmountRate.of(1.00),
memberPaymentTypes,
PaymentTypeAmountRate.of(PaymentType.WARIKAN, AmountRate.of(0.5)));
System.out.println(paymentTypeAmountRates);
// メンバーの割り勘を行う
MemberPaymentAmounts memberPaymentAmounts = party.warikan(billing, paymentTypeAmountRates);
System.out.println("memberPaymentAmounts = " + memberPaymentAmounts);
System.out.println("memberPaymentAmounts.size() = " + memberPaymentAmounts.size());
assertTrue(
memberPaymentAmounts.contains(
MemberPaymentAmount.of(kato, PaymentAmount.of(Money.of(16667, Money.JPY)))));
assertTrue(
memberPaymentAmounts.contains(
MemberPaymentAmount.of(shaka, PaymentAmount.of(Money.of(16666, Money.JPY)))));
assertThat(memberPaymentAmounts.size(), is(2));
// メンバー支払金額の合計
PaymentAmount totalAmount = memberPaymentAmounts.totalPaymentAmount();
assertThat(totalAmount, is(PaymentAmount.of(billing.value())));
System.out.println(totalAmount);
}
@Test
public void expectToWarikan_FractionalSharingType_幹事以外負担() {
MemberPaymentTypes memberPaymentTypes =
MemberPaymentTypes.of(
MemberPaymentType.of(kato, PaymentType.WARIKAN_PLUS),
MemberPaymentType.of(shaka, PaymentType.WARIKAN),
MemberPaymentType.of(fujii, PaymentType.WARIKAN));
Party party =
Party.of(
name,
Members.of(kato, shaka, fujii),
memberPaymentTypes,
Option.some(DifferenceAmountAdjustmentType.幹事以外));
// 請求金額
BillingAmount billing = BillingAmount.of(Money.of(BigDecimal.valueOf(20000), Money.JPY));
// 割り勘の設定
PaymentTypeAmountRates paymentTypeAmountRates =
PaymentTypeAmountRates.of(
AmountRate.of(1.00),
memberPaymentTypes,
PaymentTypeAmountRate.of(PaymentType.WARIKAN, AmountRate.of(0.25)),
PaymentTypeAmountRate.of(PaymentType.WARIKAN_PLUS, AmountRate.of(0.5)));
// メンバーの割り勘を行う
MemberPaymentAmounts memberPaymentAmounts = party.warikan(billing, paymentTypeAmountRates);
System.out.println("memberPaymentAmounts = " + memberPaymentAmounts);
System.out.println("memberPaymentAmounts.size() = " + memberPaymentAmounts.size());
assertTrue(
memberPaymentAmounts.contains(
MemberPaymentAmount.of(kato, PaymentAmount.of(Money.of(10000, Money.JPY)))));
assertTrue(
memberPaymentAmounts.contains(
MemberPaymentAmount.of(shaka, PaymentAmount.of(Money.of(5000, Money.JPY)))));
assertTrue(
memberPaymentAmounts.contains(
MemberPaymentAmount.of(fujii, PaymentAmount.of(Money.of(5000, Money.JPY)))));
assertThat(memberPaymentAmounts.size(), is(3));
// メンバー支払金額の合計
PaymentAmount totalAmount = memberPaymentAmounts.totalPaymentAmount();
assertThat(totalAmount, is(PaymentAmount.of(billing.value())));
System.out.println(totalAmount);
}
}
|
3e0790f94dd964450ea1805f340f9401e7b5adf5
| 4,045 |
java
|
Java
|
opentracing_shim/src/main/java/io/opentelemetry/opentracingshim/SpanContextShim.java
|
Oberon00/opentelemetry-java
|
2675c4fb94a203dd0355a8be6d87eb67871f0e41
|
[
"Apache-2.0"
] | null | null | null |
opentracing_shim/src/main/java/io/opentelemetry/opentracingshim/SpanContextShim.java
|
Oberon00/opentelemetry-java
|
2675c4fb94a203dd0355a8be6d87eb67871f0e41
|
[
"Apache-2.0"
] | null | null | null |
opentracing_shim/src/main/java/io/opentelemetry/opentracingshim/SpanContextShim.java
|
Oberon00/opentelemetry-java
|
2675c4fb94a203dd0355a8be6d87eb67871f0e41
|
[
"Apache-2.0"
] | null | null | null | 29.311594 | 99 | 0.721632 | 3,210 |
/*
* Copyright 2019, OpenTelemetry Authors
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package io.opentelemetry.opentracingshim;
import io.opentelemetry.distributedcontext.DistributedContext;
import io.opentelemetry.distributedcontext.Entry;
import io.opentelemetry.distributedcontext.EntryKey;
import io.opentelemetry.distributedcontext.EntryMetadata;
import io.opentelemetry.distributedcontext.EntryValue;
import io.opentracing.SpanContext;
import java.util.Iterator;
import java.util.Map;
final class SpanContextShim extends BaseShimObject implements SpanContext {
static final EntryMetadata DEFAULT_ENTRY_METADATA =
EntryMetadata.create(EntryMetadata.EntryTtl.UNLIMITED_PROPAGATION);
private final io.opentelemetry.trace.SpanContext context;
private final DistributedContext distContext;
public SpanContextShim(SpanShim spanShim) {
this(
spanShim.telemetryInfo(),
spanShim.getSpan().getContext(),
spanShim.telemetryInfo().emptyDistributedContext());
}
public SpanContextShim(TelemetryInfo telemetryInfo, io.opentelemetry.trace.SpanContext context) {
this(telemetryInfo, context, telemetryInfo.emptyDistributedContext());
}
public SpanContextShim(
TelemetryInfo telemetryInfo,
io.opentelemetry.trace.SpanContext context,
DistributedContext distContext) {
super(telemetryInfo);
this.context = context;
this.distContext = distContext;
}
SpanContextShim newWithKeyValue(String key, String value) {
DistributedContext.Builder builder = contextManager().contextBuilder().setParent(distContext);
builder.put(EntryKey.create(key), EntryValue.create(value), DEFAULT_ENTRY_METADATA);
return new SpanContextShim(telemetryInfo(), context, builder.build());
}
io.opentelemetry.trace.SpanContext getSpanContext() {
return context;
}
DistributedContext getDistributedContext() {
return distContext;
}
@Override
public String toTraceId() {
return context.getTraceId().toString();
}
@Override
public String toSpanId() {
return context.getSpanId().toString();
}
@Override
public Iterable<Map.Entry<String, String>> baggageItems() {
final Iterator<Entry> iterator = distContext.getEntries().iterator();
return new BaggageIterable(iterator);
}
@SuppressWarnings("ReturnMissingNullable")
String getBaggageItem(String key) {
EntryValue value = distContext.getEntryValue(EntryKey.create(key));
return value == null ? null : value.asString();
}
static class BaggageIterable implements Iterable<Map.Entry<String, String>> {
final Iterator<Entry> iterator;
BaggageIterable(Iterator<Entry> iterator) {
this.iterator = iterator;
}
@Override
public Iterator<Map.Entry<String, String>> iterator() {
return new Iterator<Map.Entry<String, String>>() {
@Override
public boolean hasNext() {
return iterator.hasNext();
}
@Override
public Map.Entry<String, String> next() {
return new BaggageEntry(iterator.next());
}
};
}
}
static class BaggageEntry implements Map.Entry<String, String> {
final Entry entry;
BaggageEntry(Entry entry) {
this.entry = entry;
}
@Override
public String getKey() {
return entry.getKey().getName();
}
@Override
public String getValue() {
return entry.getValue().asString();
}
@Override
public String setValue(String value) {
return getValue();
}
}
}
|
3e0791495d01cbe71572fe2f9e8571330632b3c4
| 1,683 |
java
|
Java
|
rpm.ui.client/src/org/fubabaz/rpm/connection/pool/AbstractConnectionPool.java
|
fubabaz/rpm
|
841c4deefcc7c6b4a218702fe6aaf98ff3e5e470
|
[
"Apache-2.0"
] | 1 |
2020-12-03T03:00:18.000Z
|
2020-12-03T03:00:18.000Z
|
rpm.ui.client/src/org/fubabaz/rpm/connection/pool/AbstractConnectionPool.java
|
fubabaz/rpm
|
841c4deefcc7c6b4a218702fe6aaf98ff3e5e470
|
[
"Apache-2.0"
] | null | null | null |
rpm.ui.client/src/org/fubabaz/rpm/connection/pool/AbstractConnectionPool.java
|
fubabaz/rpm
|
841c4deefcc7c6b4a218702fe6aaf98ff3e5e470
|
[
"Apache-2.0"
] | null | null | null | 25.892308 | 97 | 0.755199 | 3,211 |
/**
* Copyright 2017 FuBaBaz Team.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.fubabaz.rpm.connection.pool;
import java.sql.Connection;
import java.sql.SQLException;
import javax.sql.DataSource;
import org.fubabaz.rpm.connection.ConnectionInfo;
import org.fubabaz.rpm.exception.SystemException;
/**
* @author ejpark
*
*/
public abstract class AbstractConnectionPool implements IConnectionPool, IConnectionInitializer {
private DataSource dataSource;
@Override
public void initialize(ConnectionInfo connectionInfo) {
this.dataSource = getDataSource(connectionInfo);
}
@Override
public Connection getConnection() {
Connection connection = null;
try {
connection = this.dataSource.getConnection();
} catch (SQLException e) {
throw new SystemException(e);
}
return connection;
}
protected int getInitConnCount() {
return ConnectionPoolConfig.INIT_CONN_CNT;
}
protected int getMaxConnCount() {
return ConnectionPoolConfig.MAX_CONN_COUNT;
}
protected long getMaxWait() {
return ConnectionPoolConfig.MAX_WAIT;
}
public abstract DataSource getDataSource(ConnectionInfo connectionInfo);
}
|
3e0792e2aa417780600c4017646c2dfd636d6753
| 1,107 |
java
|
Java
|
src/main/java/com/ssm/controller/UserController.java
|
Ergoy/ssm-personnel
|
9a9e30a76531dfb73ba3ad8dee46b22d4d2e74fa
|
[
"MIT"
] | null | null | null |
src/main/java/com/ssm/controller/UserController.java
|
Ergoy/ssm-personnel
|
9a9e30a76531dfb73ba3ad8dee46b22d4d2e74fa
|
[
"MIT"
] | null | null | null |
src/main/java/com/ssm/controller/UserController.java
|
Ergoy/ssm-personnel
|
9a9e30a76531dfb73ba3ad8dee46b22d4d2e74fa
|
[
"MIT"
] | null | null | null | 29.918919 | 62 | 0.70009 | 3,212 |
package com.ssm.controller;
import com.ssm.model.User;
import com.ssm.service.IUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;
@Controller
@RequestMapping("/user")
public class UserController {
@Autowired
private IUserService userService;
@RequestMapping("/select")
public ModelAndView selectUser() throws Exception {
ModelAndView mv = new ModelAndView();
User user = userService.selectUser(1);
mv.addObject("user", user);
mv.setViewName("selectUser");
return mv;
}
@RequestMapping("/loginform")
public ModelAndView loginform() throws Exception {
ModelAndView mv = new ModelAndView();
mv.setViewName("loginForm");
return mv;
}
@RequestMapping("/login")
public ModelAndView login() throws Exception {
ModelAndView mv = new ModelAndView();
mv.setViewName("index");
return mv;
}
}
|
3e079451f5d28507c5d4695d488dcc721c67ab56
| 6,021 |
java
|
Java
|
projects/connector-manager/source/java/com/google/enterprise/connector/instantiator/BatchCoordinator.java
|
KalibriCuga/google-enterprise-connector-manager
|
49b8cd008b6604f8cf3d8660fda23dcfb3245e24
|
[
"Apache-2.0"
] | 11 |
2015-04-06T19:32:10.000Z
|
2021-12-07T13:08:33.000Z
|
projects/connector-manager/source/java/com/google/enterprise/connector/instantiator/BatchCoordinator.java
|
KalibriCuga/google-enterprise-connector-manager
|
49b8cd008b6604f8cf3d8660fda23dcfb3245e24
|
[
"Apache-2.0"
] | 1 |
2015-08-05T21:46:18.000Z
|
2015-08-05T21:46:18.000Z
|
projects/connector-manager/source/java/com/google/enterprise/connector/instantiator/BatchCoordinator.java
|
KalibriCuga/google-enterprise-connector-manager
|
49b8cd008b6604f8cf3d8660fda23dcfb3245e24
|
[
"Apache-2.0"
] | 6 |
2015-04-24T20:06:35.000Z
|
2020-02-04T02:49:25.000Z
| 40.409396 | 78 | 0.734097 | 3,213 |
// Copyright (C) 2009 Google Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package com.google.enterprise.connector.instantiator;
import com.google.enterprise.connector.persist.ConnectorNotFoundException;
import com.google.enterprise.connector.traversal.BatchResult;
import com.google.enterprise.connector.traversal.BatchResultRecorder;
import com.google.enterprise.connector.traversal.BatchTimeout;
import com.google.enterprise.connector.traversal.TraversalStateStore;
import java.util.logging.Logger;
/**
* Coordinate operations that apply to a running batch with other changes that
* affect this [@link {@link ConnectorCoordinatorImpl}.
* <p>
* The {@link ConnectorCoordinatorImpl} monitor is used to guard batch
* operations.
* <p>
* To avoid long held locks the {@link ConnectorCoordinatorImpl} monitor is
* not held while a batch runs or even between the time a batch is canceled
* and the time its background processing completes. Therefore, a lingering
* batch may attempt to record completion information, modify the checkpoint
* or timeout after the lingering batch has been canceled. These operations
* may even occur after a new batch has started. To avoid corrupting the
* {@link ConnectorCoordinatorImpl} state this class employs the batchKey
* protocol to disable completion operations that are performed on behalf of
* lingering batches. Here is how the protocol works.
* <OL>
* <LI>To start a batch starts while holding the
* {@link ConnectorCoordinatorImpl} monitor assign the batch a unique key.
* Store the key in ConnectorCoordinator.this.currentBatchKey. Also create a
* {@link BatchCoordinator} with BatchCoordinator.requiredBatchKey set to the
* key for the batch.
* <LI>To cancel a batch while holding the ConnectorCoordinatorImpl monitor,
* null out ConnectorCoordinator.this.currentBatchKey.
* <LI>The {@link BatchCoordinator} performs all completion operations for a
* batch and prevents operations on behalf of non current batches. To check
* while holding the {@link ConnectorCoordinatorImpl} monitor it
* verifies that
* BatchCoordinator.requiredBatchKey equals
* ConnectorCoordinator.this.currentBatchKey.
* </OL>
*/
class BatchCoordinator implements TraversalStateStore,
BatchResultRecorder, BatchTimeout {
private static final Logger LOGGER =
Logger.getLogger(BatchCoordinator.class.getName());
private String cachedState;
private final Object requiredBatchKey;
private final ConnectorCoordinatorImpl connectorCoordinator;
/**
* Creates a BatchCoordinator
*/
BatchCoordinator(ConnectorCoordinatorImpl connectorCoordinator)
throws ConnectorNotFoundException {
this.requiredBatchKey = connectorCoordinator.currentBatchKey;
this.cachedState = connectorCoordinator.getConnectorState();
this.connectorCoordinator = connectorCoordinator;
}
public String getTraversalState() {
synchronized (connectorCoordinator) {
if (connectorCoordinator.currentBatchKey == requiredBatchKey) {
return cachedState;
} else {
throw new BatchCompletedException();
}
}
}
public void storeTraversalState(String state) {
synchronized (connectorCoordinator) {
// Make sure our batch is still valid and that nobody has modified
// the checkpoint while we were away.
try {
if ((connectorCoordinator.currentBatchKey == requiredBatchKey) &&
isCheckpointUnmodified()) {
connectorCoordinator.setConnectorState(state);
cachedState = state;
} else {
throw new BatchCompletedException();
}
} catch (ConnectorNotFoundException cnfe) {
// Connector disappeared while we were away.
// Don't try to store results.
throw new BatchCompletedException();
}
}
}
public void recordResult(BatchResult result) {
synchronized (connectorCoordinator) {
if (connectorCoordinator.currentBatchKey == requiredBatchKey) {
connectorCoordinator.recordResult(result);
} else {
LOGGER.fine("Ignoring a BatchResult returned from a "
+ "prevously canceled traversal batch. Connector = "
+ connectorCoordinator.getConnectorName()
+ " result = " + result + " batchKey = " + requiredBatchKey);
}
}
}
public void timeout() {
synchronized (connectorCoordinator) {
if (connectorCoordinator.currentBatchKey == requiredBatchKey) {
connectorCoordinator.resetBatch();
} else {
LOGGER.warning("Ignoring Timeout for previously prevously canceled"
+ " or completed traversal batch. Connector = "
+ connectorCoordinator.getConnectorName()
+ " batchKey = "+ requiredBatchKey);
}
}
}
// Returns true if the stored traversal state has not been modified since
// we started, false if the persisted state does not match our cache.
private boolean isCheckpointUnmodified() throws ConnectorNotFoundException {
String currentState = connectorCoordinator.getConnectorState();
if (currentState == cachedState) {
return true;
} else {
return (cachedState != null) && cachedState.equals(currentState);
}
}
// TODO(strellis): Add this Exception to throws for BatchRecorder,
// TraversalStateStore, BatchTimeout interfaces and catch this
// specific exception rather than IllegalStateException.
private static class BatchCompletedException extends IllegalStateException {
}
}
|
3e07962fe2cb463b0ece983d42ec2879f9653e3c
| 660 |
java
|
Java
|
app/src/main/java/it/polito/mad/countonme/messaging/FirebaseIDService.java
|
madgroup17/countonme
|
777113fe3d538c3c969a33c28632b0ea383b366c
|
[
"Apache-2.0"
] | null | null | null |
app/src/main/java/it/polito/mad/countonme/messaging/FirebaseIDService.java
|
madgroup17/countonme
|
777113fe3d538c3c969a33c28632b0ea383b366c
|
[
"Apache-2.0"
] | null | null | null |
app/src/main/java/it/polito/mad/countonme/messaging/FirebaseIDService.java
|
madgroup17/countonme
|
777113fe3d538c3c969a33c28632b0ea383b366c
|
[
"Apache-2.0"
] | null | null | null | 25.384615 | 76 | 0.760606 | 3,214 |
package it.polito.mad.countonme.messaging;
import android.os.Binder;
import android.os.IBinder;
import android.util.Log;
import com.google.firebase.iid.FirebaseInstanceId;
import com.google.firebase.iid.FirebaseInstanceIdService;
/**
* Created by francescobruno on 20/05/17.
*/
public class FirebaseIDService extends FirebaseInstanceIdService {
private static final String TAG = "FirebaseIDService";
@Override
public void onTokenRefresh() {
String refreshedToken = FirebaseInstanceId.getInstance().getToken();
sendRegistrationToServer(refreshedToken);
}
private void sendRegistrationToServer(String token) {
}
}
|
3e079734196643f777887ea67d50571f5c49f08f
| 853 |
java
|
Java
|
bundles/com.zeligsoft.domain.omg.corba.dsl/src-gen/com/zeligsoft/domain/omg/corba/dsl/idl/impl/SequenceParamTypeImpl.java
|
elder4p/CX4CBDDS
|
9f46115f3e4b075ceb4f6692bd9f95410df50895
|
[
"Apache-2.0"
] | null | null | null |
bundles/com.zeligsoft.domain.omg.corba.dsl/src-gen/com/zeligsoft/domain/omg/corba/dsl/idl/impl/SequenceParamTypeImpl.java
|
elder4p/CX4CBDDS
|
9f46115f3e4b075ceb4f6692bd9f95410df50895
|
[
"Apache-2.0"
] | null | null | null |
bundles/com.zeligsoft.domain.omg.corba.dsl/src-gen/com/zeligsoft/domain/omg/corba/dsl/idl/impl/SequenceParamTypeImpl.java
|
elder4p/CX4CBDDS
|
9f46115f3e4b075ceb4f6692bd9f95410df50895
|
[
"Apache-2.0"
] | null | null | null | 19.837209 | 95 | 0.643611 | 3,215 |
/**
*/
package com.zeligsoft.domain.omg.corba.dsl.idl.impl;
import com.zeligsoft.domain.omg.corba.dsl.idl.IdlPackage;
import com.zeligsoft.domain.omg.corba.dsl.idl.SequenceParamType;
import org.eclipse.emf.ecore.EClass;
/**
* <!-- begin-user-doc -->
* An implementation of the model object '<em><b>Sequence Param Type</b></em>'.
* <!-- end-user-doc -->
* <p>
* </p>
*
* @generated
*/
public class SequenceParamTypeImpl extends FormalParameterTypeImpl implements SequenceParamType
{
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected SequenceParamTypeImpl()
{
super();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
protected EClass eStaticClass()
{
return IdlPackage.Literals.SEQUENCE_PARAM_TYPE;
}
} //SequenceParamTypeImpl
|
3e079815a6a0f82ecd945803a1cd6c4f2fd050ec
| 1,817 |
java
|
Java
|
dspace-api/src/main/java/org/dspace/batch/factory/ImpServiceFactoryImpl.java
|
steph-ieffam/DSpace
|
fdcd064f7de8d39859f267b681e3aa9cd06f6d91
|
[
"BSD-3-Clause"
] | 35 |
2016-09-27T14:34:43.000Z
|
2021-12-15T11:20:31.000Z
|
dspace-api/src/main/java/org/dspace/batch/factory/ImpServiceFactoryImpl.java
|
steph-ieffam/DSpace
|
fdcd064f7de8d39859f267b681e3aa9cd06f6d91
|
[
"BSD-3-Clause"
] | 110 |
2016-09-15T13:49:39.000Z
|
2022-02-01T07:00:17.000Z
|
dspace-api/src/main/java/org/dspace/batch/factory/ImpServiceFactoryImpl.java
|
steph-ieffam/DSpace
|
fdcd064f7de8d39859f267b681e3aa9cd06f6d91
|
[
"BSD-3-Clause"
] | 81 |
2016-11-28T12:52:20.000Z
|
2022-03-07T16:12:20.000Z
| 29.786885 | 83 | 0.777655 | 3,216 |
/**
* The contents of this file are subject to the license and copyright
* detailed in the LICENSE and NOTICE files at the root of the source
* tree and available online at
*
* http://www.dspace.org/license/
*/
package org.dspace.batch.factory;
import org.dspace.batch.service.ImpBitstreamMetadatavalueService;
import org.dspace.batch.service.ImpBitstreamService;
import org.dspace.batch.service.ImpMetadatavalueService;
import org.dspace.batch.service.ImpRecordService;
import org.dspace.batch.service.ImpServiceFactory;
import org.dspace.batch.service.ImpWorkflowNStateService;
import org.springframework.beans.factory.annotation.Autowired;
public class ImpServiceFactoryImpl extends ImpServiceFactory {
@Autowired(required = true)
private ImpBitstreamService impBitstreamService;
@Autowired(required = true)
private ImpBitstreamMetadatavalueService impBitstreamMetadatavalueService;
@Autowired(required = true)
private ImpMetadatavalueService impMetadatavalueService;
@Autowired(required = true)
private ImpRecordService impRecordService;
@Autowired(required = true)
private ImpWorkflowNStateService impWorkflowNStateService;
@Override
public ImpBitstreamService getImpBitstreamService() {
return impBitstreamService;
}
@Override
public ImpBitstreamMetadatavalueService getImpBitstreamMetadatavalueService() {
return impBitstreamMetadatavalueService;
}
@Override
public ImpMetadatavalueService getImpMetadatavalueService() {
return impMetadatavalueService;
}
@Override
public ImpRecordService getImpRecordService() {
return impRecordService;
}
@Override
public ImpWorkflowNStateService getImpWorkflowNStateService() {
return impWorkflowNStateService;
}
}
|
3e07988ac3f8175cb1a7cf697bd74a417ac390e7
| 12,453 |
java
|
Java
|
integration-test/src/main/java/com/sequenceiq/it/cloudbreak/newway/cloud/AzureCloudProvider.java
|
Chaffelson/cloudbreak
|
a465a06dae43835c46503a2e4f30e46250249dcb
|
[
"Apache-2.0"
] | null | null | null |
integration-test/src/main/java/com/sequenceiq/it/cloudbreak/newway/cloud/AzureCloudProvider.java
|
Chaffelson/cloudbreak
|
a465a06dae43835c46503a2e4f30e46250249dcb
|
[
"Apache-2.0"
] | null | null | null |
integration-test/src/main/java/com/sequenceiq/it/cloudbreak/newway/cloud/AzureCloudProvider.java
|
Chaffelson/cloudbreak
|
a465a06dae43835c46503a2e4f30e46250249dcb
|
[
"Apache-2.0"
] | null | null | null | 39.037618 | 120 | 0.71276 | 3,217 |
package com.sequenceiq.it.cloudbreak.newway.cloud;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
import java.util.Set;
import com.sequenceiq.cloudbreak.api.model.AmbariStackDetailsJson;
import com.sequenceiq.cloudbreak.api.model.stack.StackAuthenticationRequest;
import com.sequenceiq.cloudbreak.api.model.v2.AmbariV2Request;
import com.sequenceiq.cloudbreak.api.model.v2.NetworkV2Request;
import com.sequenceiq.cloudbreak.api.model.v2.TemplateV2Request;
import com.sequenceiq.it.cloudbreak.newway.Cluster;
import com.sequenceiq.it.cloudbreak.newway.Credential;
import com.sequenceiq.it.cloudbreak.newway.CredentialEntity;
import com.sequenceiq.it.cloudbreak.newway.StackAction;
import com.sequenceiq.it.cloudbreak.newway.StackCreation;
import com.sequenceiq.it.cloudbreak.newway.StackEntity;
import com.sequenceiq.it.cloudbreak.newway.TestParameter;
import com.sequenceiq.it.cloudbreak.parameters.RequiredInputParameters.Azure.Database.Hive;
import com.sequenceiq.it.cloudbreak.parameters.RequiredInputParameters.Azure.Database.Ranger;
public class AzureCloudProvider extends CloudProviderHelper {
public static final String AZURE = "azure";
public static final String AZURE_CAPITAL = "AZURE";
private static final String CREDENTIAL_DEFAULT_NAME = "autotesting-azure-cred";
private static final String BLUEPRINT_DEFAULT_NAME = "Data Science: Apache Spark 2, Apache Zeppelin";
private static final String AZURE_CLUSTER_DEFAULT_NAME = "autotesting-azure-cluster";
private static final String NETWORK_DEFAULT_NAME = "autotesting-azure-net";
private static final String VPC_DEFAULT_ID = "aszegedi";
private static final String SUBNET_DEFAULT_ID = "default";
private static final String RESOURCE_GROUP_DEFAULT_NAME = "aszegedi";
private static final String DEFAULT_SUBNET_CIDR = "10.0.0.0/16";
private static final String NETWORK_DEFAULT_DESCRIPTION = "autotesting azure network";
private static final String CREDENTIAL_ACCESS_KEY_ENV_KEY = "integrationtest.azurermcredential.accessKey";
private static final String CREDENTIAL_SECRET_KEY_ENV_KEY = "integrationtest.azurermcredential.secretKey";
private static final String CREDENTIAL_TENANT_ID_ENV_KEY = "integrationtest.azurermcredential.tenantId";
private static final String CREDENTIAL_SUBSCRIPTION_ID_ENV_KEY = "integrationtest.azurermcredential.subscriptionId";
private static final String ACCESS_KEY_PARAM_KEY = "accessKey";
private static final String SECRET_KEY_PARAM_KEY = "secretKey";
private static final String SUBSCRIPTION_ID_PARAM_KEY = "subscriptionId";
private static final String TENANT_ID_PARAM_KEY = "tenantId";
private static final String GENERIC_TEST_VALUE = "12345abcdefg789";
private final ResourceHelper<?> resourceHelper;
public AzureCloudProvider(TestParameter testParameter) {
super(testParameter);
String storageType = testParameter.get("cloudStorageType");
if (storageType != null) {
switch (storageType.toUpperCase()) {
case "WASB":
resourceHelper = new AzureWasbResourceHelper(testParameter, "-azure-wasb");
break;
default:
resourceHelper = new AzureAdlsResourceHelper(testParameter, "-azure-adls");
break;
}
} else {
resourceHelper = new AzureWasbResourceHelper(testParameter, "-azure-wasb");
}
}
@Override
public CredentialEntity aValidCredential(boolean create) {
CredentialEntity credential = create ? Credential.isCreated() : Credential.request();
return credential
.withName(getCredentialName())
.withDescription(CREDENTIAL_DEFAULT_DESCRIPTION)
.withCloudPlatform(AZURE_CAPITAL)
.withParameters(azureCredentialDetails());
}
@Override
public String availabilityZone() {
return null;
}
@Override
public String region() {
return getTestParameter().getWithDefault("azureRegion", "North Europe");
}
@Override
StackAuthenticationRequest stackauth() {
StackAuthenticationRequest stackauth = new StackAuthenticationRequest();
stackauth.setPublicKey(getTestParameter().get(INTEGRATIONTEST_PUBLIC_KEY_FILE).substring(BEGIN_INDEX));
return stackauth;
}
@Override
public TemplateV2Request template() {
TemplateV2Request t = new TemplateV2Request();
t.setInstanceType(getTestParameter().getWithDefault("azureInstanceType", "Standard_D3_v2"));
t.setVolumeCount(Integer.parseInt(getTestParameter().getWithDefault("azureInstanceVolumeCount", "1")));
t.setVolumeSize(Integer.parseInt(getTestParameter().getWithDefault("azureInstanceVolumeSize", "100")));
t.setVolumeType(getTestParameter().getWithDefault("azureInstanceVolumeType", "Standard_LRS"));
Map<String, Object> params = new HashMap<>();
params.put("encrypted", "false");
params.put("managedDisk", "true");
t.setParameters(params);
return t;
}
@Override
public String getClusterName() {
return getTestParameter().getWithDefault("azureClusterName", AZURE_CLUSTER_DEFAULT_NAME);
}
@Override
public String getPlatform() {
return AZURE_CAPITAL;
}
@Override
public String getCredentialName() {
return getTestParameter().getWithDefault("azureCredentialName", CREDENTIAL_DEFAULT_NAME);
}
@Override
public String getBlueprintName() {
return getTestParameter().getWithDefault("azureBlueprintName", BLUEPRINT_DEFAULT_NAME);
}
@Override
public String getNetworkName() {
return getTestParameter().getWithDefault("azureNetworkName", NETWORK_DEFAULT_NAME);
}
@Override
public String getSubnetCIDR() {
return getTestParameter().getWithDefault("azureSubnetCIDR", DEFAULT_SUBNET_CIDR);
}
@Override
public String getVpcId() {
return getTestParameter().getWithDefault("azureVcpId", VPC_DEFAULT_ID);
}
@Override
public String getSubnetId() {
return getTestParameter().getWithDefault("azureSubnetId", SUBNET_DEFAULT_ID);
}
public String getResourceGroupName() {
return getTestParameter().getWithDefault("resourceGroupName", RESOURCE_GROUP_DEFAULT_NAME);
}
public boolean getNoFirewallRules() {
Boolean firewallRules = Boolean.valueOf(getTestParameter().get("azureNoFirewallRules"));
return firewallRules == null ? false : firewallRules;
}
public boolean getNoPublicIp() {
Boolean publicIp = Boolean.valueOf(getTestParameter().get("azureNoPublicIp"));
return publicIp == null ? false : publicIp;
}
@Override
public Map<String, Object> newNetworkProperties() {
return null;
}
@Override
public Map<String, Object> networkProperties() {
return null;
}
@Override
public Map<String, Object> subnetProperties() {
Map<String, Object> map = new HashMap<>();
map.put("subnetId", getSubnetId());
map.put("networkId", getVpcId());
map.put("resourceGroupName", getResourceGroupName());
map.put("noFirewallRules", getNoFirewallRules());
map.put("noPublicIp", getNoPublicIp());
return map;
}
@Override
public NetworkV2Request newNetwork() {
NetworkV2Request network = new NetworkV2Request();
network.setSubnetCIDR(getSubnetCIDR());
return network;
}
@Override
public NetworkV2Request existingNetwork() {
return null;
}
@Override
public NetworkV2Request existingSubnet() {
NetworkV2Request network = new NetworkV2Request();
network.setParameters(subnetProperties());
return network;
}
@Override
public AmbariV2Request getAmbariRequestWithNoConfigStrategyAndEmptyMpacks(String blueprintName) {
var ambari = ambariRequestWithBlueprintName(blueprintName);
var stackDetails = new AmbariStackDetailsJson();
stackDetails.setMpacks(Collections.emptyList());
ambari.setConfigStrategy(null);
ambari.setAmbariStackDetails(stackDetails);
return ambari;
}
@Override
public ResourceHelper<?> getResourceHelper() {
return resourceHelper;
}
@Override
public Cluster aValidDatalakeCluster() {
return Cluster.request()
.withAmbariRequest(ambariRequestWithBlueprintName(getDatalakeBlueprintName()))
.withCloudStorage(resourceHelper.getCloudStorageRequestForDatalake())
.withRdsConfigNames(Set.of(
getTestParameter().get(Ranger.CONFIG_NAME),
getTestParameter().get(Hive.CONFIG_NAME)))
.withLdapConfigName(resourceHelper.getLdapConfigName());
}
@Override
public Cluster aValidAttachedCluster(String datalakeClusterName) {
return Cluster.request()
.withSharedService(datalakeClusterName)
.withAmbariRequest(ambariRequestWithBlueprintName(getBlueprintName()))
.withCloudStorage(resourceHelper.getCloudStorageRequestForAttachedCluster())
.withRdsConfigNames(new HashSet<>(Arrays.asList(
getTestParameter().get(Ranger.CONFIG_NAME),
getTestParameter().get(Hive.CONFIG_NAME))))
.withLdapConfigName(resourceHelper.getLdapConfigName());
}
public Map<String, Object> azureCredentialDetails() {
Map<String, Object> map = new HashMap<>();
map.put(ACCESS_KEY_PARAM_KEY, getTestParameter().get(CREDENTIAL_ACCESS_KEY_ENV_KEY));
map.put(SECRET_KEY_PARAM_KEY, getTestParameter().get(CREDENTIAL_SECRET_KEY_ENV_KEY));
map.put(SUBSCRIPTION_ID_PARAM_KEY, getTestParameter().get(CREDENTIAL_SUBSCRIPTION_ID_ENV_KEY));
map.put(TENANT_ID_PARAM_KEY, getTestParameter().get(CREDENTIAL_TENANT_ID_ENV_KEY));
return map;
}
public Map<String, Object> azureCredentialDetailsInvalidAccessKey() {
Map<String, Object> map = new HashMap<>();
map.put(ACCESS_KEY_PARAM_KEY, GENERIC_TEST_VALUE);
map.put(SECRET_KEY_PARAM_KEY, getTestParameter().get(CREDENTIAL_SECRET_KEY_ENV_KEY));
map.put(SUBSCRIPTION_ID_PARAM_KEY, getTestParameter().get(CREDENTIAL_SUBSCRIPTION_ID_ENV_KEY));
map.put(TENANT_ID_PARAM_KEY, getTestParameter().get(CREDENTIAL_TENANT_ID_ENV_KEY));
return map;
}
public Map<String, Object> azureCredentialDetailsInvalidSecretKey() {
Map<String, Object> map = new HashMap<>();
map.put(ACCESS_KEY_PARAM_KEY, getTestParameter().get(CREDENTIAL_ACCESS_KEY_ENV_KEY));
map.put(SECRET_KEY_PARAM_KEY, GENERIC_TEST_VALUE);
map.put(SUBSCRIPTION_ID_PARAM_KEY, getTestParameter().get(CREDENTIAL_SUBSCRIPTION_ID_ENV_KEY));
map.put(TENANT_ID_PARAM_KEY, getTestParameter().get(CREDENTIAL_TENANT_ID_ENV_KEY));
return map;
}
public Map<String, Object> azureCredentialDetailsInvalidSubscriptionID() {
Map<String, Object> map = new HashMap<>();
map.put(ACCESS_KEY_PARAM_KEY, getTestParameter().get(CREDENTIAL_ACCESS_KEY_ENV_KEY));
map.put(SECRET_KEY_PARAM_KEY, getTestParameter().get(CREDENTIAL_SECRET_KEY_ENV_KEY));
map.put(SUBSCRIPTION_ID_PARAM_KEY, GENERIC_TEST_VALUE);
map.put(TENANT_ID_PARAM_KEY, getTestParameter().get(CREDENTIAL_TENANT_ID_ENV_KEY));
return map;
}
public Map<String, Object> azureCredentialDetailsInvalidTenantID() {
Map<String, Object> map = new HashMap<>();
map.put(ACCESS_KEY_PARAM_KEY, getTestParameter().get(CREDENTIAL_ACCESS_KEY_ENV_KEY));
map.put(SECRET_KEY_PARAM_KEY, getTestParameter().get(CREDENTIAL_SECRET_KEY_ENV_KEY));
map.put(SUBSCRIPTION_ID_PARAM_KEY, getTestParameter().get(CREDENTIAL_SUBSCRIPTION_ID_ENV_KEY));
map.put(TENANT_ID_PARAM_KEY, GENERIC_TEST_VALUE);
return map;
}
@Override
public StackEntity aValidAttachedStackRequest() {
var request = new StackCreation(aValidStackRequest());
request.setCreationStrategy(StackAction::determineNetworkAzureFromDatalakeStack);
return request.getStack();
}
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.