From d83740e270cb66ec2ca25779bbcd297088c55b16 Mon Sep 17 00:00:00 2001 From: Artem Medvedev Date: Fri, 14 Jun 2024 21:12:33 +0200 Subject: [PATCH] refactor!: exposed and mapped ports api - rename `ExposedPort` to `ContainerPort` (after #655) - `with_mapped_port`: accept two arguments instead of tuple - introduce `IntoContainerPort` to make a shortcut for conversion from `u16` to `ContainerPort` --- testcontainers/src/core/image/image_ext.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testcontainers/src/core/image/image_ext.rs b/testcontainers/src/core/image/image_ext.rs index 35bcae17..21b81774 100644 --- a/testcontainers/src/core/image/image_ext.rs +++ b/testcontainers/src/core/image/image_ext.rs @@ -155,7 +155,7 @@ impl>, I: Image> ImageExt for RI { ) -> ContainerRequest { let runnable = self.into(); let mut ports = runnable.ports.unwrap_or_default(); - ports.push(PortMapping::new(host_port, container_port.into())); + ports.push(PortMapping::new(host_port, container_port)); ContainerRequest { ports: Some(ports),