Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
wendelin.core
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
Joshua
wendelin.core
Commits
61b173c9
Commit
61b173c9
authored
May 03, 2019
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
bc0ea4bf
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
wcfs/wcfs_test.py
wcfs/wcfs_test.py
+4
-5
No files found.
wcfs/wcfs_test.py
View file @
61b173c9
...
@@ -35,8 +35,7 @@ from persistent.timestamp import TimeStamp
...
@@ -35,8 +35,7 @@ from persistent.timestamp import TimeStamp
import
os
,
os
.
path
,
subprocess
,
threading
import
os
,
os
.
path
,
subprocess
,
threading
from
errno
import
EINVAL
from
errno
import
EINVAL
from
golang
import
go
,
chan
,
func
,
defer
,
select
from
golang
import
go
,
chan
,
func
,
defer
,
select
from
golang
import
context
from
golang
import
context
,
sync
from
golang.x.sync
import
errgroup
from
zodbtools.util
import
ashex
as
h
,
fromhex
from
zodbtools.util
import
ashex
as
h
,
fromhex
from
pytest
import
raises
from
pytest
import
raises
from
.internal
import
mm
from
.internal
import
mm
...
@@ -651,15 +650,15 @@ def test_wcfs():
...
@@ -651,15 +650,15 @@ def test_wcfs():
w
=
t
.
openwatch
()
w
=
t
.
openwatch
()
ctx
=
context
.
background
()
# XXX stub
ctx
=
context
.
background
()
# XXX stub
wg
,
ctx
=
errgroup
.
with_context
(
ctx
)
wg
=
sync
.
WorkGroup
(
ctx
)
def
_
():
def
_
(
ctx
):
pinv
=
w
.
expectPin
(
ctx
,
[(
zf
,
2
,
at1
),
(
zf
,
3
,
at0
)])
pinv
=
w
.
expectPin
(
ctx
,
[(
zf
,
2
,
at1
),
(
zf
,
3
,
at0
)])
#pinv = w.expectPin(ctx, {zf: [(2, at1), (3, at0)]}) XXX <- this way better? (sugar)
#pinv = w.expectPin(ctx, {zf: [(2, at1), (3, at0)]}) XXX <- this way better? (sugar)
for
p
in
pinv
:
for
p
in
pinv
:
p
.
reply
(
b"ack"
)
p
.
reply
(
b"ack"
)
wg
.
go
(
_
)
wg
.
go
(
_
)
def
_
():
def
_
(
ctx
):
assert
w
.
sendReq
(
ctx
,
b"watch %s @%s"
%
(
h
(
zf
.
_p_oid
),
h
(
at1
)))
==
"ok"
assert
w
.
sendReq
(
ctx
,
b"watch %s @%s"
%
(
h
(
zf
.
_p_oid
),
h
(
at1
)))
==
"ok"
wg
.
go
(
_
)
wg
.
go
(
_
)
wg
.
wait
()
wg
.
wait
()
...
...
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