Skip to content

Commit

Permalink
using setUpTest instead of setupSuiteScopeCluster
Browse files Browse the repository at this point in the history
  • Loading branch information
gbbafna committed Sep 2, 2023
1 parent 0af7d70 commit 2f85d03
Showing 1 changed file with 6 additions and 3 deletions.
Expand Up @@ -32,6 +32,7 @@

package org.opensearch.search.profile.aggregation;

import org.junit.Before;
import org.opensearch.action.index.IndexRequestBuilder;
import org.opensearch.action.search.SearchResponse;
import org.opensearch.search.aggregations.Aggregator.SubAggCollectionMode;
Expand Down Expand Up @@ -162,8 +163,9 @@ protected int numberOfShards() {
return 1;
}

@Override
protected void setupSuiteScopeCluster() throws Exception {

@Before
public void setUpTest() throws Exception {
assertAcked(
client().admin()
.indices()
Expand Down Expand Up @@ -196,7 +198,7 @@ protected void setupSuiteScopeCluster() throws Exception {
createIndex("idx_unmapped");
}

public void testSimpleProfile() {
public void testSimpleProfile() {
SearchResponse response = client().prepareSearch("idx")
.setProfile(true)
.addAggregation(histogram("histo").field(NUMBER_FIELD).interval(1L))
Expand Down Expand Up @@ -244,6 +246,7 @@ public void testSimpleProfile() {
}

public void testMultiLevelProfile() {

SearchResponse response = client().prepareSearch("idx")
.setProfile(true)
.addAggregation(
Expand Down

0 comments on commit 2f85d03

Please sign in to comment.