Skip to content

Commit

Permalink
Remove MonitoringWithWatcherRestIT.testThatLocalExporterAddsWatches
Browse files Browse the repository at this point in the history
We remove this test because it is flaky and the feature tested here is already tested by monitoring.
  • Loading branch information
gmarouli authored Feb 2, 2023
1 parent 8d44c9a commit ff60564
Showing 1 changed file with 0 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,28 +44,6 @@ public void cleanExporters() throws Exception {
deleteAllWatcherData();
}

@AwaitsFix(bugUrl = "https://github.com/elastic/elasticsearch/issues/59132")
public void testThatLocalExporterAddsWatches() throws Exception {
String watchId = createMonitoringWatch();

Request request = new Request("PUT", "/_cluster/settings");
request.setJsonEntity(
Strings.toString(
jsonBuilder().startObject()
.startObject("persistent")
.field("xpack.monitoring.exporters.my_local_exporter.type", "local")
.field("xpack.monitoring.exporters.my_local_exporter.cluster_alerts.management.enabled", true)
.endObject()
.endObject()
)
);
adminClient().performRequest(request);

assertTotalWatchCount(WATCH_IDS.length);

assertMonitoringWatchHasBeenOverWritten(watchId);
}

private void assertMonitoringWatchHasBeenOverWritten(String watchId) throws Exception {
assertBusy(() -> {
ObjectPath path = ObjectPath.createFromResponse(client().performRequest(new Request("GET", "/_watcher/watch/" + watchId)));
Expand Down

0 comments on commit ff60564

Please sign in to comment.