+
    Òç·jY  ã                   óP  € R t ^ RIt^ RIt^ RIt^ RIt^ RIt^ RIt]P                  ! ]4      P                  4       P                  P                  tRt]P                  ! ]P                  ! R4      R4       ! R R]P                  4      4       t]R8X  d   ]P$                  ! 4        R# R# )z_Tests for the pm2 config (ecosystem.config.cjs):  python3 -m unittest scripts/test_ecosystem.pyNz:console.log(JSON.stringify(require(process.argv[1]).apps))Únodez
needs nodec                   ó>   a € ] tR t^t o R tR tR tR tR tRt	V t
R# )Ú	Ecosystemc           	     óÔ   € \         P                  ! R R\        \        \        R,          4      .RR/ \
        P                  CVCRR7      P                  p\        P                  ! V4      # )r   z-ezecosystem.config.cjsT)Úcapture_outputÚtextÚenvÚcheck)
Ú
subprocessÚrunÚLOADÚstrÚROOTÚosÚenvironÚstdoutÚjsonÚloads)Úselfr   Úouts   &, Ú./work/data/stt/webtt/scripts/test_ecosystem.pyÚappsÚEcosystem.apps   sV   € Ü�nŠn˜f d¬D´#´dÐ=SÕ6SÓ2TÐUÐfjÐquØ!6¤B§J¡JÐ!6°#Ð!6¸dôDßDJÁFð 	ä�zŠz˜#‹Ðó    c                ób  € V P                  4       w  pV P                  VR ,          R4       V P                  \        P                  ! VR,          4      \        4       V P                  VR,          R4       V P                  VR,          R4       V P                  VR,          R,          R	4       R
# )ÚnameÚwebttÚcwdÚscriptzscripts/serve.pyÚargsz$8289 --mcp mcp.config.json --computer   ÚPYTHONUNBUFFEREDÚ1N)r   ÚassertEqualÚpathlibÚPathr   ©r   Úapps   & r   Ú4test_runs_serve_py_with_the_mcp_bridge_from_the_repoÚ>Ecosystem.test_runs_serve_py_with_the_mcp_bridge_from_the_repo   s„   € Ø—	‘	“‰ˆØ×Ñ˜˜V� gÔ.Ø×ÑœŸš c¨%¥jÓ1´4Ô8Ø×Ñ˜˜X�Ð(:Ô;Ø×Ñ˜˜V�Ð&LÔMØ×Ñ˜˜U�Ð$6Õ7¸Ö=r   c                ó  € V P                  4       w  pV P                  \        P                  P	                  VR ,          4      VR ,          4       V P                  \        P
                  ! VR ,          \        P                  4      4       R# )ÚinterpreterN)r   Ú
assertTruer   ÚpathÚisabsÚaccessÚX_OKr%   s   & r   ÚAtest_python_is_an_absolute_path_so_boot_time_path_does_not_matterÚKEcosystem.test_python_is_an_absolute_path_so_boot_time_path_does_not_matter   sT   € Ø—	‘	“‰ˆØ�‰œŸ™Ÿ™ c¨-Õ&8Ó9¸3¸}Õ;MÔNØ�‰œŸ	š	 # mÕ"4´b·g±gÓ>Ö?r   c                ó°   € V P                  R RR7      w  pV P                  VR,          R 4       V P                  VR,          P                  R4      4       R# )z/opt/py/bin/python3Ú9000)ÚWEBTT_PYTHONÚ
WEBTT_PORTr*   r   z9000 N)r   r"   r+   Ú
startswithr%   s   & r   Ú&test_python_and_port_can_be_overriddenÚ0Ecosystem.test_python_and_port_can_be_overridden!   sH   € Ø—	‘	Ð'<È�	ÓP‰ˆØ×Ñ˜˜]Õ+Ð-BÔCØ�‰˜˜F�×.Ñ.¨wÓ7Ö8r   c                ó¾   € V P                  4       w  pV P                  VR ,          4       V P                  VR,          ^ 4       V P                  VR,          R4       R# )ÚautorestartÚmax_restartsÚkill_timeoutiˆ  N)r   r+   ÚassertGreaterÚassertGreaterEqualr%   s   & r   Ú=test_restarts_are_bounded_and_shutdown_waits_for_mcp_childrenÚGEcosystem.test_restarts_are_bounded_and_shutdown_waits_for_mcp_children&   sJ   € Ø—	‘	“‰ˆØ�‰˜˜MÕ*Ô+Ø×Ñ˜3˜~Õ.°Ô2Ø×Ñ  NÕ 3°TÖ:r   © N)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__r   r'   r0   r7   r?   Ú__static_attributes__Ú__classdictcell__)Ú__classdict__s   @r   r   r      s$   ø‡ € òò
>ò@ò
9÷
;ð ;r   r   Ú__main__)Ú__doc__r   r   r#   Úshutilr
   Úunittestr$   Ú__file__ÚresolveÚparentr   r   Ú
skipUnlessÚwhichÚTestCaser   rB   ÚmainrA   r   r   Ú<module>rT      s‘   ðÙ eÛ Û 	Û Û Û Û à‡|‚|�HÓ×%Ñ%Ó'×.Ñ.×5Ñ5€ØC€ð 
×Ò�V—\’\ &Ó)¨<Ó8ô;�×!Ñ!ó ;ó 9ð;ð> ˆzÔØ‡M‚M†Oñ r   