FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

ServerContainer adjustments by alexanderankin · Pull Request #2 · Tranquility2/testcontainers-python · GitHub

ServerContainer adjustments - #2

Merged
Tranquility2 merged 2 commits into
Tranquility2:srv_containerfrom
testcontainers:srv_container
Jun 17, 2024
Merged

ServerContainer adjustments#2
Tranquility2 merged 2 commits into
Tranquility2:srv_containerfrom
testcontainers:srv_container

Conversation

alexanderankin commented Jun 16, 2024
edited
Loading

Copy link
Copy Markdown

some additional thoughts, maybe ServerContainer direction should be clarified - its for FastAPI/Lambda module - in the class's doc string.

Additionally I want to make DockerImage and image as string more interchangeable, not just in servercontainer but everywhere, similar to how python has os.PathLike we should have DockerImageName type which includes DockerImage and str - https://java.testcontainers.org/features/creating_images/

…refactor

* fix the docs so that we can mark DbContainer as deprecated for removal
* add a warning to ServerContainer just in case it is actually possible to move it out of core
* use glob for modules/index.rst
* clean up the table of contents so that deprecated classes do not appear on the front page
* prepare to refactor the dockerimage stuff with the same class name/structure as Java (DockerImageName, ImageFromDockerfile)

Copy link
Copy Markdown
Author

additionally, had to make httpx not optional as it was referenced in a doctest

Copy link
Copy Markdown
Owner

This is nice, I fully understand the needs to actually be using "DockerImage", my implementation was wrong to use the image file directly..
If I understand currently this is much more like in Java:

public GenericContainer dslContainer = new GenericContainer(
    new ImageFromDockerfile()
            .withFileFromString("folder/someFile.txt", "hello")

Tranquility2 merged commit 4b57208 into Tranquility2:srv_container Jun 17, 2024
alexanderankin deleted the srv_container branch September 24, 2024 13:35
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants


Back | FazBrowse Home | New Git URL