Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions src/platform/tests/Bridge/HuggingFace/ModelClientTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ public function testGetUrlForDifferentInputsAndTasks(?string $task, string $expe
{
$reflection = new \ReflectionClass(ModelClient::class);
$getUrlMethod = $reflection->getMethod('getUrl');
$getUrlMethod->setAccessible(true);

$model = new Model('test-model');
$httpClient = new MockHttpClient();
Expand Down Expand Up @@ -87,7 +86,6 @@ public function testGetPayloadForDifferentInputsAndTasks(object|array|string $in

$reflection = new \ReflectionClass(ModelClient::class);
$getPayloadMethod = $reflection->getMethod('getPayload');
$getPayloadMethod->setAccessible(true);

$httpClient = new MockHttpClient();
$modelClient = new ModelClient($httpClient, 'test-provider', 'test-api-key');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,6 @@ public function testItUsesEventSourceHttpClient()
$client = new ModelClient($httpClient, 'http://localhost:1234');

$reflection = new \ReflectionProperty($client, 'httpClient');
$reflection->setAccessible(true);

$this->assertInstanceOf(EventSourceHttpClient::class, $reflection->getValue($client));
}
Expand All @@ -103,7 +102,6 @@ public function testItKeepsExistingEventSourceHttpClient()
$client = new ModelClient($eventSourceHttpClient, 'http://localhost:1234');

$reflection = new \ReflectionProperty($client, 'httpClient');
$reflection->setAccessible(true);

$this->assertSame($eventSourceHttpClient, $reflection->getValue($client));
}
Expand Down