|
UniSet 2.45.1
|
Классы | |
| class | TestFBInstanceCodegen |
| class | TestFBCallCodegen |
| class | TestFBFieldAccessCodegen |
| class | TestFunctionBlockDeclarationCodegen |
Функции | |
| IRProgram | _make_program (str name="Main", list|None inputs=None, list|None outputs=None, list|None locals_=None, list|None fb_instances=None, list|None body=None, list|None function_blocks=None) |
| SensorMapping | _make_mapping (list[SensorEntry]|None inputs=None, list[SensorEntry]|None outputs=None) |
Tests for function block code generation (codegen.py). Tests cover: - IRFBInstance emits correct constructor: new TON(pt), new CTU(pv), new RS() - IRFBCall emits correct update() calls with args in correct order - IRFieldAccess on FB emits obj.field - All 10 standard FBs generate correct constructor and update() calls - FUNCTION_BLOCK declaration emits JS class with constructor and execute()
|
protected |
Helper to create a SensorMapping with defaults.
|
protected |
Helper to create an IRProgram with defaults.