orionis 0.414.0__py3-none-any.whl → 0.415.0__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.
- orionis/metadata/framework.py +1 -1
- orionis/test/core/unit_test.py +26 -10
- orionis/test/output/dumper.py +1 -1
- {orionis-0.414.0.dist-info → orionis-0.415.0.dist-info}/METADATA +1 -1
- {orionis-0.414.0.dist-info → orionis-0.415.0.dist-info}/RECORD +77 -68
- orionis-0.415.0.dist-info/top_level.txt +4 -0
- tests/container/entities/test_binding.py +1 -1
- tests/container/test_thread_safety.py +0 -1
- tests/testing/cases/__init__.py +0 -0
- tests/testing/cases/test_testing_asynchronous.py +63 -0
- tests/testing/cases/test_testing_synchronous.py +59 -0
- tests/testing/entities/__init__.py +0 -0
- tests/testing/entities/test_testing_result.py +185 -0
- tests/testing/enums/__init__.py +0 -0
- tests/testing/enums/test_testing_status.py +68 -0
- tests/testing/output/__init__.py +0 -0
- tests/testing/output/test_testing_dumper.py +32 -0
- tests/testing/output/test_testing_printer.py +42 -0
- tests/testing/test_testing_unit.py +110 -209
- orionis-0.414.0.dist-info/top_level.txt +0 -2
- tests/testing/test_testing_result.py +0 -131
- {tests/foundation → environment}/__init__.py +0 -0
- {tests/services/environment → environment}/test_services_environment.py +0 -0
- {tests/foundation/config → foundation}/__init__.py +0 -0
- {tests/foundation/config/app → foundation/config}/__init__.py +0 -0
- {tests/foundation/config/auth → foundation/config/app}/__init__.py +0 -0
- {tests/foundation → foundation}/config/app/test_foundation_config_app.py +0 -0
- {tests/foundation/config/cache → foundation/config/auth}/__init__.py +0 -0
- {tests/foundation → foundation}/config/auth/test_foundation_config_auth.py +0 -0
- {tests/foundation/config/cors → foundation/config/cache}/__init__.py +0 -0
- {tests/foundation → foundation}/config/cache/test_foundation_config_cache.py +0 -0
- {tests/foundation → foundation}/config/cache/test_foundation_config_cache_file.py +0 -0
- {tests/foundation → foundation}/config/cache/test_foundation_config_cache_stores.py +0 -0
- {tests/foundation/config/database → foundation/config/cors}/__init__.py +0 -0
- {tests/foundation → foundation}/config/cors/test_foundation_config_cors.py +0 -0
- {tests/foundation/config/filesystems → foundation/config/database}/__init__.py +0 -0
- {tests/foundation → foundation}/config/database/test_foundation_config_database.py +0 -0
- {tests/foundation → foundation}/config/database/test_foundation_config_database_connections.py +0 -0
- {tests/foundation → foundation}/config/database/test_foundation_config_database_mysql.py +0 -0
- {tests/foundation → foundation}/config/database/test_foundation_config_database_oracle.py +0 -0
- {tests/foundation → foundation}/config/database/test_foundation_config_database_pgsql.py +0 -0
- {tests/foundation → foundation}/config/database/test_foundation_config_database_sqlite.py +0 -0
- {tests/foundation/config/logging → foundation/config/filesystems}/__init__.py +0 -0
- {tests/foundation → foundation}/config/filesystems/test_foundation_config_filesystems.py +0 -0
- {tests/foundation → foundation}/config/filesystems/test_foundation_config_filesystems_aws.py +0 -0
- {tests/foundation → foundation}/config/filesystems/test_foundation_config_filesystems_disks.py +0 -0
- {tests/foundation → foundation}/config/filesystems/test_foundation_config_filesystems_local.py +0 -0
- {tests/foundation → foundation}/config/filesystems/test_foundation_config_filesystems_public.py +0 -0
- {tests/foundation/config/mail → foundation/config/logging}/__init__.py +0 -0
- {tests/foundation → foundation}/config/logging/test_foundation_config_logging.py +0 -0
- {tests/foundation → foundation}/config/logging/test_foundation_config_logging_channels.py +0 -0
- {tests/foundation → foundation}/config/logging/test_foundation_config_logging_chunked.py +0 -0
- {tests/foundation → foundation}/config/logging/test_foundation_config_logging_daily.py +0 -0
- {tests/foundation → foundation}/config/logging/test_foundation_config_logging_hourly.py +0 -0
- {tests/foundation → foundation}/config/logging/test_foundation_config_logging_monthly.py +0 -0
- {tests/foundation → foundation}/config/logging/test_foundation_config_logging_stack.py +0 -0
- {tests/foundation → foundation}/config/logging/test_foundation_config_logging_weekly.py +0 -0
- {tests/foundation/config/queue → foundation/config/mail}/__init__.py +0 -0
- {tests/foundation → foundation}/config/mail/test_foundation_config_mail.py +0 -0
- {tests/foundation → foundation}/config/mail/test_foundation_config_mail_file.py +0 -0
- {tests/foundation → foundation}/config/mail/test_foundation_config_mail_mailers.py +0 -0
- {tests/foundation → foundation}/config/mail/test_foundation_config_mail_smtp.py +0 -0
- {tests/foundation/config/root → foundation/config/queue}/__init__.py +0 -0
- {tests/foundation → foundation}/config/queue/test_foundation_config_queue.py +0 -0
- {tests/foundation → foundation}/config/queue/test_foundation_config_queue_brokers.py +0 -0
- {tests/foundation → foundation}/config/queue/test_foundation_config_queue_database.py +0 -0
- {tests/foundation/config/session → foundation/config/root}/__init__.py +0 -0
- {tests/foundation → foundation}/config/root/test_foundation_config_root_paths.py +0 -0
- {tests/foundation/config/startup → foundation/config/session}/__init__.py +0 -0
- {tests/foundation → foundation}/config/session/test_foundation_config_session.py +0 -0
- {tests/foundation/config/testing → foundation/config/startup}/__init__.py +0 -0
- {tests/foundation → foundation}/config/startup/test_foundation_config_startup.py +0 -0
- {tests/foundation/exceptions → foundation/config/testing}/__init__.py +0 -0
- {tests/foundation → foundation}/config/testing/test_foundation_config_testing.py +0 -0
- {tests/services/environment → foundation/exceptions}/__init__.py +0 -0
- {tests/foundation → foundation}/exceptions/test_foundation_config_exceptions.py +0 -0
- {orionis-0.414.0.dist-info → orionis-0.415.0.dist-info}/WHEEL +0 -0
- {orionis-0.414.0.dist-info → orionis-0.415.0.dist-info}/licenses/LICENCE +0 -0
- {orionis-0.414.0.dist-info → orionis-0.415.0.dist-info}/zip-safe +0 -0
orionis/metadata/framework.py
CHANGED
orionis/test/core/unit_test.py
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import io
|
|
2
2
|
import json
|
|
3
|
-
import os
|
|
4
3
|
import re
|
|
5
4
|
import time
|
|
6
5
|
import traceback
|
|
@@ -316,9 +315,27 @@ class UnitTest(IUnitTest):
|
|
|
316
315
|
tests = self.__loader.discover(
|
|
317
316
|
start_dir=str(full_path),
|
|
318
317
|
pattern=self.__pattern,
|
|
319
|
-
top_level_dir=
|
|
318
|
+
top_level_dir="."
|
|
320
319
|
)
|
|
321
320
|
|
|
321
|
+
# Check for failed test imports (unittest.loader._FailedTest)
|
|
322
|
+
for test in self.__flattenTestSuite(tests):
|
|
323
|
+
if test.__class__.__name__ == "_FailedTest":
|
|
324
|
+
# Extract the error message from the test's traceback
|
|
325
|
+
error_message = ""
|
|
326
|
+
if hasattr(test, "_exception"):
|
|
327
|
+
error_message = str(test._exception)
|
|
328
|
+
elif hasattr(test, "_outcome") and hasattr(test._outcome, "errors"):
|
|
329
|
+
error_message = str(test._outcome.errors)
|
|
330
|
+
else:
|
|
331
|
+
# Try to get error from test id or str(test)
|
|
332
|
+
error_message = str(test)
|
|
333
|
+
raise OrionisTestValueError(
|
|
334
|
+
f"Failed to import test module: {test.id()}.\n"
|
|
335
|
+
f"Error details: {error_message}\n"
|
|
336
|
+
"Please check for import errors or missing dependencies."
|
|
337
|
+
)
|
|
338
|
+
|
|
322
339
|
# If name pattern is provided, filter tests by name
|
|
323
340
|
if test_name_pattern:
|
|
324
341
|
tests = self.__filterTestsByName(
|
|
@@ -365,6 +382,7 @@ class UnitTest(IUnitTest):
|
|
|
365
382
|
f"Error importing tests from path '{str(full_path)}': {str(e)}.\n"
|
|
366
383
|
"Please verify that the directory and test modules are accessible and correct."
|
|
367
384
|
)
|
|
385
|
+
|
|
368
386
|
except Exception as e:
|
|
369
387
|
|
|
370
388
|
# Raise a general error for unexpected issues
|
|
@@ -700,6 +718,11 @@ class UnitTest(IUnitTest):
|
|
|
700
718
|
# Iterate through all test cases in the original (possibly nested) suite
|
|
701
719
|
for test_case in self.__flattenTestSuite(self.__suite):
|
|
702
720
|
|
|
721
|
+
# If it's a failed test, add it as-is to the flattened suite
|
|
722
|
+
if test_case.__class__.__name__ == "_FailedTest":
|
|
723
|
+
flattened_suite.addTest(test_case)
|
|
724
|
+
continue
|
|
725
|
+
|
|
703
726
|
# Get the test method name using reflection
|
|
704
727
|
rf_instance = ReflectionInstance(test_case)
|
|
705
728
|
method_name = rf_instance.getAttribute("_testMethodName")
|
|
@@ -730,14 +753,7 @@ class UnitTest(IUnitTest):
|
|
|
730
753
|
continue
|
|
731
754
|
|
|
732
755
|
# Attempt to extract dependency information from the test method signature
|
|
733
|
-
|
|
734
|
-
signature = rf_instance.getMethodDependencies(method_name)
|
|
735
|
-
except Exception as e:
|
|
736
|
-
raise OrionisTestValueError(
|
|
737
|
-
f"Failed to resolve test dependencies in '../{method_name}.py. "
|
|
738
|
-
f"This may be caused by incorrect imports, missing modules, or undefined classes. "
|
|
739
|
-
f"Please verify that all test methods and their dependencies are correctly declared and accessible."
|
|
740
|
-
)
|
|
756
|
+
signature = rf_instance.getMethodDependencies(method_name)
|
|
741
757
|
|
|
742
758
|
# If there are no dependencies to resolve, or unresolved dependencies exist, add as-is
|
|
743
759
|
if ((not signature.resolved and not signature.unresolved) or (not signature.resolved and len(signature.unresolved) > 0)):
|
orionis/test/output/dumper.py
CHANGED
|
@@ -1,3 +1,58 @@
|
|
|
1
|
+
environment/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
+
environment/test_services_environment.py,sha256=6UH3g2Z2DQYtGnyySCRnT35VCENlL-PQWHIdH6zA9rw,3767
|
|
3
|
+
foundation/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
4
|
+
foundation/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
5
|
+
foundation/config/app/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
6
|
+
foundation/config/app/test_foundation_config_app.py,sha256=3ol-IOoYs5wbxEY7rPsiR1LnFTbcaeqcKUy0x1KTVH0,5580
|
|
7
|
+
foundation/config/auth/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
8
|
+
foundation/config/auth/test_foundation_config_auth.py,sha256=iDK3VuJ3TtuEYE5dR8xaByQ8mZLbrsFdCqaFrfCFlgY,1048
|
|
9
|
+
foundation/config/cache/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
|
+
foundation/config/cache/test_foundation_config_cache.py,sha256=fDtw_0NPB2h18nrR13zD6WXL7lK6QyQKjpj6R61LMuw,4653
|
|
11
|
+
foundation/config/cache/test_foundation_config_cache_file.py,sha256=X_kb3D5LkZOq1VPqemgP1XRTsD_FLk8CG0MZWl1Wp1Y,3674
|
|
12
|
+
foundation/config/cache/test_foundation_config_cache_stores.py,sha256=yRVB5aBEGfL6sjJvLQAP0SFOXyiB7UjDgv01d5mPtjo,4584
|
|
13
|
+
foundation/config/cors/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
14
|
+
foundation/config/cors/test_foundation_config_cors.py,sha256=0B19I4g5TRp9vQu79vcteeIsjbBpiIoE6Mxslx5d9os,6721
|
|
15
|
+
foundation/config/database/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
16
|
+
foundation/config/database/test_foundation_config_database.py,sha256=OiO42vc940RVCcHTj7XoMO-xpKFQ5l-5JpSYR4jwR24,4846
|
|
17
|
+
foundation/config/database/test_foundation_config_database_connections.py,sha256=sQ5b2rwmhdMk44oZOx4Hb6EGW_3DW3dnDUtTKu0QSWA,6977
|
|
18
|
+
foundation/config/database/test_foundation_config_database_mysql.py,sha256=200U6fL9XysUJ7tynSCKcWdRPEd7Fh4TP-lfSE2wMzY,12432
|
|
19
|
+
foundation/config/database/test_foundation_config_database_oracle.py,sha256=zhWuAFPKW5EQtTmfIunqo8mKjcdqbLy-nnSiy4x6lS4,10413
|
|
20
|
+
foundation/config/database/test_foundation_config_database_pgsql.py,sha256=Vl9AcYw-lTGUbyH8r6wtO27pd1B0ndRYwaJLiaivIRI,8531
|
|
21
|
+
foundation/config/database/test_foundation_config_database_sqlite.py,sha256=oxb0kyENsRHNiw5NwqYicB-URM43j0jTlL5leiPBm8Y,7362
|
|
22
|
+
foundation/config/filesystems/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
23
|
+
foundation/config/filesystems/test_foundation_config_filesystems.py,sha256=_XYpbESjUwX-LmLv2Ik4dPc-32KEiaa7_Iz753dXz-E,5278
|
|
24
|
+
foundation/config/filesystems/test_foundation_config_filesystems_aws.py,sha256=IqYDNTmYAtFLFsa0jLzbYZSApqo_YHxysaD74ytezrc,5897
|
|
25
|
+
foundation/config/filesystems/test_foundation_config_filesystems_disks.py,sha256=lG4bvb0kAcGQbwwtDzKPnW0jZG7Aniw52A4m-3vaL4Q,6474
|
|
26
|
+
foundation/config/filesystems/test_foundation_config_filesystems_local.py,sha256=X10AQjmlNB2sty34hXOkTDcMcZDraF-x1Kw6X7NxcBc,4296
|
|
27
|
+
foundation/config/filesystems/test_foundation_config_filesystems_public.py,sha256=W94Fb5CZ81HMaDI9Z_YetdY0ma77qINad-2AWBcyRlI,5900
|
|
28
|
+
foundation/config/logging/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
29
|
+
foundation/config/logging/test_foundation_config_logging.py,sha256=vCYAp8qe6SOo1VJQcb1_R5JMQe00HCl78D4E-43Dxm8,3183
|
|
30
|
+
foundation/config/logging/test_foundation_config_logging_channels.py,sha256=c4OT2o_ml48uqwsCChXffRxFMjqpS3yTplZyvIqsEhA,8990
|
|
31
|
+
foundation/config/logging/test_foundation_config_logging_chunked.py,sha256=TL-pLde4LAvHTcj01RT_Sa_OkwbQHzKrAH-9UGKVaMY,7021
|
|
32
|
+
foundation/config/logging/test_foundation_config_logging_daily.py,sha256=Sf5vG6WL558N41dukprA5iiT1LoBXi1ak19QGSZpAsI,7076
|
|
33
|
+
foundation/config/logging/test_foundation_config_logging_hourly.py,sha256=zjDDXykck_gH9TLPcoESwgjUd-6qZJDjjFwD_Xz2Yak,6765
|
|
34
|
+
foundation/config/logging/test_foundation_config_logging_monthly.py,sha256=59AKYce42PqVVNGu_FjsQtR2EtXePUvYwgF4MkA01WM,6370
|
|
35
|
+
foundation/config/logging/test_foundation_config_logging_stack.py,sha256=BYTtZmbJlGeW_7qXo7AlyQZOluvZDzMgBTM68hbq2nc,5302
|
|
36
|
+
foundation/config/logging/test_foundation_config_logging_weekly.py,sha256=g-x3VCN_L1jrrSrsW1UkBWYpKeuK5ASAAzhlKQJDkvQ,7697
|
|
37
|
+
foundation/config/mail/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
38
|
+
foundation/config/mail/test_foundation_config_mail.py,sha256=xR3HY218J7vecdM1h0TaAfX4DGl90PUgmktlylT_4S8,4209
|
|
39
|
+
foundation/config/mail/test_foundation_config_mail_file.py,sha256=9apGs381QxaO9gwwDTAtObF61AMFTd61c1Sfx1nZeYM,3023
|
|
40
|
+
foundation/config/mail/test_foundation_config_mail_mailers.py,sha256=tcQ2EAcF2EOQ_QB2a765bexU_RImz8P7zBndi_tAFUk,3427
|
|
41
|
+
foundation/config/mail/test_foundation_config_mail_smtp.py,sha256=cf2gRJ0-IcqN38MhXIP_pfVjsRsRlCDOHPNB11B7daE,4883
|
|
42
|
+
foundation/config/queue/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
43
|
+
foundation/config/queue/test_foundation_config_queue.py,sha256=xeeEmfgObuAnry7qB530vXWyNmCNl76vHyWXH0Eb-Qg,3416
|
|
44
|
+
foundation/config/queue/test_foundation_config_queue_brokers.py,sha256=COjFZ25AzA7clRCkjt6MseaiuxYOulLEsZxGfY2Lo5c,3051
|
|
45
|
+
foundation/config/queue/test_foundation_config_queue_database.py,sha256=qLYXjG8YVIp_NWYcZA9A2GmOdjFyt3snq9X1cdIok8M,4830
|
|
46
|
+
foundation/config/root/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
47
|
+
foundation/config/root/test_foundation_config_root_paths.py,sha256=HqxBdLI-mdsinSEjRKKKvbV2QzmXNfs4b__RzRoftiE,7102
|
|
48
|
+
foundation/config/session/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
49
|
+
foundation/config/session/test_foundation_config_session.py,sha256=Zvjzzy8ApRTogRbr3RaIe4EhvWoLKsX9udb2DSokCMI,6392
|
|
50
|
+
foundation/config/startup/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
51
|
+
foundation/config/startup/test_foundation_config_startup.py,sha256=_7pi_uaI3OJcQu4hSh_k0iE_wWZDU6kWUOS5Y9yp17c,6807
|
|
52
|
+
foundation/config/testing/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
53
|
+
foundation/config/testing/test_foundation_config_testing.py,sha256=BQsQVGmGBiIyRPag6d-meBxip4tW9rWXbKR-V-YDIfU,8237
|
|
54
|
+
foundation/exceptions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
55
|
+
foundation/exceptions/test_foundation_config_exceptions.py,sha256=tiXKxGSP8majXpLPyoGR0WGvDE1LoLXQK6NpcQNqz_A,4091
|
|
1
56
|
orionis/__init__.py,sha256=4AGBG1xD3NjsqkmQ-fD3pde7tiO26iwOpdvJoNvP0kI,201
|
|
2
57
|
orionis/_console/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
3
58
|
orionis/_console/command_filter.py,sha256=bn0fcWfQg13DrQBaV4NopNxdP-6up0G54Qmhg7r_BKA,1211
|
|
@@ -258,7 +313,7 @@ orionis/foundation/providers/progress_bar_provider.py,sha256=WW3grNgH-yV2meSSTeO
|
|
|
258
313
|
orionis/foundation/providers/testing_provider.py,sha256=iJSN2RIChbYIL-1ue6vmPmDMCSrvERDkti4Er9MPiLA,1102
|
|
259
314
|
orionis/foundation/providers/workers_provider.py,sha256=kiQjQRyUEyiBX2zcbF_KmqRgvc7Bvxsvg5oMtIvYniM,1075
|
|
260
315
|
orionis/metadata/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
261
|
-
orionis/metadata/framework.py,sha256=
|
|
316
|
+
orionis/metadata/framework.py,sha256=PBPhkOuTumFXjj2FcS-EUvGdP6UNUR8seyMhX5M4YOw,4960
|
|
262
317
|
orionis/metadata/package.py,sha256=tqLfBRo-w1j_GN4xvzUNFyweWYFS-qhSgAEc-AmCH1M,5452
|
|
263
318
|
orionis/services/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
264
319
|
orionis/services/asynchrony/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -394,7 +449,7 @@ orionis/test/contracts/render.py,sha256=0o6NjrKx2ewBf1JvAf8BaAtJQPb64yq1FJCeKb3i
|
|
|
394
449
|
orionis/test/contracts/test_result.py,sha256=vTNdVbWlzp0rsZ7KFPpFi6YjQMhUeurkRPLjBBcHRvc,3371
|
|
395
450
|
orionis/test/contracts/unit_test.py,sha256=ZfgcB3JGBCcIOQ17uM6x355bHlGRHAR1uPBR4K-zCuc,5497
|
|
396
451
|
orionis/test/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
397
|
-
orionis/test/core/unit_test.py,sha256=
|
|
452
|
+
orionis/test/core/unit_test.py,sha256=QJa_xleHdMEQUdfxzv8OuNWFeiXMsjJSGju4885GZnA,67381
|
|
398
453
|
orionis/test/entities/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
399
454
|
orionis/test/entities/result.py,sha256=eO9YWZ-I3ABNzlJ6jk09BUqnXjaHQ8mqeur2-pRGK9s,4041
|
|
400
455
|
orionis/test/enums/__init__.py,sha256=M3imAgMvKFTKg55FbtVoY3zxj7QRY9AfaUWxiSZVvn4,66
|
|
@@ -406,7 +461,7 @@ orionis/test/exceptions/persistence.py,sha256=GbNwpUfrtZ-VstX_Amflg8OwQ3WEWOnDmn
|
|
|
406
461
|
orionis/test/exceptions/runtime.py,sha256=yLLBtDR61k53OIAwi5wVLxap79Agh2khXrhRb4bTe9k,778
|
|
407
462
|
orionis/test/exceptions/value.py,sha256=P9SD64EWATKneV-QP-yhfJ2GxyypKxqgmk5MqiguxV0,1001
|
|
408
463
|
orionis/test/output/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
409
|
-
orionis/test/output/dumper.py,sha256=
|
|
464
|
+
orionis/test/output/dumper.py,sha256=7NRrFCFcMmI5T_1oHT90ymJOfhtfBRg0LXo5Io_dgzY,7147
|
|
410
465
|
orionis/test/output/printer.py,sha256=cpElVLaK94JtQeHpgN-HTSuE8dJhPhZMt51L7Lramz8,29080
|
|
411
466
|
orionis/test/records/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
412
467
|
orionis/test/records/logs.py,sha256=WhOmRJhQck76vx8l_c_7M-H8_RS9p3yB_jJ39Rnx-Lc,19050
|
|
@@ -428,17 +483,17 @@ orionis/test/validators/web_report.py,sha256=-h3Fe9jY93_kzUhd2NBIqEfCcBpu-8Ei9x3
|
|
|
428
483
|
orionis/test/validators/workers.py,sha256=LGffDKtK6SKixFKzIYPQpI5aFeQPAGXpv_LUtmEu6g4,1102
|
|
429
484
|
orionis/test/view/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
430
485
|
orionis/test/view/render.py,sha256=3ICz68l-WF3BtnYqH5m-ktN9UD00MELMbmMnyJDV74A,4768
|
|
431
|
-
orionis-0.
|
|
486
|
+
orionis-0.415.0.dist-info/licenses/LICENCE,sha256=-_4cF2EBKuYVS_SQpy1uapq0oJPUU1vl_RUWSy2jJTo,1111
|
|
432
487
|
tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
433
488
|
tests/container/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
434
489
|
tests/container/test_container.py,sha256=asv8TkkupVoex6SWod74NBl4dSs7wb9mLmu_glNdNy8,14815
|
|
435
490
|
tests/container/test_singleton.py,sha256=GkwFaLtRvOQCNMpaCXfQiPu6tJWRm3gkDaJ0vzQn1ko,4689
|
|
436
|
-
tests/container/test_thread_safety.py,sha256=
|
|
491
|
+
tests/container/test_thread_safety.py,sha256=CxEMZRDHapJSX73oDrZBu2gxGJhFiBTo56pl0FzQbzA,3722
|
|
437
492
|
tests/container/context/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
438
493
|
tests/container/context/test_manager.py,sha256=QfzhzkK5LFmtI7AEE-dzceBROTo7VNnQfL3EGgYqK64,1354
|
|
439
494
|
tests/container/context/test_scope.py,sha256=2ykGAmey5xu3cXASseIiOHosJ4QwABbQqRU3_WahO8c,1221
|
|
440
495
|
tests/container/entities/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
441
|
-
tests/container/entities/test_binding.py,sha256=
|
|
496
|
+
tests/container/entities/test_binding.py,sha256=CFiBGlOeQKK4ielkj1JqxOWJSqrsi2VFIE7nE5R6ykU,9709
|
|
442
497
|
tests/container/enums/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
443
498
|
tests/container/enums/test_lifetimes.py,sha256=JFb4q1rgo10C5ibQ6LS-776NevxCMNLSq_cd7D1O8Ps,3511
|
|
444
499
|
tests/container/facades/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -462,67 +517,12 @@ tests/container/validators/test_is_valid_alias.py,sha256=egVf6IfSXurIdu8hKo03rws
|
|
|
462
517
|
tests/container/validators/test_lifetime.py,sha256=5PequjXAcIcp0Q4TIki7THSU31XftGpI0u1mVGqHmpU,4692
|
|
463
518
|
tests/example/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
464
519
|
tests/example/test_example.py,sha256=XJEcsro3vCO5m4zvMiWUGphvd0C7oIkBtUfQgTDsdUU,25568
|
|
465
|
-
tests/foundation/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
466
|
-
tests/foundation/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
467
|
-
tests/foundation/config/app/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
468
|
-
tests/foundation/config/app/test_foundation_config_app.py,sha256=3ol-IOoYs5wbxEY7rPsiR1LnFTbcaeqcKUy0x1KTVH0,5580
|
|
469
|
-
tests/foundation/config/auth/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
470
|
-
tests/foundation/config/auth/test_foundation_config_auth.py,sha256=iDK3VuJ3TtuEYE5dR8xaByQ8mZLbrsFdCqaFrfCFlgY,1048
|
|
471
|
-
tests/foundation/config/cache/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
472
|
-
tests/foundation/config/cache/test_foundation_config_cache.py,sha256=fDtw_0NPB2h18nrR13zD6WXL7lK6QyQKjpj6R61LMuw,4653
|
|
473
|
-
tests/foundation/config/cache/test_foundation_config_cache_file.py,sha256=X_kb3D5LkZOq1VPqemgP1XRTsD_FLk8CG0MZWl1Wp1Y,3674
|
|
474
|
-
tests/foundation/config/cache/test_foundation_config_cache_stores.py,sha256=yRVB5aBEGfL6sjJvLQAP0SFOXyiB7UjDgv01d5mPtjo,4584
|
|
475
|
-
tests/foundation/config/cors/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
476
|
-
tests/foundation/config/cors/test_foundation_config_cors.py,sha256=0B19I4g5TRp9vQu79vcteeIsjbBpiIoE6Mxslx5d9os,6721
|
|
477
|
-
tests/foundation/config/database/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
478
|
-
tests/foundation/config/database/test_foundation_config_database.py,sha256=OiO42vc940RVCcHTj7XoMO-xpKFQ5l-5JpSYR4jwR24,4846
|
|
479
|
-
tests/foundation/config/database/test_foundation_config_database_connections.py,sha256=sQ5b2rwmhdMk44oZOx4Hb6EGW_3DW3dnDUtTKu0QSWA,6977
|
|
480
|
-
tests/foundation/config/database/test_foundation_config_database_mysql.py,sha256=200U6fL9XysUJ7tynSCKcWdRPEd7Fh4TP-lfSE2wMzY,12432
|
|
481
|
-
tests/foundation/config/database/test_foundation_config_database_oracle.py,sha256=zhWuAFPKW5EQtTmfIunqo8mKjcdqbLy-nnSiy4x6lS4,10413
|
|
482
|
-
tests/foundation/config/database/test_foundation_config_database_pgsql.py,sha256=Vl9AcYw-lTGUbyH8r6wtO27pd1B0ndRYwaJLiaivIRI,8531
|
|
483
|
-
tests/foundation/config/database/test_foundation_config_database_sqlite.py,sha256=oxb0kyENsRHNiw5NwqYicB-URM43j0jTlL5leiPBm8Y,7362
|
|
484
|
-
tests/foundation/config/filesystems/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
485
|
-
tests/foundation/config/filesystems/test_foundation_config_filesystems.py,sha256=_XYpbESjUwX-LmLv2Ik4dPc-32KEiaa7_Iz753dXz-E,5278
|
|
486
|
-
tests/foundation/config/filesystems/test_foundation_config_filesystems_aws.py,sha256=IqYDNTmYAtFLFsa0jLzbYZSApqo_YHxysaD74ytezrc,5897
|
|
487
|
-
tests/foundation/config/filesystems/test_foundation_config_filesystems_disks.py,sha256=lG4bvb0kAcGQbwwtDzKPnW0jZG7Aniw52A4m-3vaL4Q,6474
|
|
488
|
-
tests/foundation/config/filesystems/test_foundation_config_filesystems_local.py,sha256=X10AQjmlNB2sty34hXOkTDcMcZDraF-x1Kw6X7NxcBc,4296
|
|
489
|
-
tests/foundation/config/filesystems/test_foundation_config_filesystems_public.py,sha256=W94Fb5CZ81HMaDI9Z_YetdY0ma77qINad-2AWBcyRlI,5900
|
|
490
|
-
tests/foundation/config/logging/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
491
|
-
tests/foundation/config/logging/test_foundation_config_logging.py,sha256=vCYAp8qe6SOo1VJQcb1_R5JMQe00HCl78D4E-43Dxm8,3183
|
|
492
|
-
tests/foundation/config/logging/test_foundation_config_logging_channels.py,sha256=c4OT2o_ml48uqwsCChXffRxFMjqpS3yTplZyvIqsEhA,8990
|
|
493
|
-
tests/foundation/config/logging/test_foundation_config_logging_chunked.py,sha256=TL-pLde4LAvHTcj01RT_Sa_OkwbQHzKrAH-9UGKVaMY,7021
|
|
494
|
-
tests/foundation/config/logging/test_foundation_config_logging_daily.py,sha256=Sf5vG6WL558N41dukprA5iiT1LoBXi1ak19QGSZpAsI,7076
|
|
495
|
-
tests/foundation/config/logging/test_foundation_config_logging_hourly.py,sha256=zjDDXykck_gH9TLPcoESwgjUd-6qZJDjjFwD_Xz2Yak,6765
|
|
496
|
-
tests/foundation/config/logging/test_foundation_config_logging_monthly.py,sha256=59AKYce42PqVVNGu_FjsQtR2EtXePUvYwgF4MkA01WM,6370
|
|
497
|
-
tests/foundation/config/logging/test_foundation_config_logging_stack.py,sha256=BYTtZmbJlGeW_7qXo7AlyQZOluvZDzMgBTM68hbq2nc,5302
|
|
498
|
-
tests/foundation/config/logging/test_foundation_config_logging_weekly.py,sha256=g-x3VCN_L1jrrSrsW1UkBWYpKeuK5ASAAzhlKQJDkvQ,7697
|
|
499
|
-
tests/foundation/config/mail/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
500
|
-
tests/foundation/config/mail/test_foundation_config_mail.py,sha256=xR3HY218J7vecdM1h0TaAfX4DGl90PUgmktlylT_4S8,4209
|
|
501
|
-
tests/foundation/config/mail/test_foundation_config_mail_file.py,sha256=9apGs381QxaO9gwwDTAtObF61AMFTd61c1Sfx1nZeYM,3023
|
|
502
|
-
tests/foundation/config/mail/test_foundation_config_mail_mailers.py,sha256=tcQ2EAcF2EOQ_QB2a765bexU_RImz8P7zBndi_tAFUk,3427
|
|
503
|
-
tests/foundation/config/mail/test_foundation_config_mail_smtp.py,sha256=cf2gRJ0-IcqN38MhXIP_pfVjsRsRlCDOHPNB11B7daE,4883
|
|
504
|
-
tests/foundation/config/queue/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
505
|
-
tests/foundation/config/queue/test_foundation_config_queue.py,sha256=xeeEmfgObuAnry7qB530vXWyNmCNl76vHyWXH0Eb-Qg,3416
|
|
506
|
-
tests/foundation/config/queue/test_foundation_config_queue_brokers.py,sha256=COjFZ25AzA7clRCkjt6MseaiuxYOulLEsZxGfY2Lo5c,3051
|
|
507
|
-
tests/foundation/config/queue/test_foundation_config_queue_database.py,sha256=qLYXjG8YVIp_NWYcZA9A2GmOdjFyt3snq9X1cdIok8M,4830
|
|
508
|
-
tests/foundation/config/root/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
509
|
-
tests/foundation/config/root/test_foundation_config_root_paths.py,sha256=HqxBdLI-mdsinSEjRKKKvbV2QzmXNfs4b__RzRoftiE,7102
|
|
510
|
-
tests/foundation/config/session/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
511
|
-
tests/foundation/config/session/test_foundation_config_session.py,sha256=Zvjzzy8ApRTogRbr3RaIe4EhvWoLKsX9udb2DSokCMI,6392
|
|
512
|
-
tests/foundation/config/startup/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
513
|
-
tests/foundation/config/startup/test_foundation_config_startup.py,sha256=_7pi_uaI3OJcQu4hSh_k0iE_wWZDU6kWUOS5Y9yp17c,6807
|
|
514
|
-
tests/foundation/config/testing/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
515
|
-
tests/foundation/config/testing/test_foundation_config_testing.py,sha256=BQsQVGmGBiIyRPag6d-meBxip4tW9rWXbKR-V-YDIfU,8237
|
|
516
|
-
tests/foundation/exceptions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
517
|
-
tests/foundation/exceptions/test_foundation_config_exceptions.py,sha256=tiXKxGSP8majXpLPyoGR0WGvDE1LoLXQK6NpcQNqz_A,4091
|
|
518
520
|
tests/metadata/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
519
521
|
tests/metadata/test_metadata_framework.py,sha256=1tCNciuPVgZPK-V8PzENJCXN-1bTktWPN9u03N4Eelw,5499
|
|
520
522
|
tests/metadata/test_metadata_package.py,sha256=gXIX-N9toEHJsmFkdhAvJRnz2T5e6pbgK37I1eFYTGM,4770
|
|
521
523
|
tests/services/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
522
524
|
tests/services/asynchrony/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
523
525
|
tests/services/asynchrony/test_services_asynchrony_coroutine.py,sha256=34Y0D6w2bVo_dm3oj0wzedMIJuSYieUG9Y2J1EQmZeo,3439
|
|
524
|
-
tests/services/environment/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
525
|
-
tests/services/environment/test_services_environment.py,sha256=6UH3g2Z2DQYtGnyySCRnT35VCENlL-PQWHIdH6zA9rw,3767
|
|
526
526
|
tests/services/introspection/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
527
527
|
tests/services/introspection/test_reflection.py,sha256=AaBi0zi7GphOqnagV8N48GZHUuoT7743Pw3oc6_As6I,13700
|
|
528
528
|
tests/services/introspection/dependencies/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -558,10 +558,19 @@ tests/support/standard/test_services_std.py,sha256=U0hNF50YE4aLE3Z9yWB2awl9owFQR
|
|
|
558
558
|
tests/support/wrapper/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
559
559
|
tests/support/wrapper/test_services_wrapper_docdict.py,sha256=Q_qyqZodLiTQ6Pv9zILfIoZj6l-WPzNWuIoRf1GTGY0,7535
|
|
560
560
|
tests/testing/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
561
|
-
tests/testing/
|
|
562
|
-
tests/testing/
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
561
|
+
tests/testing/test_testing_unit.py,sha256=ZZM6RKxxg4TjANG3_Dy7aQpV60atQbCcSTlOdJZiDIs,4704
|
|
562
|
+
tests/testing/cases/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
563
|
+
tests/testing/cases/test_testing_asynchronous.py,sha256=gBcUyx1gmhulC-51BLtJOCwQOK6EMBaUws8eG8nxYOs,2218
|
|
564
|
+
tests/testing/cases/test_testing_synchronous.py,sha256=n7btUA-2cXPx-HLRfyI7YtVuJvcSuYVC-z843SktPCk,2427
|
|
565
|
+
tests/testing/entities/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
566
|
+
tests/testing/entities/test_testing_result.py,sha256=WtuoZarANSgcLeYSIU3heO-K8YORZkEgsQmHYPj1qPo,6734
|
|
567
|
+
tests/testing/enums/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
568
|
+
tests/testing/enums/test_testing_status.py,sha256=Jld1j4nn1IvK_Cok4k-BIRUg3DiB55LZVVxXEnHsTdo,2479
|
|
569
|
+
tests/testing/output/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
570
|
+
tests/testing/output/test_testing_dumper.py,sha256=QWuHEN-ImwiqNszqnsYUOJNwgZB1WM8ussw_DqFkfEY,1063
|
|
571
|
+
tests/testing/output/test_testing_printer.py,sha256=ov4u0FLHtdWt3onXDQr4-uaMMKE3QYZ4Z-K9LGOuUiM,1366
|
|
572
|
+
orionis-0.415.0.dist-info/METADATA,sha256=Vo3D_EQQFEbqYWWc-nexGpjncl_9bLjVGsWk_QH4YFE,4772
|
|
573
|
+
orionis-0.415.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
574
|
+
orionis-0.415.0.dist-info/top_level.txt,sha256=nkPWzvqkAzAmwPMPo3_iiUgzWMFOGfz6hVwdASslEGE,37
|
|
575
|
+
orionis-0.415.0.dist-info/zip-safe,sha256=frcCV1k9oG9oKj3dpUqdJg1PxRT2RSN_XKdLCPjaYaY,2
|
|
576
|
+
orionis-0.415.0.dist-info/RECORD,,
|
|
@@ -3,7 +3,7 @@ from orionis.container.enums.lifetimes import Lifetime
|
|
|
3
3
|
from orionis.container.exceptions.type import OrionisContainerTypeError
|
|
4
4
|
from orionis.test.cases.asynchronous import AsyncTestCase
|
|
5
5
|
|
|
6
|
-
class
|
|
6
|
+
class TestEntities(AsyncTestCase):
|
|
7
7
|
|
|
8
8
|
async def testBindingInitialization(self):
|
|
9
9
|
"""
|
|
File without changes
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
from orionis.test.cases.asynchronous import AsyncTestCase
|
|
2
|
+
import inspect
|
|
3
|
+
|
|
4
|
+
class TestAsyncTestCase(AsyncTestCase):
|
|
5
|
+
|
|
6
|
+
async def testMethodsExist(self):
|
|
7
|
+
"""
|
|
8
|
+
Checks if the AsyncTestCase class defines the required asynchronous lifecycle methods.
|
|
9
|
+
|
|
10
|
+
Parameters
|
|
11
|
+
----------
|
|
12
|
+
self : TestAsyncTestCase
|
|
13
|
+
The test case instance.
|
|
14
|
+
|
|
15
|
+
Returns
|
|
16
|
+
-------
|
|
17
|
+
None
|
|
18
|
+
This method does not return anything. It asserts the existence of required methods.
|
|
19
|
+
|
|
20
|
+
Notes
|
|
21
|
+
-----
|
|
22
|
+
This test ensures that the AsyncTestCase class contains all necessary asynchronous lifecycle methods
|
|
23
|
+
for proper setup and teardown in asynchronous test scenarios.
|
|
24
|
+
"""
|
|
25
|
+
required_methods = [
|
|
26
|
+
"asyncSetUp",
|
|
27
|
+
"asyncTearDown",
|
|
28
|
+
"onAsyncSetup",
|
|
29
|
+
"onAsyncTeardown"
|
|
30
|
+
]
|
|
31
|
+
# Assert that each required method exists in AsyncTestCase
|
|
32
|
+
for method_name in required_methods:
|
|
33
|
+
self.assertTrue(hasattr(AsyncTestCase, method_name), f"{method_name} does not exist")
|
|
34
|
+
|
|
35
|
+
async def testMethodsAreCoroutines(self):
|
|
36
|
+
"""
|
|
37
|
+
Checks that all required asynchronous lifecycle methods in AsyncTestCase are coroutine functions.
|
|
38
|
+
|
|
39
|
+
Parameters
|
|
40
|
+
----------
|
|
41
|
+
self : TestAsyncTestCase
|
|
42
|
+
The test case instance.
|
|
43
|
+
|
|
44
|
+
Returns
|
|
45
|
+
-------
|
|
46
|
+
None
|
|
47
|
+
This method does not return anything. It asserts that required methods are coroutine functions.
|
|
48
|
+
|
|
49
|
+
Notes
|
|
50
|
+
-----
|
|
51
|
+
This test verifies that the lifecycle methods are implemented as coroutine functions,
|
|
52
|
+
which is necessary for asynchronous execution in test cases.
|
|
53
|
+
"""
|
|
54
|
+
required_methods = [
|
|
55
|
+
"asyncSetUp",
|
|
56
|
+
"asyncTearDown",
|
|
57
|
+
"onAsyncSetup",
|
|
58
|
+
"onAsyncTeardown"
|
|
59
|
+
]
|
|
60
|
+
# Assert that each required method is a coroutine function
|
|
61
|
+
for method_name in required_methods:
|
|
62
|
+
method = getattr(AsyncTestCase, method_name)
|
|
63
|
+
self.assertTrue(inspect.iscoroutinefunction(method), f"{method_name} is not a coroutine function")
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
from orionis.test.cases.asynchronous import AsyncTestCase
|
|
2
|
+
from orionis.test.cases.synchronous import SyncTestCase
|
|
3
|
+
import inspect
|
|
4
|
+
|
|
5
|
+
class TestSyncTestCase(AsyncTestCase):
|
|
6
|
+
|
|
7
|
+
async def testHasMethods(self):
|
|
8
|
+
"""
|
|
9
|
+
Checks whether the SyncTestCase class defines the required synchronous lifecycle methods.
|
|
10
|
+
|
|
11
|
+
This test verifies the existence of the following methods in SyncTestCase:
|
|
12
|
+
- setUp: Prepares the test environment before each test.
|
|
13
|
+
- tearDown: Cleans up the test environment after each test.
|
|
14
|
+
- onSetup: Additional setup logic for tests.
|
|
15
|
+
- onTeardown: Additional teardown logic for tests.
|
|
16
|
+
|
|
17
|
+
Returns
|
|
18
|
+
-------
|
|
19
|
+
None
|
|
20
|
+
This method does not return any value. It performs assertions to validate the presence of required methods.
|
|
21
|
+
"""
|
|
22
|
+
# Assert that SyncTestCase has a setUp method
|
|
23
|
+
self.assertTrue(hasattr(SyncTestCase, "setUp"))
|
|
24
|
+
|
|
25
|
+
# Assert that SyncTestCase has a tearDown method
|
|
26
|
+
self.assertTrue(hasattr(SyncTestCase, "tearDown"))
|
|
27
|
+
|
|
28
|
+
# Assert that SyncTestCase has an onSetup method
|
|
29
|
+
self.assertTrue(hasattr(SyncTestCase, "onSetup"))
|
|
30
|
+
|
|
31
|
+
# Assert that SyncTestCase has an onTeardown method
|
|
32
|
+
self.assertTrue(hasattr(SyncTestCase, "onTeardown"))
|
|
33
|
+
|
|
34
|
+
async def testMethodsAreNotCoroutines(self):
|
|
35
|
+
"""
|
|
36
|
+
Checks that the lifecycle methods of SyncTestCase are regular functions and not coroutine functions.
|
|
37
|
+
|
|
38
|
+
This test ensures that the following methods are synchronous:
|
|
39
|
+
- setUp
|
|
40
|
+
- tearDown
|
|
41
|
+
- onSetup
|
|
42
|
+
- onTeardown
|
|
43
|
+
|
|
44
|
+
Returns
|
|
45
|
+
-------
|
|
46
|
+
None
|
|
47
|
+
This method does not return any value. It performs assertions to confirm that the methods are not coroutine functions.
|
|
48
|
+
"""
|
|
49
|
+
# Assert that setUp is not a coroutine function
|
|
50
|
+
self.assertFalse(inspect.iscoroutinefunction(SyncTestCase.setUp))
|
|
51
|
+
|
|
52
|
+
# Assert that tearDown is not a coroutine function
|
|
53
|
+
self.assertFalse(inspect.iscoroutinefunction(SyncTestCase.tearDown))
|
|
54
|
+
|
|
55
|
+
# Assert that onSetup is not a coroutine function
|
|
56
|
+
self.assertFalse(inspect.iscoroutinefunction(SyncTestCase.onSetup))
|
|
57
|
+
|
|
58
|
+
# Assert that onTeardown is not a coroutine function
|
|
59
|
+
self.assertFalse(inspect.iscoroutinefunction(SyncTestCase.onTeardown))
|
|
File without changes
|
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
from orionis.test.cases.asynchronous import AsyncTestCase
|
|
2
|
+
from orionis.test.entities.result import TestResult
|
|
3
|
+
from orionis.test.enums import TestStatus
|
|
4
|
+
|
|
5
|
+
class TestTestingResult(AsyncTestCase):
|
|
6
|
+
|
|
7
|
+
async def testDefaultValues(self) -> None:
|
|
8
|
+
"""
|
|
9
|
+
Ensures that optional fields in a TestResult instance are set to None when not provided during initialization.
|
|
10
|
+
|
|
11
|
+
This test checks the default behavior for the following optional fields:
|
|
12
|
+
- error_message
|
|
13
|
+
- traceback
|
|
14
|
+
- class_name
|
|
15
|
+
- method
|
|
16
|
+
- module
|
|
17
|
+
- file_path
|
|
18
|
+
|
|
19
|
+
The method asserts that each of these fields is None after instantiating TestResult with only required arguments.
|
|
20
|
+
|
|
21
|
+
Parameters
|
|
22
|
+
----------
|
|
23
|
+
self : TestTestingResult
|
|
24
|
+
The test case instance.
|
|
25
|
+
|
|
26
|
+
Returns
|
|
27
|
+
-------
|
|
28
|
+
None
|
|
29
|
+
This method does not return any value. It performs assertions to validate default field values.
|
|
30
|
+
|
|
31
|
+
Notes
|
|
32
|
+
-----
|
|
33
|
+
This test verifies that the TestResult dataclass correctly initializes optional fields to None when they are omitted.
|
|
34
|
+
"""
|
|
35
|
+
# Create a TestResult instance with only required fields
|
|
36
|
+
result = TestResult(
|
|
37
|
+
id=1,
|
|
38
|
+
name="Sample Test",
|
|
39
|
+
status=TestStatus.PASSED,
|
|
40
|
+
execution_time=0.5
|
|
41
|
+
)
|
|
42
|
+
# Assert that all optional fields are set to None by default
|
|
43
|
+
self.assertIsNone(result.error_message)
|
|
44
|
+
self.assertIsNone(result.traceback)
|
|
45
|
+
self.assertIsNone(result.class_name)
|
|
46
|
+
self.assertIsNone(result.method)
|
|
47
|
+
self.assertIsNone(result.module)
|
|
48
|
+
self.assertIsNone(result.file_path)
|
|
49
|
+
|
|
50
|
+
async def testRequiredFields(self) -> None:
|
|
51
|
+
"""
|
|
52
|
+
Validates that TestResult enforces the presence of all required fields during initialization.
|
|
53
|
+
|
|
54
|
+
This test attempts to instantiate TestResult without required fields and expects a TypeError to be raised.
|
|
55
|
+
|
|
56
|
+
Parameters
|
|
57
|
+
----------
|
|
58
|
+
self : TestTestingResult
|
|
59
|
+
The test case instance.
|
|
60
|
+
|
|
61
|
+
Returns
|
|
62
|
+
-------
|
|
63
|
+
None
|
|
64
|
+
This method does not return any value. It performs assertions to validate required field enforcement.
|
|
65
|
+
|
|
66
|
+
Notes
|
|
67
|
+
-----
|
|
68
|
+
- Attempts to instantiate TestResult with no arguments.
|
|
69
|
+
- Attempts to instantiate TestResult missing the 'id' field.
|
|
70
|
+
- Expects a TypeError to be raised in both cases.
|
|
71
|
+
"""
|
|
72
|
+
# Attempt to create TestResult with no arguments; should raise TypeError
|
|
73
|
+
with self.assertRaises(TypeError):
|
|
74
|
+
TestResult() # Missing all required fields
|
|
75
|
+
|
|
76
|
+
# Attempt to create TestResult missing the 'id' field; should raise TypeError
|
|
77
|
+
with self.assertRaises(TypeError):
|
|
78
|
+
TestResult(
|
|
79
|
+
name="Sample Test",
|
|
80
|
+
status=TestStatus.PASSED,
|
|
81
|
+
execution_time=0.5
|
|
82
|
+
)
|
|
83
|
+
|
|
84
|
+
async def testImmutable(self) -> None:
|
|
85
|
+
"""
|
|
86
|
+
Tests the immutability of TestResult instances.
|
|
87
|
+
|
|
88
|
+
Ensures that TestResult, implemented as a frozen dataclass, does not allow modification of its attributes after instantiation.
|
|
89
|
+
|
|
90
|
+
Parameters
|
|
91
|
+
----------
|
|
92
|
+
self : TestTestingResult
|
|
93
|
+
The test case instance.
|
|
94
|
+
|
|
95
|
+
Returns
|
|
96
|
+
-------
|
|
97
|
+
None
|
|
98
|
+
This method does not return any value. It performs assertions to validate immutability.
|
|
99
|
+
|
|
100
|
+
Raises
|
|
101
|
+
------
|
|
102
|
+
Exception
|
|
103
|
+
If an attempt is made to modify an attribute of a frozen TestResult instance.
|
|
104
|
+
|
|
105
|
+
Notes
|
|
106
|
+
-----
|
|
107
|
+
Attempts to modify the 'name' attribute of a TestResult instance and expects an exception to be raised.
|
|
108
|
+
"""
|
|
109
|
+
# Create a TestResult instance
|
|
110
|
+
result = TestResult(
|
|
111
|
+
id=1,
|
|
112
|
+
name="Sample Test",
|
|
113
|
+
status=TestStatus.PASSED,
|
|
114
|
+
execution_time=0.5
|
|
115
|
+
)
|
|
116
|
+
# Attempt to modify an attribute; should raise an exception due to immutability
|
|
117
|
+
with self.assertRaises(Exception):
|
|
118
|
+
result.name = "Modified Name"
|
|
119
|
+
|
|
120
|
+
async def testStatusValues(self) -> None:
|
|
121
|
+
"""
|
|
122
|
+
Verifies that all possible values of the TestStatus enum can be assigned to the status field of a TestResult instance.
|
|
123
|
+
|
|
124
|
+
Iterates over each TestStatus value, assigns it to a TestResult, and asserts that the status is set correctly.
|
|
125
|
+
|
|
126
|
+
Parameters
|
|
127
|
+
----------
|
|
128
|
+
self : TestTestingResult
|
|
129
|
+
The test case instance.
|
|
130
|
+
|
|
131
|
+
Returns
|
|
132
|
+
-------
|
|
133
|
+
None
|
|
134
|
+
This method does not return any value. It performs assertions to validate status assignment.
|
|
135
|
+
|
|
136
|
+
Notes
|
|
137
|
+
-----
|
|
138
|
+
This test ensures that the status field in TestResult supports all enum values defined in TestStatus.
|
|
139
|
+
"""
|
|
140
|
+
# Iterate through all possible TestStatus values
|
|
141
|
+
for status in TestStatus:
|
|
142
|
+
# Create a TestResult instance with the current status
|
|
143
|
+
result = TestResult(
|
|
144
|
+
id=1,
|
|
145
|
+
name="Status Test",
|
|
146
|
+
status=status,
|
|
147
|
+
execution_time=0.1
|
|
148
|
+
)
|
|
149
|
+
# Assert that the status field matches the assigned value
|
|
150
|
+
self.assertEqual(result.status, status)
|
|
151
|
+
|
|
152
|
+
async def testErrorFields(self) -> None:
|
|
153
|
+
"""
|
|
154
|
+
Verifies that the error_message and traceback fields are correctly stored in the TestResult object when provided.
|
|
155
|
+
|
|
156
|
+
This test initializes a TestResult with error_message and traceback values and asserts that they are set as expected.
|
|
157
|
+
|
|
158
|
+
Parameters
|
|
159
|
+
----------
|
|
160
|
+
self : TestTestingResult
|
|
161
|
+
The test case instance.
|
|
162
|
+
|
|
163
|
+
Returns
|
|
164
|
+
-------
|
|
165
|
+
None
|
|
166
|
+
This method does not return any value. It performs assertions to validate error field assignment.
|
|
167
|
+
|
|
168
|
+
Notes
|
|
169
|
+
-----
|
|
170
|
+
This test ensures that error-related fields are properly assigned and retrievable from the TestResult instance.
|
|
171
|
+
"""
|
|
172
|
+
error_msg = "Test failed"
|
|
173
|
+
traceback = "Traceback info"
|
|
174
|
+
# Create a TestResult instance with error fields
|
|
175
|
+
result = TestResult(
|
|
176
|
+
id=1,
|
|
177
|
+
name="Failing Test",
|
|
178
|
+
status=TestStatus.FAILED,
|
|
179
|
+
execution_time=0.2,
|
|
180
|
+
error_message=error_msg,
|
|
181
|
+
traceback=traceback
|
|
182
|
+
)
|
|
183
|
+
# Assert that error_message and traceback fields are set correctly
|
|
184
|
+
self.assertEqual(result.error_message, error_msg)
|
|
185
|
+
self.assertEqual(result.traceback, traceback)
|
|
File without changes
|