!C99Shell v. 2.1 [PHP 8 Update] [02.02.2022]!

Software: Apache/2.4.53 (Unix) OpenSSL/1.1.1o PHP/7.4.29 mod_perl/2.0.12 Perl/v5.34.1. PHP/7.4.29 

uname -a: Linux vps-2738122-x 4.15.0-213-generic #224-Ubuntu SMP Mon Jun 19 13:30:12 UTC 2023 x86_64 

uid=1(daemon) gid=1(daemon) grupos=1(daemon) 

Safe-mode: OFF (not secure)

/opt/apex_tdfonline/php/modelo/lib/testing_selenium/   drwxr-xr-x
Free 13.85 GB of 61.93 GB (22.36%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     toba_selenium_test_runner.php (1.95 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
require_once(toba_dir() . '/php/3ros/simpletest/runner.php');

class 
toba_selenium_test_runner extends SimpleRunner
{
    protected 
$separar_pruebas false;

    function 
separar_pruebas($estado=false)
    {
        
$this->separar_pruebas $estado;
    }
    
    function 
run()
    {
        
$methods get_class_methods(get_class($this->_test_case));
        
$invoker = &$this->_test_case->createInvoker();        
        foreach (
$methods as $method) {
            if (! 
$this->_isTest($method)) {
                continue;
            }
            if (
$this->_isConstructor($method)) {
                continue;
            }
            if (
$this->_scorer->shouldInvoke($this->_test_case->getLabel(), $method)) {
                if(
$this->separar_pruebas) {
                    
toba::logger()->debug("\n\n%%%%%%%%%%%--------- INICIO prueba: $method ---------%%%%%%%%%%%%%%%%%%%\n"'toba');
                }
                try {
                    
$rsp $invoker->invoke($method);
                    
$asrt $invoker->getTestCase()->get_assert_status();                            //Recupero si el caso, usa Assert o no internamente.
                    
if (!is_null($rsp) && is_array($rsp)  && !$asrt) {                                //En base a ello, uso o no los datos devueltos.
                        
$result = (isset($rsp['resultado'])) ? $rsp['resultado'] : false;
                        
$msg $this->parsear_extra_resultado($rsp);
                        
$invoker->getTestCase()->assertTrue($result$msg);                    
                    }
                } catch (
PHPWebDriver_WebDriverCurlException $e) {
                    
toba::logger()->debug($e->getMessage());
                    throw new 
toba_error_usuario('Inicie el servidor Selenium por favor');
                }
                if(
$this->separar_pruebas) {
                    
toba::logger()->debug("\n\n%%%%%%%%%%%--------- FIN prueba: $method ---------%%%%%%%%%%%%%%%%%%%"'toba');
                }
            }
        }
    }
    
    
/**
     * Parsea lo que devuelvan en la componente 'extra' de un arreglo y en base a eso devolvera un msg que podra ser texto, link u otra cosa.
     * @param array $datos
     * @return text
     */
    
protected function parsear_extra_resultado($datos)
    {
        
$msg '';
        if (isset(
$datos['extra'])) {
            
$msg = (is_array($datos['extra']))? var_export($datos['extra'], true) : $datos['extra'];            
        }
        return 
$msg;
    }
}
?>

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.1 [PHP 8 Update] [02.02.2022] maintained byC99Shell Github | Generation time: 0.4789 ]--