-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Issue36 - Eureka integration #46
base: master
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -53,7 +53,14 @@ func TestMain(m *testing.M) { | |
func TestEurekaClientNoEureka(t *testing.T) { | ||
_, err := NewEurekaClient("http://localhost:9999/thisshouldntwork") | ||
if err != errNoEurekaConnection { | ||
t.Fatal("We shouldnt reach eureka if Eureka hostname/port is completely wrong") | ||
t.Fatal("We shouldnt reach eureka if Eureka hostname/port is completely wrong. Actual err:", err) | ||
} | ||
} | ||
|
||
func TestEurekaClientEurekaDoesNotReply(t *testing.T) { | ||
_, err := NewEurekaClient("http://192.0.2.1:9999/thisshouldtimeout") | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. "Addresses starting with "192.0.2.", "198.51.100.", or "203.0.113." are reserved for use in documentation and sample configurations. They should never be used in a live network configuration. No one has permission to use these addresses on the Internet." There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you suggest another IP range which traffic will be dropped for sure? In fact, these networks are referenced as "TEST NETWORKs" in the RFC, so that was the best option I found... There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. you were right, don't change it. |
||
if err != errEurekaTimesOut { | ||
t.Fatal("Pointing to a destination that drops packages should fail because of timeout. Actual err:", err) | ||
} | ||
} | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guessed you will return the string array with the IPs here instead of nil...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
WIP, WIP, WIP... ;)