From d6500bb18359e9f7675d499aeebb86fddb6bccc9 Mon Sep 17 00:00:00 2001 From: Johan Date: Mon, 12 Jul 2021 16:19:36 +0700 Subject: [PATCH] fix bug where the path class attribute was not output correctly --- resources/views/components/fa-icon.blade.php | 2 +- tests/ComponentsTest.php | 13 +++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/resources/views/components/fa-icon.blade.php b/resources/views/components/fa-icon.blade.php index 9f7274e..6af53fa 100644 --- a/resources/views/components/fa-icon.blade.php +++ b/resources/views/components/fa-icon.blade.php @@ -11,6 +11,6 @@ @endif @foreach ($paths as $path) - + @endforeach diff --git a/tests/ComponentsTest.php b/tests/ComponentsTest.php index ff5d773..0d422fe 100644 --- a/tests/ComponentsTest.php +++ b/tests/ComponentsTest.php @@ -108,6 +108,19 @@ public function duotone_360_degrees_can_be_rendered() : void $this->assertIsString($this->renderComponent($component)); } + /** @test */ + public function duotone_user_crown_have_the_correct_classnames() : void + { + $component = $this->app->make(FaDuotone::class, [ + 'name' => 'user-crown', + ]); + + $output = $this->renderComponent($component); + + $this->assertStringContainsString('class="fa-primary"', $output); + $this->assertStringContainsString('class="fa-secondary"', $output); + } + /** * @test * @dataProvider components