Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
spring-boot-admin
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
openSource
spring-boot-admin
Commits
d8ea3ae4
Commit
d8ea3ae4
authored
Mar 09, 2018
by
Johannes Edmeier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix unstable tests
parent
403b3258
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
AdminServerNotifierAutoConfigurationTest.java
...rver/config/AdminServerNotifierAutoConfigurationTest.java
+3
-3
No files found.
spring-boot-admin-server/src/test/java/de/codecentric/boot/admin/server/config/AdminServerNotifierAutoConfigurationTest.java
View file @
d8ea3ae4
...
@@ -63,7 +63,7 @@ public class AdminServerNotifierAutoConfigurationTest {
...
@@ -63,7 +63,7 @@ public class AdminServerNotifierAutoConfigurationTest {
}
}
@Test
@Test
public
void
test_notifierListener
()
{
public
void
test_notifierListener
()
throws
InterruptedException
{
load
(
TestSingleNotifierConfig
.
class
);
load
(
TestSingleNotifierConfig
.
class
);
InstanceEventStore
store
=
context
.
getBean
(
InstanceEventStore
.
class
);
InstanceEventStore
store
=
context
.
getBean
(
InstanceEventStore
.
class
);
...
@@ -71,9 +71,10 @@ public class AdminServerNotifierAutoConfigurationTest {
...
@@ -71,9 +71,10 @@ public class AdminServerNotifierAutoConfigurationTest {
.
expectSubscription
()
.
expectSubscription
()
.
then
(()
->
StepVerifier
.
create
(
store
.
append
(
Collections
.
singletonList
(
APP_DOWN
))).
verifyComplete
())
.
then
(()
->
StepVerifier
.
create
(
store
.
append
(
Collections
.
singletonList
(
APP_DOWN
))).
verifyComplete
())
.
expectNext
(
APP_DOWN
)
.
expectNext
(
APP_DOWN
)
.
then
(()
->
assertThat
(
context
.
getBean
(
TestNotifier
.
class
).
getEvents
()).
containsOnly
(
APP_DOWN
))
.
thenCancel
()
.
thenCancel
()
.
verify
();
.
verify
();
Thread
.
sleep
(
50
);
//wait for the notifications in different thread
assertThat
(
context
.
getBean
(
TestNotifier
.
class
).
getEvents
()).
containsOnly
(
APP_DOWN
);
}
}
@Test
@Test
...
@@ -163,7 +164,6 @@ public class AdminServerNotifierAutoConfigurationTest {
...
@@ -163,7 +164,6 @@ public class AdminServerNotifierAutoConfigurationTest {
public
Notifier
testNotifier
()
{
public
Notifier
testNotifier
()
{
return
new
TestNotifier
();
return
new
TestNotifier
();
}
}
}
}
private
static
class
MailSenderConfig
{
private
static
class
MailSenderConfig
{
...
...
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