Skip to content

Commit 2620796

Browse files
committed
Adjust regex for catching both new and old size error messages
1 parent 9914525 commit 2620796

File tree

2 files changed

+22
-4
lines changed

2 files changed

+22
-4
lines changed

modules/reindex/build.gradle

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,3 @@ if (OS.current() == OS.WINDOWS) {
167167
}
168168
}
169169
}
170-
171-
tasks.named("yamlRestCompatTestTransform").configure { task ->
172-
task.skipTest("reindex/20_validation/specifying size fails", "size is rejected in 9.0")
173-
}

modules/reindex/src/yamlRestTest/resources/rest-api-spec/test/reindex/20_validation.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,28 @@
9494
body:
9595
conflicts: cat
9696

97+
---
98+
"specifying size fails":
99+
- requires:
100+
cluster_features: ["gte_v8.0.0"]
101+
reason: "size supported until 8"
102+
103+
- do:
104+
index:
105+
index: test
106+
id: "1"
107+
body: { "text": "test" }
108+
109+
- do:
110+
catch: /(invalid parameter \[size\], use \[max_docs\] instead|unknown field \[size\])/
111+
reindex:
112+
body:
113+
source:
114+
index: test
115+
dest:
116+
index: dest
117+
size: 1
118+
97119
---
98120
"invalid max_docs in body fails":
99121
- requires:

0 commit comments

Comments
 (0)