Skip to content

Commit 3aab6cd

Browse files
committed
CS
1 parent 339a5fd commit 3aab6cd

3 files changed

Lines changed: 6 additions & 12 deletions

File tree

tests/HttpClient/AgentClientTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public function testClientHandsOffEnvelopeToLocalAgent(): void
3232
$request->setStringBody($envelope);
3333

3434
$client = new AgentClient('127.0.0.1', $this->agentPort);
35-
$response = $client->sendRequest($request, new \Sentry\Options());
35+
$response = $client->sendRequest($request, new Options());
3636

3737
$this->waitForEnvelopeCount(1);
3838
$agentOutput = $this->stopTestAgent();
@@ -58,7 +58,7 @@ public function testClientReturnsAcceptedWhenLocalAgentIsUnavailable(): void
5858
});
5959

6060
try {
61-
$response = $client->sendRequest($request, new \Sentry\Options());
61+
$response = $client->sendRequest($request, new Options());
6262
} finally {
6363
restore_error_handler();
6464
}
@@ -70,7 +70,7 @@ public function testClientReturnsAcceptedWhenLocalAgentIsUnavailable(): void
7070
public function testClientReturnsErrorWhenBodyIsEmpty(): void
7171
{
7272
$client = new AgentClient();
73-
$response = $client->sendRequest(new Request(), new \Sentry\Options());
73+
$response = $client->sendRequest(new Request(), new Options());
7474

7575
$this->assertSame(400, $response->getStatusCode());
7676
$this->assertTrue($response->hasError());

tests/HttpClient/TestAgent.php

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -134,13 +134,7 @@ public function waitForEnvelopeCount(int $expectedCount, float $timeout = 5.0):
134134
}
135135

136136
if (microtime(true) - $startTime > $timeout) {
137-
throw new \RuntimeException(
138-
\sprintf(
139-
'Timeout waiting for %d envelope(s), got %d.',
140-
$expectedCount,
141-
\count($output['messages'])
142-
)
143-
);
137+
throw new \RuntimeException(\sprintf('Timeout waiting for %d envelope(s), got %d.', $expectedCount, \count($output['messages'])));
144138
}
145139

146140
usleep(10000);

tests/HttpClient/agent-server.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555

5656
$buffer .= $chunk;
5757

58-
while (\strlen($buffer) >= 4) {
58+
while (strlen($buffer) >= 4) {
5959
if ($messageLength === 0) {
6060
$unpackedHeader = unpack('N', substr($buffer, 0, 4));
6161

@@ -66,7 +66,7 @@
6666
$messageLength = $unpackedHeader[1];
6767
}
6868

69-
if (\strlen($buffer) < $messageLength) {
69+
if (strlen($buffer) < $messageLength) {
7070
break;
7171
}
7272

0 commit comments

Comments
 (0)