fix DateIndexNameProcessorTests offset pattern (#38069)

`XX` was being used to represent an offset pattern,
it should be `ZZ`

Fixes #38067.
This commit is contained in:
Tal Levy 2019-01-30 23:57:56 -08:00 committed by Alexander Reelsen
parent b94acb608b
commit e0d5de33da
1 changed files with 1 additions and 2 deletions

View File

@ -79,11 +79,10 @@ public class DateIndexNameProcessorTests extends ESTestCase {
assertThat(document.getSourceAndMetadata().get("_index"), equalTo("<events-{19700101||/m{yyyyMMdd|UTC}}>"));
}
@AwaitsFix(bugUrl = "https://github.com/elastic/elasticsearch/issues/38067")
public void testTemplatedFields() throws Exception {
String indexNamePrefix = randomAlphaOfLength(10);
String dateRounding = randomFrom("y", "M", "w", "d", "h", "m", "s");
String indexNameFormat = randomFrom("yyyy-MM-dd'T'HH:mm:ss.SSSXX", "yyyyMMdd", "MM/dd/yyyy");
String indexNameFormat = randomFrom("yyyy-MM-dd'T'HH:mm:ss.SSSZZ", "yyyyMMdd", "MM/dd/yyyy");
String date = Integer.toString(randomInt());
Function<String, DateTime> dateTimeFunction = DateFormat.Unix.getFunction(null, DateTimeZone.UTC, null);