Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
project
drupal
Commits
027c1e97
Commit
027c1e97
authored
Jun 10, 2009
by
Dries
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Patch
#484610
by Damien Tournoud: do not start an output buffer when running in CLI mode.
parent
a13bad58
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
4 deletions
+8
-4
scripts/run-tests.sh
scripts/run-tests.sh
+8
-4
No files found.
scripts/run-tests.sh
View file @
027c1e97
...
...
@@ -12,16 +12,20 @@
// Set defaults and get overrides.
list
(
$args
,
$count
)
=
simpletest_script_parse_args
()
;
simpletest_script_init
()
;
if
(
$args
[
'help'
]
||
$count
==
0
)
{
simpletest_script_help
()
;
exit
;
}
if
(
$args
[
'execute-batch'
])
{
// Masquerade as Apache
for
running tests.
simpletest_script_init
(
"Apache"
)
;
simpletest_script_execute_batch
()
;
}
else
{
// Run administrative functions as CLI.
simpletest_script_init
(
"PHP CLI"
)
;
}
// Bootstrap to perform initial validation or other operations.
drupal_bootstrap
(
DRUPAL_BOOTSTRAP_FULL
)
;
...
...
@@ -226,7 +230,7 @@ function simpletest_script_parse_args() {
/
**
*
Initialize script variables and perform general setup requirements.
*
/
function
simpletest_script_init
()
{
function
simpletest_script_init
(
$server_software
)
{
global
$args
,
$php
;
$host
=
'localhost'
;
...
...
@@ -260,7 +264,7 @@ function simpletest_script_init() {
$_SERVER
[
'HTTP_HOST'
]
=
$host
;
$_SERVER
[
'REMOTE_ADDR'
]
=
'127.0.0.1'
;
$_SERVER
[
'SERVER_ADDR'
]
=
'127.0.0.1'
;
$_SERVER
[
'SERVER_SOFTWARE'
]
=
'Apache'
;
$_SERVER
[
'SERVER_SOFTWARE'
]
=
$server_software
;
$_SERVER
[
'SERVER_NAME'
]
=
'localhost'
;
$_SERVER
[
'REQUEST_URI'
]
=
$path
.
'/'
;
$_SERVER
[
'REQUEST_METHOD'
]
=
'GET'
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment