Skip to content

Commit

Permalink
update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Mpdreamz committed Oct 31, 2024
1 parent 4210e60 commit a042c11
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public void CopiesAllDefaults()
config.Should().BeEquivalentTo(newConfig);
}

#if !NETFRAMEWORK
[Fact]
public void CopiesAllProperties()
{
Expand All @@ -33,4 +34,5 @@ public void CopiesAllProperties()

config.Should().BeEquivalentTo(newConfig);
}
#endif
}
10 changes: 5 additions & 5 deletions tests/Elastic.Transport.Tests/ResponseBuilderDisposeTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -67,18 +67,18 @@ private async Task AssertResponse<T>(bool disableDirectStreaming, int statusCode

var memoryStreamFactory = new TrackMemoryStreamFactory();

if (skipStatusCode > -1 )
if (skipStatusCode > -1)
config = InMemoryConnectionFactory.Create(productRegistration)
.DisableDirectStreaming(disableDirectStreaming)
.SkipDeserializationForStatusCodes(skipStatusCode)
.MemoryStreamFactory(memoryStreamFactory);
.SkipDeserializationForStatusCodes(skipStatusCode);
else if (productRegistration is not null)
config = InMemoryConnectionFactory.Create(productRegistration)
.DisableDirectStreaming(disableDirectStreaming)
.MemoryStreamFactory(memoryStreamFactory);
.DisableDirectStreaming(disableDirectStreaming);
else
config = disableDirectStreaming ? _settingsDisableDirectStream : _settings;

config = new TransportConfiguration(config) { MemoryStreamFactory = memoryStreamFactory };

var endpoint = new Endpoint(new EndpointPath(httpMethod, "/"), new Node(new Uri("http://localhost:9200")));
var requestData = new RequestData(config, null, customResponseBuilder);

Expand Down

0 comments on commit a042c11

Please sign in to comment.