Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.buildout
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
isaak yansane-sisk
slapos.buildout
Commits
b00b0ffb
Commit
b00b0ffb
authored
Feb 08, 2007
by
Jim Fulton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added flush/fsync to the write method to try to avoid
spurious test failures. I'm not sure this is really necessary.
parent
7f564127
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletion
+8
-1
src/zc/buildout/testing.py
src/zc/buildout/testing.py
+8
-1
No files found.
src/zc/buildout/testing.py
View file @
b00b0ffb
...
...
@@ -26,6 +26,8 @@ import pkg_resources
import
zc.buildout.buildout
import
zc.buildout.easy_install
fsync
=
getattr
(
os
,
'fsync'
,
lambda
fileno
:
None
)
setuptools_location
=
pkg_resources
.
working_set
.
find
(
pkg_resources
.
Requirement
.
parse
(
'setuptools'
)).
location
...
...
@@ -57,7 +59,12 @@ def rmdir(*path):
shutil
.
rmtree
(
os
.
path
.
join
(
*
path
))
def
write
(
dir
,
*
args
):
open
(
os
.
path
.
join
(
dir
,
*
(
args
[:
-
1
])),
'w'
).
write
(
args
[
-
1
])
path
=
os
.
path
.
join
(
dir
,
*
(
args
[:
-
1
]))
f
=
open
(
path
,
'w'
)
f
.
write
(
args
[
-
1
])
f
.
flush
()
fsync
(
f
.
fileno
())
f
.
close
()
def
system
(
command
,
input
=
''
):
i
,
o
=
os
.
popen4
(
command
)
...
...
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