From c0aabadac84b2de318e9b76e435f3e6c40c67abe Mon Sep 17 00:00:00 2001 From: maumar Date: Fri, 21 Jun 2024 16:59:51 -0700 Subject: [PATCH] fixing cosmos test failures on linux --- .../Query/OwnedQueryCosmosTest.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/test/EFCore.Cosmos.FunctionalTests/Query/OwnedQueryCosmosTest.cs b/test/EFCore.Cosmos.FunctionalTests/Query/OwnedQueryCosmosTest.cs index d65433ac39b..aed107a50bc 100644 --- a/test/EFCore.Cosmos.FunctionalTests/Query/OwnedQueryCosmosTest.cs +++ b/test/EFCore.Cosmos.FunctionalTests/Query/OwnedQueryCosmosTest.cs @@ -1,6 +1,7 @@ // Licensed to the .NET Foundation under one or more agreements. // The .NET Foundation licenses this file to you under the MIT license. +using System.Net; using Microsoft.Azure.Cosmos; using Microsoft.EntityFrameworkCore.Cosmos.Internal; @@ -49,7 +50,7 @@ public override async Task Navigation_rewrite_on_owned_collection_with_compositi { var exception = await Assert.ThrowsAsync(() => base.Navigation_rewrite_on_owned_collection_with_composition(async)); - Assert.Contains("'ORDER BY' is not supported in subqueries.", exception.Message); + Assert.Equal(HttpStatusCode.BadRequest, exception.StatusCode); AssertSql( """ @@ -1089,7 +1090,7 @@ public override async Task OrderBy_ElementAt_over_owned_collection(bool async) { var exception = await Assert.ThrowsAsync(() => base.OrderBy_ElementAt_over_owned_collection(async)); - Assert.Contains("'ORDER BY' is not supported in subqueries.", exception.Message); + Assert.Equal(HttpStatusCode.BadRequest, exception.StatusCode); AssertSql( """