@@ -52,7 +52,6 @@ func TestNestedVariableSource(t *testing.T) {
5252 } {
5353 t .Run (tt .name , func (t * testing.T ) {
5454 ctx := context .Background ()
55- mockEntitySource := input .NewCacheQuerier (map [deppy.Identifier ]input.Entity {})
5655
5756 nestedSource := variablesources.NestedVariableSource {}
5857 for i := range tt .varSources {
@@ -70,7 +69,7 @@ func TestNestedVariableSource(t *testing.T) {
7069 })
7170 }
7271
73- variables , err := nestedSource .GetVariables (ctx , mockEntitySource )
72+ variables , err := nestedSource .GetVariables (ctx )
7473 if tt .wantErr != "" {
7574 assert .EqualError (t , err , tt .wantErr )
7675 } else {
@@ -82,15 +81,14 @@ func TestNestedVariableSource(t *testing.T) {
8281
8382 t .Run ("error from a nested constructor" , func (t * testing.T ) {
8483 ctx := context .Background ()
85- mockEntitySource := input .NewCacheQuerier (map [deppy.Identifier ]input.Entity {})
8684
8785 nestedSource := variablesources.NestedVariableSource {
8886 func (inputVariableSource input.VariableSource ) (input.VariableSource , error ) {
8987 return nil , errors .New ("fake error from a constructor" )
9088 },
9189 }
9290
93- variables , err := nestedSource .GetVariables (ctx , mockEntitySource )
91+ variables , err := nestedSource .GetVariables (ctx )
9492 assert .EqualError (t , err , "fake error from a constructor" )
9593 assert .Nil (t , variables )
9694 })
@@ -123,10 +121,9 @@ func TestSliceVariableSource(t *testing.T) {
123121 } {
124122 t .Run (tt .name , func (t * testing.T ) {
125123 ctx := context .Background ()
126- mockEntitySource := input .NewCacheQuerier (map [deppy.Identifier ]input.Entity {})
127124
128125 sliceSource := variablesources .SliceVariableSource (tt .varSources )
129- variables , err := sliceSource .GetVariables (ctx , mockEntitySource )
126+ variables , err := sliceSource .GetVariables (ctx )
130127 if tt .wantErr != "" {
131128 assert .EqualError (t , err , tt .wantErr )
132129 } else {
@@ -145,7 +142,7 @@ type mockVariableSource struct {
145142 fakeError error
146143}
147144
148- func (m * mockVariableSource ) GetVariables (ctx context.Context , entitySource input. EntitySource ) ([]deppy.Variable , error ) {
145+ func (m * mockVariableSource ) GetVariables (ctx context.Context ) ([]deppy.Variable , error ) {
149146 if m .fakeError != nil {
150147 return nil , m .fakeError
151148 }
@@ -154,7 +151,7 @@ func (m *mockVariableSource) GetVariables(ctx context.Context, entitySource inpu
154151 return m .fakeVariables , nil
155152 }
156153
157- nestedVars , err := m .inputVariableSource .GetVariables (ctx , entitySource )
154+ nestedVars , err := m .inputVariableSource .GetVariables (ctx )
158155 if err != nil {
159156 return nil , err
160157 }
0 commit comments