Skip to content

Commit 683c74c

Browse files
Fix date format use in SearchApiDocValueFieldsTests (#4934) (#4944)
Relates: elastic/elasticsearch#60044 This commit updates the SearchApiDocValueFieldsTests to use a different date format. Fixes #4920 Co-authored-by: Russ Cam <russ.cam@elastic.co>
1 parent 6f4b4b9 commit 683c74c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/Tests/Search/Search/SearchApiTests.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ public SearchApiDocValueFieldsTests(ReadOnlyCluster cluster, EndpointUsage usage
285285
new
286286
{
287287
field = "lastActivity",
288-
format = "weekyear"
288+
format = DateFormat.basic_date
289289
},
290290
}
291291
};
@@ -306,7 +306,7 @@ public SearchApiDocValueFieldsTests(ReadOnlyCluster cluster, EndpointUsage usage
306306
)
307307
.DocValueFields(fs => fs
308308
.Field(p => p.Name)
309-
.Field(p => p.LastActivity, format: "weekyear")
309+
.Field(p => p.LastActivity, format: DateFormat.basic_date)
310310
);
311311

312312
protected override SearchRequest<Project> Initializer => new SearchRequest<Project>()
@@ -324,7 +324,7 @@ public SearchApiDocValueFieldsTests(ReadOnlyCluster cluster, EndpointUsage usage
324324
Value = "Stable"
325325
}),
326326
DocValueFields = Infer.Field<Project>(p => p.Name)
327-
.And<Project>(p => p.LastActivity, format: "weekyear")
327+
.And<Project>(p => p.LastActivity, format: DateFormat.basic_date)
328328
};
329329

330330
protected override void ExpectResponse(ISearchResponse<Project> response)

0 commit comments

Comments
 (0)