class Lapis::Test::ColdBootContext

Overview

Encapsulates a dedicated, completely isolated ephemeral Godot engine environment for tests requiring cold boot execution without polluting the shared engine or project.

Defined in:

libgodot/testing.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(test_name : String) #

Instance Method Detail

def cleanup : Void #

Guarantees that ephemeral sandbox files are completely wiped upon completion.


def godot_exe : String #

def run_isolated_project(args : Array(String) = [] of String) : TestResult #

Executes the isolated project in headless runtime mode


def run_isolated_script(script_rel_path : String, args : Array(String) = [] of String) : TestResult #

Runs an isolated script in a dedicated headless Godot process with complete environment isolation.


def sandbox_dir : String #

def test_name : String #

def write_file(rel_path : String, content : String) : String #

Writes an isolated scene, resource, or configuration file into the sandbox.


def write_script(rel_path : String, code : String) : String #

Writes an isolated test script into the ephemeral sandbox. This code only exists for this test and will NEVER be replicated across the project.