(t *testing.T)
| 2831 | } |
| 2832 | |
| 2833 | func TestFindFrame(t *testing.T) { |
| 2834 | frame := mustNewExecutionFrame(t, EmptyActivation()) |
| 2835 | defer frame.Close() |
| 2836 | |
| 2837 | tests := []struct { |
| 2838 | name string |
| 2839 | act Activation |
| 2840 | }{ |
| 2841 | { |
| 2842 | name: "nested wrapper", |
| 2843 | act: &testActivationWrapper{Activation: &testActivationWrapper{Activation: frame, name: "w1"}, name: "w2"}, |
| 2844 | }, |
| 2845 | { |
| 2846 | name: "parent hierarchy", |
| 2847 | act: &parentActivationWrapper{parent: frame}, |
| 2848 | }, |
| 2849 | } |
| 2850 | for _, tc := range tests { |
| 2851 | t.Run(tc.name, func(t *testing.T) { |
| 2852 | found := findFrame(tc.act) |
| 2853 | if found != frame { |
| 2854 | t.Errorf("findFrame() = %v, wanted %v", found, frame) |
| 2855 | } |
| 2856 | }) |
| 2857 | } |
| 2858 | } |
| 2859 | |
| 2860 | func TestObservableInterpretable(t *testing.T) { |
| 2861 | obsInt := &ObservableInterpretable{InterpretableV2: NewConstValue(12, types.True)} |
nothing calls this directly
no test coverage detected