factory_utilities_tests
AUTO-GENERATED FILE – DO NOT EDIT MANUALLY
Source File: /addons/grid_building/test/utilities/helpers/factory_utilities_tests.gd
Extends: GdUnitTestSuite
Properties
- Property:
runner: GdUnitSceneRunner
Private Properties
- Property:
_created_objects: Array[Object] = [] (private) - Property:
_test_start_time: int (private) - Property:
_max_test_duration_ms: int = TEST_TIMEOUT_MS (private)
Constants
- Constant:
TEST_TIMEOUT_MS: int = 5000 # 5 second timeout - Constant:
MEMORY_TOLERANCE_BYTES: int = 1024 * 1024 # 1MB memory tolerance - Constant:
PERFORMANCE_THRESHOLD_MS: int = 100 # Performance threshold for operations - Constant:
FACTORY_CREATION_TIMEOUT_MS: int = 500 # Factory creation timeout - Constant:
STRESS_TEST_ITERATIONS: int = 10 # Number of iterations for stress tests - Constant:
SUCCESS_RATE_THRESHOLD: float = 0.8 # Minimum success rate (80%) - Constant:
TILE_OPERATION_COUNT: int = 10 # Number of tile operations for performance tests - Constant:
VALIDATION_TEST_POSITION: Vector2 = Vector2(200, 300) # Standard test position - Constant:
PERSISTENCE_TEST_POSITION: Vector2 = Vector2(123, 456) # Position for persistence tests - Constant:
POSITIONER_TEST_POSITION: Vector2 = Vector2(100, 100) # Position for positioner tests - Constant:
MINIMUM_COLLISION_SHAPES: int = 1 # Minimum shapes required for collision objects - Constant:
MINIMUM_ENVIRONMENT_COUNT: int = 5 # Minimum environments for stress test validation - Constant:
MINIMUM_TILE_SOURCES: int = 1 # Minimum tile sources for valid TileSet - Constant:
EXPECTED_RULE_COUNT: int = 3 # Expected number of rule types - Constant:
REQUIRED_PLACEMENT_COMPONENTS: Array[String] = [ - Constant:
REQUIRED_RULE_COMPONENTS: Array[String] = [ - Constant:
ESSENTIAL_SYSTEMS_COMPONENTS: Array[String] = [
Public Methods
before
before_test
after
after_test
track_object
1
| track_object(obj: Object) -> Object
|
assert_object_not_null
1
2
3
4
| assert_object_not_null(
obj: Object,
context: String
) -> void
|
Helper Methods for Common Test Patterns
1
2
3
4
5
| assert_performance_threshold(
actual_ms: int,
operation: String,
threshold: int = PERFORMANCE_THRESHOLD_MS
) -> void
|
assert_memory_usage_change
1
2
3
4
5
| assert_memory_usage_change(
initial: int,
final: int,
operation: String
) -> void
|
validate_environment_components
1
2
3
4
5
| validate_environment_components(
env: Variant,
required_components: Array[String],
context: String
) -> void
|
create_indicator_test_environment_with_tracking
1
| create_indicator_test_environment_with_tracking() -> CollisionTestEnvironment
|
test_test_node2d_factory_robustness
1
| test_test_node2d_factory_robustness() -> void
|
test_test_tilemap_factory_validation
1
| test_test_tilemap_factory_validation() -> void
|
test_composition_container_factory_robustness
1
| test_composition_container_factory_robustness() -> void
|
test_placement_system_factory_layer_comprehensive
1
| test_placement_system_factory_layer_comprehensive() -> void
|
test_rule_indicator_factory_layer_dependencies
1
| test_rule_indicator_factory_layer_dependencies() -> void
|
test_factory_edge_cases_invalid_configurations
1
| test_factory_edge_cases_invalid_configurations() -> void
|
1
| test_factory_performance_and_cleanup() -> void
|
test_factory_memory_safety
1
| test_factory_memory_safety() -> void
|
test_factory_stress_and_recovery
1
| test_factory_stress_and_recovery() -> void
|
test_factory_error_recovery
1
| test_factory_error_recovery() -> void
|
test_factory_memory_cleanup
1
| test_factory_memory_cleanup() -> void
|
test_collision_rule_validation
1
| test_collision_rule_validation() -> void
|
test_validation_out_of_bounds
1
| test_validation_out_of_bounds() -> void
|
test_factory_method_redundancy_detection
1
| test_factory_method_redundancy_detection() -> void
|
Private Methods
_track_object
1
| _track_object(obj: Object) -> Object
|
Flags: private
_assert_object_not_null
1
2
3
4
| _assert_object_not_null(
obj: Object,
context: String
) -> void
|
Flags: private
1
2
3
4
5
| _assert_performance_threshold(
actual_ms: int,
operation: String,
threshold: int = PERFORMANCE_THRESHOLD_MS
) -> void
|
Flags: private
_assert_memory_usage_change
1
2
3
4
5
| _assert_memory_usage_change(
initial: int,
final: int,
operation: String
) -> void
|
Flags: private
_validate_environment_components
1
2
3
4
5
| _validate_environment_components(
env: Variant,
required_components: Array[String],
context: String
) -> void
|
Flags: private
_create_test_node_with_tracking
1
| _create_test_node_with_tracking() -> Node2D
|
Flags: private
_create_test_container_with_tracking
1
| _create_test_container_with_tracking() -> GBCompositionContainer
|
Flags: private
_create_test_tilemap_with_tracking
1
| _create_test_tilemap_with_tracking() -> TileMapLayer
|
Flags: private
_create_indicator_test_environment_with_tracking
1
| _create_indicator_test_environment_with_tracking() -> CollisionTestEnvironment
|
Flags: private
_track_object_from_dict
1
| _track_object_from_dict(dict: Dictionary) -> void
|
Flags: private
Helper function to track objects from dictionary for cleanup
Grid Building v5.0.8 | Generated 24/05/2026