snipe-it/tests/Unit/BladeComponents/IconComponentTest.php

21 lines
576 B
PHP
Raw Normal View History

Squashed commit of the following: commit 147fcfb8ebc4ceeea96d803d6a455abeba54f45a Merge: 58a3d09b5 fdcc17ca2 Author: snipe <snipe@snipe.net> Date: Tue Oct 22 15:12:55 2024 +0100 Merge pull request #15676 from Toreg87/fixes/api_create_user_fmcs Fix user creation with FullMultipleCompanySupport enabled over API commit 58a3d09b5fd7ffa979bfb9553cacbb24ae452462 Merge: 30a06a594 867fa2f36 Author: snipe <snipe@snipe.net> Date: Tue Oct 22 14:55:42 2024 +0100 Merge pull request #15703 from marcusmoore/bug/sc-27188 Linked accessory files in activity report commit 30a06a594289571097e2d30901546bc9a17b4bac Merge: 6c6af78e0 ce3086317 Author: snipe <snipe@snipe.net> Date: Tue Oct 22 11:47:06 2024 +0100 Merge pull request #15693 from marcusmoore/chore/remove-parallel-testing Removed brianium/paratest commit 6c6af78e0840fc4f134e5bbb7965f21f4adcc0e1 Merge: 9b06bbb6c 3f79fd7ea Author: snipe <snipe@snipe.net> Date: Tue Oct 22 11:46:04 2024 +0100 Merge pull request #15705 from marcusmoore/tests/icon-component-test Added test to ensure icon component does not end in newline commit 3f79fd7ea744bd18134785c37b87a2f4bcff0347 Author: Marcus Moore <contact@marcusmoore.io> Date: Mon Oct 21 17:07:40 2024 -0700 Add test to ensure icon component does not end in newline commit 9b06bbb6c37fcea9b6202ad9fb2b4d952210dd01 Merge: 46ad1d072 d7f70146f Author: snipe <snipe@snipe.net> Date: Mon Oct 21 22:38:26 2024 +0100 Merge pull request #15704 from marcusmoore/bug/remove-extra-icon Removed second icon in accessory file list commit ce30863177e499a29f395c9c88ce9c67bd669a74 Author: Marcus Moore <contact@marcusmoore.io> Date: Mon Oct 21 13:57:04 2024 -0700 Remove brianium/paratest dependency commit d7f70146f4a886795ddb118cc2f71bbadded72dc Author: Marcus Moore <contact@marcusmoore.io> Date: Mon Oct 21 13:48:25 2024 -0700 Remove extra icon in accessory file upload list commit 867fa2f36e02bdfe0ee74ae98b590fd013f6fc7a Author: Marcus Moore <contact@marcusmoore.io> Date: Mon Oct 21 12:40:24 2024 -0700 Display file in activity report for accessories commit 0933a2d4ea6d5babd6ef3e0e2f8350c2e088648d Author: Marcus Moore <contact@marcusmoore.io> Date: Thu Oct 17 18:01:48 2024 -0700 Remove --parallel flag commit 46ad1d072f5c45d20c1b078d2b3f84a3a0f36632 Merge: bcb4bd9eb 3cf746d7d Author: snipe <snipe@snipe.net> Date: Thu Oct 17 15:29:47 2024 +0100 Merge pull request #15680 from uberbrady/bulk_checkout_to_bulk_actions Bulk checkout to bulk actions commit bcb4bd9eb4e419e8a125a7dccd3e79c39dc13e21 Merge: 250037540 f50ccbcc4 Author: snipe <snipe@snipe.net> Date: Thu Oct 17 10:20:13 2024 +0100 Merge pull request #15683 from Toreg87/fixes/outdated_comment Fix outdated comment in CompanyableTrait commit f50ccbcc492db6c98cabf6dc6752dd99ab82bce7 Author: Tobias Regnery <tobias.regnery@gmail.com> Date: Thu Oct 17 11:07:28 2024 +0200 Fix outdated comment in CompanyableTrait As of commit 5800e8d the user model uses CompanyableTrait so remove this clearly outdated comment commit 3cf746d7df83ef3e7cfa45c602fc182ebe8f11e3 Author: Brady Wetherington <bwetherington@grokability.com> Date: Wed Oct 16 23:13:32 2024 +0100 Rework the bulk checkout to not change how all checkouts work commit 6b7af802af41c92a36e77605415869c9e72ec192 Author: Brady Wetherington <bwetherington@grokability.com> Date: Thu Oct 10 13:28:23 2024 +0100 Add 'bulk checkout' as one of the bulk actions in the bulk actions toolbar commit fdcc17ca2c33d38a7af505c99d9547e014f5f783 Author: Tobias Regnery <tobias.regnery@gmail.com> Date: Wed Oct 16 11:18:24 2024 +0200 Fix user creation with FullMultipleCompanySupport enabled over API It is currently possible as a non-superuser to create a new user or patch an existing user with arbitrary company over the API if FullMultipleCompanySupport is enabled. Altough a highly unlikely scenario as the user needs permission to create API keys and new users, it is a bug that should get fixed. Add a call to getIdForCurrentUser() to normalize the company_id if FullMultipleCompanySupport is enabled. Signed-off-by: snipe <snipe@snipe.net>
2024-10-22 07:43:19 -07:00
<?php
namespace Tests\Unit\BladeComponents;
use Illuminate\Support\Facades\View;
use Illuminate\Support\Str;
use Tests\TestCase;
class IconComponentTest extends TestCase
{
public function testIconComponentDoesNotEndInNewline()
{
$renderedTemplateString = View::make('blade.icon', ['type' => 'checkout'])->render();
$this->assertFalse(
Str::endsWith($renderedTemplateString, PHP_EOL),
'Newline found at end of icon component. Bootstrap tables will not render if there is a newline at the end of the file.'
);
}
}