**Build scan:**
https://gradle-enterprise.elastic.co/s/7vcre2by7feoe/tests/:server:internalClusterTest/org.elasticsearch.search.aggregations.bucket.SignificantTermsSignificanceScoreIT/testScriptScore

**Reproduction line:**
```
./gradlew ':server:internalClusterTest' --tests "org.elasticsearch.search.aggregations.bucket.SignificantTermsSignificanceScoreIT.testScriptScore" -Dtests.seed=3AF8B75C5D0AD4EA -Dtests.locale=es-PR -Dtests.timezone=EAT -Druntime.java=20
```

**Applicable branches:**
main

**Reproduces locally?:**
Yes

**Failure history:**
https://gradle-enterprise.elastic.co/scans/tests?tests.container=org.elasticsearch.search.aggregations.bucket.SignificantTermsSignificanceScoreIT&tests.test=testScriptScore

**Failure excerpt:**
```
java.lang.Exception: Test abandoned because suite timeout was reached.

  at __randomizedtesting.SeedInfo.seed([3AF8B75C5D0AD4EA]:0)

```
server/src/internalClusterTest/java/org/elasticsearch/search/aggregations/bucket/SignificantTermsSignificanceScoreIT.java
.subAggregation(subAgg);
        SearchResponse response = client().prepareSearch("test").setQuery(query).addAggregation(agg).get();
        assertSearchResponse(response);
        SignificantTerms sigTerms = response.getAggregations().get("significant_terms");
        assertThat(sigTerms.getBuckets().size(), equalTo(2));
        for (SignificantTerms.Bucket bucket : sigTerms) {
            StringTerms terms = bucket.getAggregations().get("class");
            assertThat(terms.getBuckets().size(), equalTo(2));
        }
    }
    private void indexEqualTestData() throws ExecutionException, InterruptedException {
        assertAcked(
            prepareCreate("test").setSettings(indexSettings(1, 0)).setMapping("text", "type=text,fielddata=true", "class", "type=keyword")
        );
        createIndex("idx_unmapped");
        ensureGreen();
        String data[] = {
            "A\ta",
            "A\ta",
            "A\tb",
            "A\tb",
            "A\tb",
            "B\tc",
            "B\tc",
            "B\tc",
            "B\tc",
            "B\td",
            "B\td",
            "B\td",
            "B\td",