Skip to content
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

net: test fails when there's no network #7431

Closed
randall77 opened this issue Feb 27, 2014 · 5 comments
Closed

net: test fails when there's no network #7431

randall77 opened this issue Feb 27, 2014 · 5 comments
Labels
FrozenDueToAge Testing An issue that has been verified to require only test changes, not just a test failure.
Milestone

Comments

@randall77
Copy link
Contributor

Turn off your network (ifconfig eth0 down, whatever else makes sense).

Run all.bash.

--- FAIL: TestIPv4MulticastListener (0.01 seconds)
    multicast_test.go:55: First ListenMulticastUDP on <nil> failed: listen udp 224.0.0.254: setsockopt: no such device
FAIL
FAIL    net 2.376s

TestIPv6 also fails.

all.bash should work even without the presence of the network, even if it just skips
these tests.
@mikioh
Copy link
Contributor

mikioh commented Feb 28, 2014

Comment 1:

Sure, I'll smash all such frakiness in Go 1.4 with new helper library: net/test.
Friends: issue #4176, issue #5524, issue #5707, issue #6553, issue #6843, issue #6879

Labels changed: added release-go1.4.

Status changed to Accepted.

@robpike
Copy link
Contributor

robpike commented Feb 28, 2014

Comment 2:

Not so fast. I'm not convinced this is worth refactoring for. If there's no network, the
best we can do is skip the network tests but then what? Skip tests that need floating
point if there's no FP unit? Skip tests that use the file system if the disk is
unmounted?

@bradfitz
Copy link
Contributor

Comment 3:

all.bash normally passes on an airplane with no network access. (skipping some tests)
It occasionally breaks, and is then fixed. I think it's a good goal to have.
The actual builders have network access, so we won't regress with some skips.

@mikioh
Copy link
Contributor

mikioh commented Aug 13, 2014

Comment 4:

Labels changed: added repo-main, removed release-go1.4.

Status changed to New.

@bradfitz bradfitz removed the new label Dec 18, 2014
@rsc rsc added this to the Unplanned milestone Apr 10, 2015
@rsc rsc removed the repo-main label Apr 14, 2015
@mikioh mikioh added Testing An issue that has been verified to require only test changes, not just a test failure. LongTerm labels May 11, 2016
@mikioh
Copy link
Contributor

mikioh commented May 12, 2016

I think go1.6 and above can handle this case. Closing.

@mikioh mikioh closed this as completed May 12, 2016
@golang golang locked and limited conversation to collaborators May 12, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge Testing An issue that has been verified to require only test changes, not just a test failure.
Projects
None yet
Development

No branches or pull requests

6 participants