infrahub-testcontainers 1.4.9__py3-none-any.whl → 1.5.0b1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -29,7 +29,7 @@ INFRAHUB_SERVICES: dict[str, ContainerService] = {
29
29
 
30
30
  PROJECT_ENV_VARIABLES: dict[str, str] = {
31
31
  "MESSAGE_QUEUE_DOCKER_IMAGE": "rabbitmq:3.13.7-management",
32
- "CACHE_DOCKER_IMAGE": "redis:7.2.4",
32
+ "CACHE_DOCKER_IMAGE": "redis:7.2.11",
33
33
  "INFRAHUB_TESTING_DOCKER_IMAGE": "registry.opsmill.io/opsmill/infrahub",
34
34
  "INFRAHUB_TESTING_DOCKER_ENTRYPOINT": f"gunicorn --config backend/infrahub/serve/gunicorn_config.py -w {os.environ.get('INFRAHUB_TESTING_WEB_CONCURRENCY', 4)} --logger-class infrahub.serve.log.GunicornLogger infrahub.server:app", # noqa: E501
35
35
  "INFRAHUB_TESTING_IMAGE_VERSION": infrahub_version,
@@ -37,7 +37,7 @@ services:
37
37
  - ${INFRAHUB_TESTING_MESSAGE_QUEUE_PORT:-0}:15692
38
38
 
39
39
  cache:
40
- image: ${CACHE_DOCKER_IMAGE:-redis:7.2.4}
40
+ image: ${CACHE_DOCKER_IMAGE:-redis:7.2.11}
41
41
  restart: unless-stopped
42
42
  healthcheck:
43
43
  test: ["CMD-SHELL", "redis-cli ping | grep PONG"]
@@ -20,7 +20,7 @@ services:
20
20
  - ${INFRAHUB_TESTING_MESSAGE_QUEUE_PORT:-0}:15692
21
21
 
22
22
  cache:
23
- image: ${CACHE_DOCKER_IMAGE:-redis:7.2.4}
23
+ image: ${CACHE_DOCKER_IMAGE:-redis:7.2.11}
24
24
  restart: unless-stopped
25
25
  healthcheck:
26
26
  test: ["CMD-SHELL", "redis-cli ping | grep PONG"]
@@ -1,4 +1,4 @@
1
- from datetime import datetime, timezone
1
+ from datetime import UTC, datetime
2
2
  from enum import Enum
3
3
  from typing import Any
4
4
 
@@ -27,7 +27,7 @@ class InfrahubResultContext(BaseModel):
27
27
 
28
28
  class InfrahubActiveMeasurementItem(BaseModel):
29
29
  definition: MeasurementDefinition
30
- start_time: datetime = Field(default_factory=lambda: datetime.now(timezone.utc))
30
+ start_time: datetime = Field(default_factory=lambda: datetime.now(UTC))
31
31
  context: dict[str, Any] = Field(default_factory=dict)
32
32
 
33
33
 
@@ -1,6 +1,6 @@
1
1
  import hashlib
2
2
  import json
3
- from datetime import datetime, timezone
3
+ from datetime import UTC, datetime
4
4
  from types import TracebackType
5
5
  from typing import Any
6
6
 
@@ -35,7 +35,7 @@ class InfrahubPerformanceTest:
35
35
  self.env_vars = {}
36
36
  self.project_name = ""
37
37
  self.test_info = {}
38
- self.start_time = datetime.now(timezone.utc)
38
+ self.start_time = datetime.now(UTC)
39
39
  self.end_time: datetime | None = None
40
40
  self.results_url = results_url
41
41
  self.scraper_endpoint = ""
@@ -57,7 +57,7 @@ class InfrahubPerformanceTest:
57
57
 
58
58
  def finalize(self, session: pytest.Session) -> None:
59
59
  if self.initialized:
60
- self.end_time = datetime.now(timezone.utc)
60
+ self.end_time = datetime.now(UTC)
61
61
  self.extract_test_session_information(session)
62
62
  self.send_results()
63
63
 
@@ -129,7 +129,7 @@ class InfrahubPerformanceTest:
129
129
  if not exc_type and self.active_measurements:
130
130
  self.add_measurement(
131
131
  definition=self.active_measurements.definition,
132
- value=(datetime.now(timezone.utc) - self.active_measurements.start_time).total_seconds() * 1000,
132
+ value=(datetime.now(UTC) - self.active_measurements.start_time).total_seconds() * 1000,
133
133
  context=self.active_measurements.context,
134
134
  )
135
135
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: infrahub-testcontainers
3
- Version: 1.4.9
3
+ Version: 1.5.0b1
4
4
  Summary: Testcontainers instance for Infrahub to easily build integration tests
5
5
  License: Apache-2.0
6
6
  Author: OpsMill
@@ -15,7 +15,7 @@ Classifier: Programming Language :: Python :: 3.11
15
15
  Classifier: Programming Language :: Python :: 3.12
16
16
  Classifier: Programming Language :: Python :: 3.13
17
17
  Requires-Dist: httpx (>=0.28.1,<0.29.0)
18
- Requires-Dist: prefect-client (==3.4.13)
18
+ Requires-Dist: prefect-client (==3.4.23)
19
19
  Requires-Dist: psutil
20
20
  Requires-Dist: pydantic (>=2.10.6,<3.0.0)
21
21
  Requires-Dist: pytest
@@ -0,0 +1,17 @@
1
+ infrahub_testcontainers/__init__.py,sha256=oPpmesGgYBSdKTg1L37FGwYBeao1EHury5SJGul-CT8,216
2
+ infrahub_testcontainers/constants.py,sha256=mZ4hLvcf4rKk9wC7EId4MQxAY0sk4V99deB04N0J2bg,85
3
+ infrahub_testcontainers/container.py,sha256=RodXcIry-ppcpce_xnzpZuBHVinYyMq64NZ6cuCvhBE,20516
4
+ infrahub_testcontainers/docker-compose-cluster.test.yml,sha256=3Zgupnt6rOCk5EK0PsUXJL1thmTbKzQelC3AeS3sGKA,14764
5
+ infrahub_testcontainers/docker-compose.test.yml,sha256=EWxll1vzAdOzTdJX3_um30nIygM-bSHPskF6AelSZRk,11162
6
+ infrahub_testcontainers/haproxy.cfg,sha256=QUkG2Xu-hKoknPOeYKAkBT_xJH6U9CfIS0DTMFZJsnk,1305
7
+ infrahub_testcontainers/helpers.py,sha256=rGEWIeUfDg4w1wJNCzTm7_H1oA58HaMSORjVlHw1aWA,4677
8
+ infrahub_testcontainers/host.py,sha256=Z4_gGoGKKeM_HGVS7SdYL1FTNGyLBk8wzicdSKHpfmM,1486
9
+ infrahub_testcontainers/measurements.py,sha256=gR-uTasSIFCXrwvnNpIpfsQIopKftT7pBiarCgIShaQ,2214
10
+ infrahub_testcontainers/models.py,sha256=-TScLFW3V7SOe3eS1C8ANKmabpxGDTX5xu-V1pgtnbs,940
11
+ infrahub_testcontainers/performance_test.py,sha256=k14E0loMNuvhIJKEItbeKdbcOC0NBM-HhSe0RnVhJJo,6117
12
+ infrahub_testcontainers/plugin.py,sha256=I3RuZQ0dARyKHuqCf0y1Yj731P2Mwf3BJUehRJKeWrs,5645
13
+ infrahub_testcontainers/prometheus.yml,sha256=610xQEyj3xuVJMzPkC4m1fRnCrjGpiRBrXA2ytCLa54,599
14
+ infrahub_testcontainers-1.5.0b1.dist-info/METADATA,sha256=c3FVtrOon_LvFp8CO7wtIzbaRIWIGTzAuaVMsUJY-dA,1031
15
+ infrahub_testcontainers-1.5.0b1.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
16
+ infrahub_testcontainers-1.5.0b1.dist-info/entry_points.txt,sha256=gHOERdtVE0P8dYz6FHkn2KplpbXvCDJQnuWg_IP0-qQ,76
17
+ infrahub_testcontainers-1.5.0b1.dist-info/RECORD,,
@@ -1,17 +0,0 @@
1
- infrahub_testcontainers/__init__.py,sha256=oPpmesGgYBSdKTg1L37FGwYBeao1EHury5SJGul-CT8,216
2
- infrahub_testcontainers/constants.py,sha256=mZ4hLvcf4rKk9wC7EId4MQxAY0sk4V99deB04N0J2bg,85
3
- infrahub_testcontainers/container.py,sha256=OX3tylqFrqQ0tA2BFXI243LbWjRElgmcmL-hu_z1wQ8,20515
4
- infrahub_testcontainers/docker-compose-cluster.test.yml,sha256=dgnujqpM6dVWoqcSiRgsqXkyzdO-jRunHIIDd-K6FHg,14763
5
- infrahub_testcontainers/docker-compose.test.yml,sha256=P7MR-YQ-_0wGdoYW3N5TI5-6FyzpKnzhi_k0OIqgtTc,11161
6
- infrahub_testcontainers/haproxy.cfg,sha256=QUkG2Xu-hKoknPOeYKAkBT_xJH6U9CfIS0DTMFZJsnk,1305
7
- infrahub_testcontainers/helpers.py,sha256=rGEWIeUfDg4w1wJNCzTm7_H1oA58HaMSORjVlHw1aWA,4677
8
- infrahub_testcontainers/host.py,sha256=Z4_gGoGKKeM_HGVS7SdYL1FTNGyLBk8wzicdSKHpfmM,1486
9
- infrahub_testcontainers/measurements.py,sha256=gR-uTasSIFCXrwvnNpIpfsQIopKftT7pBiarCgIShaQ,2214
10
- infrahub_testcontainers/models.py,sha256=ASYyvl7d_WQz_i7y8-3iab9hwwmCl3OCJavqVbe8nXU,954
11
- infrahub_testcontainers/performance_test.py,sha256=hvwiy6tc_lWniYqGkqfOXVGAmA_IV15VOZqbiD9ezno,6149
12
- infrahub_testcontainers/plugin.py,sha256=I3RuZQ0dARyKHuqCf0y1Yj731P2Mwf3BJUehRJKeWrs,5645
13
- infrahub_testcontainers/prometheus.yml,sha256=610xQEyj3xuVJMzPkC4m1fRnCrjGpiRBrXA2ytCLa54,599
14
- infrahub_testcontainers-1.4.9.dist-info/METADATA,sha256=lrDijfTjdUTA4kywyQt3LQ8SKQuC6VBIfaJPFENrmZY,1029
15
- infrahub_testcontainers-1.4.9.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
16
- infrahub_testcontainers-1.4.9.dist-info/entry_points.txt,sha256=gHOERdtVE0P8dYz6FHkn2KplpbXvCDJQnuWg_IP0-qQ,76
17
- infrahub_testcontainers-1.4.9.dist-info/RECORD,,