Testing Infrastructure
Test Coverage & File Architecture
ZepraBrowser Testing Architecture
The ZepraBrowser project maintains a massive test suite scaling identically with core development. Test components are broadly organized into native C++ integration tests handling core DOM and browser integration alongside dedicated ZepraScript test environments.
šÆ Overall Test Tree
The core test/ directory coordinates integration testing for networking, crypto, DOM, garbage collection algorithms, and rendering engines. 26 total directories governing 108 test files exist today.
zeprabrowser/test/
āāā browser_test_runner.cpp # Central Test Orchestration
āāā CMakeLists.txt # CMake Build Setup
āāā dom_test.html # HTML Execution Tests
āāā nxcrypto_tests.cpp # Native Cryptography Integration
āāā nxhttp_security_test.cpp # HTTP Protocol & Security Validation
āāā nxhttp_tests.cpp # Native networking assertions
āāā smart_ram_allocator_test.cpp # RAM Memory Limiting Validation
āāā test_basic.cpp # Core Application Base Setup
āāā visual_test_nxsvg.cpp # NX SVG Native Rendering Validation
āāā demos/ # App GUI Emulation
ā āāā zepraEngine
ā āāā examples
ā ā āāā gl_demo.cpp # Direct OpenGL Hardware Benchmarks
ā ā āāā webgl_demo.cpp # WebGL Native Translation Sandbox
ā ā āāā zepra_window_demo.cpp # Full Desktop Application Pipeline Sandbox
ā āāā src
ā āāā zepra_browser_app.cpp
ā āāā zepra_browser_nxgfx.cpp
āāā webexstest/ # Extensions & Threading Tests
ā āāā connectest
ā āāā crawlinf
āāā htmltest/
ā āāā test_css_cascade.html # Full HTML CSS cascade assertions
āāā layouttest/
ā āāā test_layout.html # Browser reflow verification
āāā jstest/
āāā test_javascript.html # Inline JS injection testingšļø Deep Garbage Collection Validation
Memory integrity and deterministic collection is pivotal to ZepraScript and the Browser DOM bridging functionality. Memory assertions evaluate isolated boundaries continuously:
gc_age_table_test.cpp- Validating object longevity metrics in the Nursery.gc_barrier_test.cpp- Multi-tier write barriers cross-generational bounds.gc_capacity_test.cpp- Strict memory cap boundary checks to guarantee application RAM footprint thresholds.gc_card_table_test.cpp- High-speed Card Table manipulation for large object heaps.gc_evacuation_test.cpp- Live memory defragmentation correctness inside the Tenured space.gc_free_list_test.cpp- Quick allocation pipeline tracking validation.gc_nursery_test.cpp- Ephemeral object rapid garbage sweep logic testing.gc_object_header_test.cpp- Verifying 64-bit word tagging and headers aren't mutating improperly.gc_pretenure_test.cpp- Validating enormous object memory tracking mechanisms straight to tenured heap spaces.gc_root_set_test.cpp- Testing the internal compiler AST, stack registers, global execution context objects root tracking.gc_scheduler_test.cpp- Ensures garbage collection timing mechanics halt WebCore engines appropriately.gc_snapshot_test.cpp- Validating Heap Dump mechanics utilized via Developer Tools Performance trackers.gc_tlab_test.cpp- Thread-Local Allocation Buffers locking validations.gc_wb_buffer_test.cpp- Concurrent generational store tracking logic.gc_weak_test.cpp- TestingWeakMap/WeakRefzero-reference cleanup checks.
š¦ ZepraScript Engine Test Suite
ZepraScript maintains a fully modularized test suite encompassing exactly 72 tests focusing on standalone logic, compliance with Test262 standard ECMA validations, JIT correctness, Interpreter boundaries, WASM translation, and Core Web API bridging correctness.
zeprabrowser/test/zeprascript/
āāā ZepraScriptTestRunner.cpp # Master ZepraScript Engine Wrapper Driver
āāā CMakeLists.txt
āāā unit/ # Deep Internal C++ Assertions
ā āāā ast_tests.cpp # AST Pipeline Evaluation
ā āāā async_tests.cpp # Async / Await Event Loop Ticking
ā āāā browser_integration_tests.cpp # WebCore Native Extension C++ Bridging
ā āāā builtin_tests.cpp # Native Javascript Base Utilities C++ validation
ā āāā class_tests.cpp # JS Class and ES6 prototype tree building
ā āāā gc_concurrent_stress_test.cpp # GC Thread Starving Engine Benchmarks
ā āāā gc_tests.cpp # Standalone Engine specific memory boundaries
ā āāā generator_tests.cpp # JS State Machine yielding and execution
ā āāā jit_stress_test.cpp # Extensive Just-In-Time Heat Testing Logic
ā āāā JITTests.cpp # Strict JIT Tier Execution Assertion Checks
ā āāā lexer_tests.cpp # Raw UTF-8 to Token Stream Parsing Checks
ā āāā parser_tests.cpp # Heavy AST Evaluation Parsing Tests
ā āāā robustness_tests.cpp # Engine failure crash protections
ā āāā runtime_tests.cpp # Bytecode Virtual Machine Native Evaluation
ā āāā RuntimeTests.cpp # Native Core Execution Evaluation Boundaries
ā āāā sandbox_tests.cpp # Site-Isolation Threat Protection and Jailbreak testing
ā āāā stress_tests.cpp # Memory and Compute Timeout Validation Checks
ā āāā url_tests.cpp # Native C++ Network Layer Routing Checks
ā āāā value_tests.cpp # JS Value NaN Tagging Boundaries inside Registers
ā āāā vm_stress_test.cpp # Extreme Operations Pipeline Bottleneck Validations
ā āāā vm_tests.cpp # Raw Execution Pipeline Validations
ā āāā wasm_tests.cpp # Assembly parsing and runtime limits
ā āāā WASMTests.cpp # Native C++ Engine interaction to WASM Modules
ā āāā build_comprehensive_tests.cpp # Integration with CLI tooling
ā āāā zir_tests.cpp # Zepra Intermediate Representation (Bytecode) Parsing Check
āāā spec/ # ECMA Specification Tools
ā āāā EngineIntrospection.h
ā āāā SpecTestRunner.cpp
ā āāā SpecTestRunner.h
ā āāā Test262Harness.cpp
ā āāā Test262Harness.h
āāā test262/ # Raw ECMA Code Compliance Scripts
ā āāā basic_compliance.js
ā āāā extended_compliance.js
āāā scripts/ # Engine Standard Sanity Checking
ā āāā 01_variables.js
ā āāā 02_arithmetic.js
ā āāā 03_strings.js
ā āāā 04_control_flow.js
ā āāā 05_functions.js
ā āāā 06_objects.js
ā āāā 07_arrays.js
ā āāā 08_classes.js
ā āāā 09_error_handling.js
ā āāā 10_operators.js
āāā runtime/
ā āāā smart_ram_allocator_test.cpp
ā āāā tab_lifecycle_test.cpp # Browser Architecture Site Isolation Pipeline checks
āāā js/ # Advanced Deep JS Verification
ā āāā api_audit.js
ā āāā async_test.js
ā āāā builtin_tests.js
ā āāā core_tests.js
ā āāā es6_tests.js
ā āāā full_compliance_test.js
ā āāā p1_api_test.js
ā āāā simple_test.js
āāā jit/
ā āāā jit_correctness_test.cpp # Confirm machine code execution is equivalent to bytecode results
āāā interpreter/
ā āāā interpreter_edge_cases_test.cpp # Ensure massive objects and call stacks do not break the C++ frames
āāā integration/ # Web API Validation Checks
ā āāā browser_vm_integration_test.cpp
ā āāā fetch_tests.cpp # Network bridging JS -> C++ -> OS checks
ā āāā indexeddb_tests.cpp # Persistent File System Disk Sync validation
ā āāā js_execution_test.cpp
ā āāā module_tests.cpp # Importing JS/TS inside native contexts
ā āāā promise_tests.cpp # Heavy native promise multi-threaded coordination
āāā gc/
ā āāā gc_generational_test.cpp
ā āāā gc_stress_test.cpp
ā āāā gc_tab_isolation_test.cpp # Checks Tab Cross-Communication memory protections are absolute
āāā browser_apis/
ā āāā fetch_test.cpp
ā āāā secure_storage_test.cpp
āāā benchmarks/ # Heavy Node versus Zepra Script Engine Processing tests
ā āāā array_ops.js
ā āāā fibonacci.js
āāā wasm/
āāā wasm_execution_test.cpp # High performance WASM assembly interaction module validationsNote: 14 directories, 72 files strictly within the ZepraScript runtime module.
Last Updated: 2026-03-15
Version: v0.01 Alpha
Maintainer: Swanaya