rambleraptor commented on code in PR #2482:
URL: https://github.com/apache/iceberg-python/pull/2482#discussion_r2370431609
##########
tests/integration/test_catalog.py:
##########
@@ -74,6 +76,20 @@ def rest_catalog() -> Generator[Catalog, None, None]:
clean_up(test_catalog)
[email protected](scope="function")
+def rest_catalog_env() -> Generator[Catalog, None, None]:
+ if properties_json := os.environ.get("PYICEBERG_REST_CATALOG_PROPERTIES"):
+ properties = json.loads(properties_json)
+ test_catalog = RestCatalog(
+ "rest_env",
+ **properties,
+ )
Review Comment:
I like this way better. I was never a fan of setting a JSON-encoded string
as an environment variable, but didn't want to have to maintain a map of
settings -> env vars. This works perfectly.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]