docs: annotate Foundry source and deployment lifecycle in Chinese [skip ci]
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
// 懒读取回归通过注入快照计数 Load,证明范围选择没有隐式扫描无关子树。
|
||||
package platform
|
||||
|
||||
import (
|
||||
@@ -7,6 +8,7 @@ import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
// readerFromSnapshots 从快照 subgraph 字段建立测试父关系,并给实际 Load 调用计数,不预填 reader 缓存。
|
||||
func readerFromSnapshots(snapshots map[string]canvasSnapshot, loads map[string]int) *canvasAIReader {
|
||||
parents := map[string]subgraphRelation{}
|
||||
for board, snapshot := range snapshots {
|
||||
@@ -32,6 +34,8 @@ func readerFromSnapshots(snapshots map[string]canvasSnapshot, loads map[string]i
|
||||
return subgraphRelation{}, sql.ErrNoRows
|
||||
}}
|
||||
}
|
||||
|
||||
// TestAIReaderDoesNotLoadUnrelatedSubgraphs 在含 499 个无关 frame 的根上运行,传播开/关都只能加载根一次。
|
||||
func TestAIReaderDoesNotLoadUnrelatedSubgraphs(t *testing.T) {
|
||||
nodes := []any{map[string]any{"id": "a", "type": "material", "position": map[string]any{"x": 0, "y": 0}, "data": map[string]any{"kind": "text", "title": "A", "text": "input", "ai": map[string]any{"enabled": true, "modelId": "fixture", "prompt": "transform", "parameters": map[string]any{}}}}}
|
||||
for i := 0; i < 499; i++ {
|
||||
@@ -50,6 +54,8 @@ func TestAIReaderDoesNotLoadUnrelatedSubgraphs(t *testing.T) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// TestAIReaderResolvesChildOutputAndFrozenPredecessor 从孩子 b 跨父端口传播到 outside,冻结 a 输入,同时不加载空兄弟子图。
|
||||
func TestAIReaderResolvesChildOutputAndFrozenPredecessor(t *testing.T) {
|
||||
raw := memberFixture(t)
|
||||
child := "11111111-1111-4111-8111-111111111111"
|
||||
|
||||
Reference in New Issue
Block a user