chore: use Run function (part 3) by mdelapenya · Pull Request #3307 · testcontainers/testcontainers-go

14-14: LGTM! Import for numeric conversions in tests.

The strconv import is appropriately added for the new test naming pattern using strconv.FormatBool.


38-38: LGTM! Consistent constant naming.

The addition of alpineImage constant follows the existing naming pattern and provides consistency across tests.


64-77: LGTM! Clean migration with configuration modifiers.

The test properly demonstrates using WithHostConfigModifier for network mode configuration alongside file mounting and wait strategies.


91-97: LGTM! Simplified container configuration.

Clean migration showing how WithHostConfigModifier can be used for privilege configuration.


124-135: LGTM! Host network configuration properly migrated.

The test maintains the same functionality while using the new Run pattern with functional options.


155-159: LGTM! Simple container creation migrated.

Clean and concise migration to the Run function.


178-184: LGTM! Log consumer configuration migrated.

Proper use of WithLogConsumerConfig in the new pattern.


207-207: Consistent test naming improvement.

Good update to use more descriptive test names with the "after-termination" prefix.


256-256: LGTM! Clear test case naming.

The updated test names "not-built-from-Dockerfile" and "built-from-Dockerfile" are more descriptive.

Also applies to: 273-273


279-286: LGTM! FromDockerfile pattern properly migrated.

Clean migration showing how to build containers from Dockerfiles using the new API.


513-524: LGTM! Build args pattern properly demonstrated.

Clean migration showing how to pass build arguments when building from Dockerfile.


647-652: LGTM! Command override pattern migrated.

Proper use of WithCmd to override container command.


666-671: LGTM! Entrypoint override pattern migrated.

Proper use of WithEntrypoint to override container entrypoint.


685-693: LGTM! Config modifier for working directory.

Clean demonstration of using WithConfigModifier to set the working directory.


976-991: LGTM! Improved test case naming and structure.

The reorganized test cases with descriptive names and proper error handling patterns are well structured.


997-997: Good use of descriptive test names.

The test names "non-existent-platform" and "valid-platform" clearly indicate what's being tested.

Also applies to: 1007-1007


1080-1085: LGTM! Consistent test naming pattern.

The updated test names use consistent hyphen-separated format improving readability.


1138-1157: LGTM! Clear test case structure.

Well-structured test cases with descriptive names and proper file mode handling.


1206-1241: LGTM! Comprehensive directory copy test cases.

Well-organized test cases covering various scenarios with clear naming.


1271-1277: LGTM! Consistent test naming.

The test names follow the established pattern with clear descriptions.


1375-1383: LGTM! Resource configuration properly migrated.

Clean use of WithHostConfigModifier for setting resource limits.


1408-1414: LGTM! Capability configuration migrated.

Proper use of WithHostConfigModifier for adding capabilities.


1431-1441: LGTM! Complex wait strategy properly migrated.

Good example of using multiple wait strategies with status code matching.


1450-1456: LGTM! User configuration properly migrated.

Clean use of WithConfigModifier to set container user.


1511-1515: LGTM! Network mode configuration migrated.

Proper use of WithHostConfigModifier for container network mode.


1607-1607: LGTM! Use of strconv for test naming.

Good use of strconv.FormatBool for generating test names from boolean values.


1615-1621: LGTM! KeepImage option properly demonstrated.

Clean migration showing how to control image retention after container termination.


1750-1752: LGTM! Improved assertions.

Good use of require.Positive for clearer test assertions.


1801-1803: LGTM! Consistent assertion improvements.

Consistent use of improved assertions throughout the retry tests.


1862-1864: LGTM! Consistent assertion pattern.

Maintains consistent assertion style across all retry test cases.