Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5_fork
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Eteri
erp5_fork
Commits
1bc7ccd1
Commit
1bc7ccd1
authored
May 26, 2011
by
Nicolas Delaby
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Deal with Shebang size limitation
parent
d8be73f8
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
2 deletions
+26
-2
slapos/recipe/erp5/src/slapos/recipe/erp5/test_suite_runner.py
...s/recipe/erp5/src/slapos/recipe/erp5/test_suite_runner.py
+13
-1
slapos/recipe/erp5/src/slapos/recipe/erp5/testrunner.py
slapos/recipe/erp5/src/slapos/recipe/erp5/testrunner.py
+13
-1
No files found.
slapos/recipe/erp5/src/slapos/recipe/erp5/test_suite_runner.py
View file @
1bc7ccd1
...
...
@@ -8,4 +8,16 @@ def runTestSuite(args):
env
[
'PATH'
]
=
':'
.
join
([
d
[
'prepend_path'
]]
+
os
.
environ
[
'PATH'
].
split
(
':'
))
env
[
'INSTANCE_HOME'
]
=
d
[
'instance_home'
]
env
[
'REAL_INSTANCE_HOME'
]
=
d
[
'instance_home'
]
os
.
execve
(
d
[
'call_list'
][
0
],
d
[
'call_list'
]
+
sys
.
argv
[
1
:],
env
)
# Deal with Shebang size limitation
executable_filepath
=
d
[
'call_list'
][
0
]
file_object
=
open
(
executable_filepath
,
'r'
)
line
=
file_object
.
readline
()
file_object
.
close
()
argument_list
=
[]
if
line
[:
2
]
==
'#!'
:
executable_filepath
=
line
[
2
:].
strip
()
argument_list
.
append
(
executable_filepath
)
argument_list
.
extend
(
d
[
'call_list'
])
argument_list
.
extend
(
sys
.
argv
[
1
:])
argument_list
.
append
(
env
)
os
.
execle
(
executable_filepath
,
*
argument_list
)
slapos/recipe/erp5/src/slapos/recipe/erp5/testrunner.py
View file @
1bc7ccd1
...
...
@@ -8,4 +8,16 @@ def runUnitTest(args):
env
[
'PATH'
]
=
':'
.
join
([
d
[
'prepend_path'
]]
+
os
.
environ
[
'PATH'
].
split
(
':'
))
env
[
'INSTANCE_HOME'
]
=
d
[
'instance_home'
]
env
[
'REAL_INSTANCE_HOME'
]
=
d
[
'instance_home'
]
os
.
execve
(
d
[
'call_list'
][
0
],
d
[
'call_list'
]
+
sys
.
argv
[
1
:],
env
)
# Deal with Shebang size limitation
executable_filepath
=
d
[
'call_list'
][
0
]
file_object
=
open
(
executable_filepath
,
'r'
)
line
=
file_object
.
readline
()
file_object
.
close
()
argument_list
=
[]
if
line
[:
2
]
==
'#!'
:
executable_filepath
=
line
[
2
:].
strip
()
argument_list
.
append
(
executable_filepath
)
argument_list
.
extend
(
d
[
'call_list'
])
argument_list
.
extend
(
sys
.
argv
[
1
:])
argument_list
.
append
(
env
)
os
.
execle
(
executable_filepath
,
*
argument_list
)
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