Proyectos de Subversion Moodle

Rev

Rev 1 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 1 Rev 1441
Línea 34... Línea 34...
34
 
34
 
35
// Is not really necessary but adding it as is a CLI_SCRIPT.
35
// Is not really necessary but adding it as is a CLI_SCRIPT.
36
define('CLI_SCRIPT', true);
36
define('CLI_SCRIPT', true);
Línea -... Línea 37...
-
 
37
define('CACHE_DISABLE_ALL', true);
-
 
38
 
-
 
39
// It makes no sense to use BEHAT_CLI for this script (the Behat launch scripts expect to start
-
 
40
// from the normal environment), so in case user has set tne environment variable, disable it.
37
define('CACHE_DISABLE_ALL', true);
41
putenv('BEHAT_CLI=0');
38
 
42
 
39
// Basic functions.
43
// Basic functions.
Línea 40... Línea 44...
40
require_once(__DIR__ . '/../../../../lib/clilib.php');
44
require_once(__DIR__ . '/../../../../lib/clilib.php');
Línea 52... Línea 56...
52
        'axe'      => null,
56
        'axe'      => null,
53
        'disable-composer' => false,
57
        'disable-composer' => false,
54
        'composer-upgrade' => true,
58
        'composer-upgrade' => true,
55
        'composer-self-update' => true,
59
        'composer-self-update' => true,
56
        'scss-deprecations' => false,
60
        'scss-deprecations' => false,
-
 
61
        'no-icon-deprecations' => false,
57
    ),
62
    ),
58
    array(
63
    array(
59
        'j' => 'parallel',
64
        'j' => 'parallel',
60
        'm' => 'maxruns',
65
        'm' => 'maxruns',
61
        'h' => 'help',
66
        'h' => 'help',
Línea 68... Línea 73...
68
$help = "
73
$help = "
69
Behat utilities to initialise behat tests
74
Behat utilities to initialise behat tests
Línea 70... Línea 75...
70
 
75
 
71
Usage:
76
Usage:
72
  php init.php      [--parallel=value [--maxruns=value] [--fromrun=value --torun=value]]
77
  php init.php      [--parallel=value [--maxruns=value] [--fromrun=value --torun=value]]
-
 
78
                    [--no-axe] [--scss-deprecations] [--no-icon-deprecations] [-o | --optimize-runs]
73
                    [--no-axe] [--scss-deprecations] [-o | --optimize-runs] [-a | --add-core-features-to-theme]
79
                    [-a | --add-core-features-to-theme]
74
                    [--no-composer-self-update] [--no-composer-upgrade]
80
                    [--no-composer-self-update] [--no-composer-upgrade]
75
                    [--disable-composer]
81
                    [--disable-composer]
Línea 76... Línea 82...
76
                    [--help]
82
                    [--help]
77
 
83
 
78
Options:
84
Options:
79
-j, --parallel      Number of parallel behat run to initialise
85
-j, --parallel         Number of parallel behat run to initialise
80
-m, --maxruns       Max parallel processes to be executed at one time
86
-m, --maxruns          Max parallel processes to be executed at one time
81
--fromrun           Execute run starting from (Used for parallel runs on different vms)
87
--fromrun              Execute run starting from (Used for parallel runs on different vms)
82
--torun             Execute run till (Used for parallel runs on different vms)
88
--torun                Execute run till (Used for parallel runs on different vms)
-
 
89
--no-axe               Disable axe accessibility tests.
Línea 83... Línea 90...
83
--no-axe            Disable axe accessibility tests.
90
--scss-deprecations    Enable SCSS deprecation checks.
84
--scss-deprecations Enable SCSS deprecation checks.
91
--no-icon-deprecations Disable icon deprecation checks.
Línea 85... Línea 92...
85
 
92
 
Línea 132... Línea 139...
132
    // Only sanitize options for single run.
139
    // Only sanitize options for single run.
133
    $cmdoptionsforsinglerun = [
140
    $cmdoptionsforsinglerun = [
134
        'add-core-features-to-theme',
141
        'add-core-features-to-theme',
135
        'axe',
142
        'axe',
136
        'scss-deprecations',
143
        'scss-deprecations',
-
 
144
        'no-icon-deprecations',
137
    ];
145
    ];
Línea 138... Línea 146...
138
 
146
 
139
    foreach ($cmdoptionsforsinglerun as $option) {
147
    foreach ($cmdoptionsforsinglerun as $option) {
140
        $commandoptions .= behat_get_command_flags($option, $options[$option]);
148
        $commandoptions .= behat_get_command_flags($option, $options[$option]);