Skip to content

Commit fe6269c

Browse files
authored
Adjust delete alias test to specify the index (#5737)
1 parent 334e52c commit fe6269c

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

tests/Tests/Indices/AliasManagement/DeleteAlias/AliasDeleteApiTests.cs

+5-7
Original file line numberDiff line numberDiff line change
@@ -21,22 +21,20 @@ public DeleteAliasApiTests(WritableCluster cluster, EndpointUsage usage) : base(
2121

2222
protected override Func<DeleteAliasDescriptor, IDeleteAliasRequest> Fluent => null;
2323
protected override HttpMethod HttpMethod => HttpMethod.DELETE;
24-
protected override DeleteAliasRequest Initializer => new DeleteAliasRequest(Infer.AllIndices, Names);
24+
protected override DeleteAliasRequest Initializer => new(CallIsolatedValue, Names);
2525
protected override bool SupportsDeserialization => false;
26-
protected override string UrlPath => $"/_all/_alias/{CallIsolatedValue + "-alias"}";
26+
protected override string UrlPath => $"/{CallIsolatedValue}/_alias/{CallIsolatedValue + "-alias"}";
2727
private Names Names => Infer.Names(CallIsolatedValue + "-alias");
2828

2929
protected override void IntegrationSetup(IElasticClient client, CallUniqueValues values)
3030
{
3131
foreach (var index in values.Values)
32-
client.Indices.Create(index, c => c
33-
.Aliases(aa => aa.Alias(index + "-alias"))
34-
);
32+
client.Indices.Create(index, c => c.Aliases(aa => aa.Alias(index + "-alias")));
3533
}
3634

3735
protected override LazyResponses ClientUsage() => Calls(
38-
(client, f) => client.Indices.DeleteAlias(Infer.AllIndices, Names),
39-
(client, f) => client.Indices.DeleteAliasAsync(Infer.AllIndices, Names),
36+
(client, f) => client.Indices.DeleteAlias(CallIsolatedValue, Names),
37+
(client, f) => client.Indices.DeleteAliasAsync(CallIsolatedValue, Names),
4038
(client, r) => client.Indices.DeleteAlias(r),
4139
(client, r) => client.Indices.DeleteAliasAsync(r)
4240
);

0 commit comments

Comments
 (0)