Use correct port in testPublicAccess

Also reduce timeout from 20 minutes to 1.
This commit is contained in:
Andrew Gaul 2015-06-24 14:50:50 -07:00
parent e0bafd4c10
commit d57b6e7b8f
1 changed files with 3 additions and 2 deletions

View File

@ -75,8 +75,9 @@ public class BaseContainerLiveTest extends BaseBlobStoreIntegrationTest {
assertNotNull(metadata.getPublicUri(), metadata.toString());
SocketOpen socketOpen = context.utils().injector().getInstance(SocketOpen.class);
Predicate<HostAndPort> socketTester = retry(socketOpen, 1200, 10, SECONDS);
assertTrue(socketTester.apply(HostAndPort.fromParts(metadata.getPublicUri().getHost(), 80)), metadata.getPublicUri().toString());
Predicate<HostAndPort> socketTester = retry(socketOpen, 60, 5, SECONDS);
HostAndPort hostAndPort = HostAndPort.fromParts(metadata.getPublicUri().getHost(), metadata.getPublicUri().getPort());
assertTrue(socketTester.apply(hostAndPort), metadata.getPublicUri().toString());
assertEquals(Strings2.toStringAndClose(view.utils().http().get(metadata.getPublicUri())), TEST_STRING);