(t *testing.T)
| 2901 | } |
| 2902 | |
| 2903 | func TestFindFrame(t *testing.T) { |
| 2904 | frame := mustNewExecutionFrame(t, EmptyActivation()) |
| 2905 | defer frame.Close() |
| 2906 | |
| 2907 | tests := []struct { |
| 2908 | name string |
| 2909 | act Activation |
| 2910 | }{ |
| 2911 | { |
| 2912 | name: "nested wrapper", |
| 2913 | act: &testActivationWrapper{Activation: &testActivationWrapper{Activation: frame, name: "w1"}, name: "w2"}, |
| 2914 | }, |
| 2915 | { |
| 2916 | name: "parent hierarchy", |
| 2917 | act: &parentActivationWrapper{parent: frame}, |
| 2918 | }, |
| 2919 | } |
| 2920 | for _, tc := range tests { |
| 2921 | t.Run(tc.name, func(t *testing.T) { |
| 2922 | found := findFrame(tc.act) |
| 2923 | if found != frame { |
| 2924 | t.Errorf("findFrame() = %v, wanted %v", found, frame) |
| 2925 | } |
| 2926 | }) |
| 2927 | } |
| 2928 | } |
| 2929 | |
| 2930 | func TestObservableInterpretable(t *testing.T) { |
| 2931 | obsInt := &ObservableInterpretable{InterpretableV2: NewConstValue(12, types.True)} |
nothing calls this directly
no test coverage detected