Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
actor-incubator
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
actor-incubator
Commits
74d9a674
Commit
74d9a674
authored
Jan 21, 2020
by
Jakob Otto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix test routine
parent
f82ccd00
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
7 deletions
+4
-7
libcaf_net/test/multiplexer.cpp
libcaf_net/test/multiplexer.cpp
+4
-7
No files found.
libcaf_net/test/multiplexer.cpp
View file @
74d9a674
...
...
@@ -175,22 +175,19 @@ CAF_TEST(send and receive) {
CAF_TEST
(
shutdown
)
{
auto
run_mpx
=
[
=
]
{
using
namespace
std
::
chrono
;
using
namespace
std
::
this_thread
;
mpx
->
set_thread_id
();
int
count
=
0
;
do
{
mpx
->
poll_once
(
false
);
}
while
(
++
count
<
10
&&
mpx
->
num_socket_managers
()
!=
0
);
mpx
->
run
();
};
CAF_REQUIRE_EQUAL
(
mpx
->
init
(),
none
);
std
::
thread
mpx_thread
{
run_mpx
};
auto
sockets
=
unbox
(
make_stream_socket_pair
());
auto
alice
=
make_counted
<
dummy_manager
>
(
manager_count
,
sockets
.
first
,
mpx
);
auto
bob
=
make_counted
<
dummy_manager
>
(
manager_count
,
sockets
.
second
,
mpx
);
alice
->
register_reading
();
bob
->
register_reading
();
while
(
mpx
->
num_socket_managers
()
!=
3
)
;
// nop
CAF_REQUIRE_EQUAL
(
mpx
->
num_socket_managers
(),
3u
);
std
::
thread
mpx_thread
{
run_mpx
};
mpx
->
shutdown
();
mpx_thread
.
join
();
CAF_REQUIRE_EQUAL
(
mpx
->
num_socket_managers
(),
0u
);
...
...
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