testcontainers/testcontainers-java

Add getMappedPort(Integer originalPort, InternetProtocol protocol)

Offen

#554 geöffnet am 23.01.2018

 (12 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)Java (1.588 Forks)batch import
good first issueresolution/acknowledgedtype/feature

Repository-Metriken

Stars
 (7.535 Sterne)
PR-Merge-Metriken
 (Durchschn. Merge 2T 17h) (2 gemergte PRs in 30 T)

Beschreibung

It will just look so much nicer in my test than

genericContainer.getContainerInfo().getNetworkSettings().getPorts().getBindings().get(new ExposedPort(originalPort, protocol))[0].getHostPortSpec()

I think it has something to do with the law of demeter.

But in all fairness root cause is https://github.com/moby/moby/issues/4635

Contributor Guide