@@ -129,13 +129,13 @@ static void test_audio_pipeline_complete_connect_upstream_ignore_source
129129 */
130130 list_item_append (& result .sched_comp -> bsource_list ,
131131 & test_data -> b1 -> sink_list );
132- test_data -> b1 -> sink = result .sched_comp ;
133- test_data -> b1 -> source = test_data -> second ;
132+ comp_buffer_set_sink_component ( test_data -> b1 , result .sched_comp ) ;
133+ comp_buffer_set_source_component ( test_data -> b1 , test_data -> second ) ;
134134 list_item_append (& test_data -> b1 -> source_list ,
135135 & test_data -> second -> bsink_list );
136136 list_item_append (& test_data -> second -> bsource_list ,
137137 & test_data -> b2 -> sink_list );
138- test_data -> b2 -> sink = test_data -> second ;
138+ comp_buffer_set_sink_component ( test_data -> b2 , test_data -> second ) ;
139139
140140 /*Testing component*/
141141 pipeline_complete (& result , test_data -> first , test_data -> second );
@@ -156,14 +156,11 @@ static void test_audio_pipeline_complete_connect_downstream_full(void **state)
156156 /*Connecting first comp to second*/
157157 comp = & test_data -> second -> ipc_config ;
158158 comp -> pipeline_id = PIPELINE_ID_SAME ;
159- list_item_append (& result .sched_comp -> bsink_list ,
160- & test_data -> b1 -> source_list );
161- test_data -> b1 -> source = result .sched_comp ;
162- list_item_append (& test_data -> b1 -> source_list ,
163- & result .sched_comp -> bsink_list );
164- test_data -> b1 -> sink = test_data -> second ;
165- list_item_append (& test_data -> b1 -> sink_list ,
166- & test_data -> second -> bsource_list );
159+ list_item_append (& result .sched_comp -> bsink_list , & test_data -> b1 -> source_list );
160+ comp_buffer_set_source_component (test_data -> b1 , result .sched_comp );
161+ list_item_append (& test_data -> b1 -> source_list , & result .sched_comp -> bsink_list );
162+ comp_buffer_set_sink_component (test_data -> b1 , test_data -> second );
163+ list_item_append (& test_data -> b1 -> sink_list , & test_data -> second -> bsource_list );
167164
168165 test_data -> first -> frames = 0 ;
169166 test_data -> second -> frames = 0 ;
@@ -189,8 +186,8 @@ static void test_audio_pipeline_complete_connect_upstream_full(void **state)
189186 comp -> pipeline_id = PIPELINE_ID_SAME ;
190187 list_item_append (& result .sched_comp -> bsource_list ,
191188 & test_data -> b1 -> sink_list );
192- test_data -> b1 -> sink = test_data -> first ;
193- test_data -> b1 -> source = test_data -> second ;
189+ comp_buffer_set_sink_component ( test_data -> b1 , test_data -> first ) ;
190+ comp_buffer_set_source_component ( test_data -> b1 , test_data -> second ) ;
194191
195192 /*Testing component*/
196193 pipeline_complete (& result , test_data -> first , test_data -> second );
@@ -212,12 +209,10 @@ static void test_audio_pipeline_complete_connect_upstream_other_pipeline
212209 /*Connecting first comp to second*/
213210 comp = & test_data -> second -> ipc_config ;
214211 comp -> pipeline_id = PIPELINE_ID_DIFFERENT ;
215- list_item_append (& result .sched_comp -> bsource_list ,
216- & test_data -> b1 -> sink_list );
217- test_data -> b1 -> sink = test_data -> first ;
218- test_data -> b1 -> source = test_data -> second ;
219- list_item_append (& test_data -> second -> bsource_list ,
220- & test_data -> b1 -> source_list );
212+ list_item_append (& result .sched_comp -> bsource_list , & test_data -> b1 -> sink_list );
213+ comp_buffer_set_sink_component (test_data -> b1 , test_data -> first );
214+ comp_buffer_set_source_component (test_data -> b1 , test_data -> second );
215+ list_item_append (& test_data -> second -> bsource_list , & test_data -> b1 -> source_list );
221216
222217 /*Testing component*/
223218 pipeline_complete (& result , test_data -> first , test_data -> second );
0 commit comments