Skip to content

Commit c3452e4

Browse files
committed
Add an additional test
1 parent 8fa8743 commit c3452e4

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

tests/MiddlewareAndComponentTest.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,24 @@ public function it_sends_a_simple_request_with_highlighted_response()
7070
);
7171
}
7272

73+
/** @test */
74+
public function it_sends_a_simple_request_with_style()
75+
{
76+
$this->fakeSuccessfulResponse('component', [
77+
'classes' => 'torchlight',
78+
'styles' => 'background-color: #292D3E;',
79+
'highlighted' => 'this is the highlighted response from the server',
80+
]);
81+
82+
$response = $this->getView('simple-php-hello-world-with-style.blade.php');
83+
84+
$this->assertEquals(
85+
'<pre><code class="torchlight" style="display: none;background-color: #292D3E;">this is the highlighted response from the server</code></pre>',
86+
$response->content()
87+
);
88+
}
89+
90+
7391
/** @test */
7492
public function classes_get_merged()
7593
{
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<pre><x-torchlight-code style='display: none;' torchlight-id='component' language='php'>
2+
echo "hello world";
3+
</x-torchlight-code></pre>

0 commit comments

Comments
 (0)