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
fixes the line ending error on windows test
  • Loading branch information
AhmedAlaa4611 committed Jan 17, 2025
commit bc8c51c50bda98106544b6e7ed6834822749c575
5 changes: 4 additions & 1 deletion tests/Http/HttpClientTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -838,7 +838,10 @@ public function testSequenceBuilder()
$this->assertSame(200, $response->status());

$response = $this->factory->get('https://example.com');
$this->assertSame("This is a story about something that happened long ago when your grandfather was a child.\n", $response->body());
$this->assertSame(
"This is a story about something that happened long ago when your grandfather was a child.\n",
str_replace("\r\n", "\n", $response->body())
);
$this->assertSame(200, $response->status());

$response = $this->factory->get('https://example.com');
Expand Down
8 changes: 4 additions & 4 deletions tests/View/Blade/BladeComponentsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ public function testComponentsAreCompiled()

public function testClassComponentsAreCompiled()
{
$this->assertSame('<?php if (isset($component)) { $__componentOriginal2dda3d2f2f9b76bd400bf03f0b84e87f = $component; } ?>
$this->assertSame(str_replace("\r\n", "\n", '<?php if (isset($component)) { $__componentOriginal2dda3d2f2f9b76bd400bf03f0b84e87f = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginal2dda3d2f2f9b76bd400bf03f0b84e87f = $attributes; } ?>
<?php $component = Illuminate\Tests\View\Blade\ComponentStub::class::resolve(["foo" => "bar"] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName(\'test\'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>', $this->compiler->compileString('@component(\'Illuminate\Tests\View\Blade\ComponentStub::class\', \'test\', ["foo" => "bar"])'));
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>'), $this->compiler->compileString('@component(\'Illuminate\Tests\View\Blade\ComponentStub::class\', \'test\', ["foo" => "bar"])'));
}

public function testEndComponentsAreCompiled()
Expand All @@ -35,7 +35,7 @@ public function testEndComponentClassesAreCompiled()
{
$this->compiler->newComponentHash('foo');

$this->assertSame('<?php echo $__env->renderComponent(); ?>
$this->assertSame(str_replace("\r\n", "\n", '<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginal79aef92e83454121ab6e5f64077e7d8a)): ?>
<?php $attributes = $__attributesOriginal79aef92e83454121ab6e5f64077e7d8a; ?>
Expand All @@ -44,7 +44,7 @@ public function testEndComponentClassesAreCompiled()
<?php if (isset($__componentOriginal79aef92e83454121ab6e5f64077e7d8a)): ?>
<?php $component = $__componentOriginal79aef92e83454121ab6e5f64077e7d8a; ?>
<?php unset($__componentOriginal79aef92e83454121ab6e5f64077e7d8a); ?>
<?php endif; ?>', $this->compiler->compileString('@endcomponentClass'));
<?php endif; ?>'), $this->compiler->compileString('@endcomponentClass'));
}

public function testSlotsAreCompiled()
Expand Down
Loading