Skip to content

Commit

Permalink
fix: window acknowledgement size
Browse files Browse the repository at this point in the history
  • Loading branch information
josephnhtam committed Sep 22, 2024
1 parent 3be541c commit 6d38273
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public void WindowAcknowledgementSize(IRtmpClientContext clientContext, uint ack
dataBuffer.WriteUInt32BigEndian(acknowledgementWindowSize);
});

clientContext.OutWindowAcknowledgementSize = acknowledgementWindowSize;
clientContext.InWindowAcknowledgementSize = acknowledgementWindowSize;
}

public void SetClientBandwidth(IRtmpClientContext clientContext, uint clientBandwidth, RtmpClientBandwidthLimitType limitType)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ namespace LiveStreamingServerNet.Rtmp.Test.RtmpEventHandlers.ProtocolControls
public class RtmpWindowAcknowledgementSizeHandlerTest
{
[Fact]
public async Task HandleAsync_Should_SetInWindowAcknowledgementSize()
public async Task HandleAsync_Should_SetOutWindowAcknowledgementSize()
{
// Arrange
var fixture = new Fixture();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ public void Acknowledgement_Should_SendAcknowledgementMessage()
}

[Fact]
public void WindowAcknowledgementSize_Should_SendWindowAcknowledgementSizeMessageAndSetOutWindowAcknowledgementSize()
public void WindowAcknowledgementSize_Should_SendWindowAcknowledgementSizeMessageAndSetInWindowAcknowledgementSize()
{
// Arrange
var size = _fixture.Create<uint>();
Expand Down Expand Up @@ -171,7 +171,7 @@ public void WindowAcknowledgementSize_Should_SendWindowAcknowledgementSizeMessag
_payloadBuffer.UnderlyingBuffer.Take(_payloadBuffer.Size)
.Should().BeEquivalentTo(expectedBuffer.UnderlyingBuffer.Take(expectedBuffer.Size));

_clientContext.Received(1).OutWindowAcknowledgementSize = size;
_clientContext.Received(1).InWindowAcknowledgementSize = size;
}

[Fact]
Expand Down

0 comments on commit 6d38273

Please sign in to comment.