@@ -236,7 +236,6 @@ public static String buildAndVerifyGivenBuilders(String projectName, BoardDescri
236
236
IProject theTestProject = null ;
237
237
NullProgressMonitor monitor = new NullProgressMonitor ();
238
238
Shared .buildCounter ++;
239
- boolean projectFreshlyCreated = true ;
240
239
241
240
for (String curBuilder : builders ) {
242
241
if (theTestProject == null ) {
@@ -247,18 +246,17 @@ public static String buildAndVerifyGivenBuilders(String projectName, BoardDescri
247
246
compileOptions , curBuilder , monitor );
248
247
waitForAllJobsToFinish ();
249
248
}
250
- // do not set the build tool when the project is freshly created because then
251
- // the default case would never be tested
252
- if (!projectFreshlyCreated ) {
253
- // set the builder
254
- CoreModel coreModel = CoreModel .getDefault ();
255
- ICProjectDescription projectDescription = coreModel .getProjectDescription (theTestProject , true );
256
- IAutoBuildConfigurationDescription autoDesc = IAutoBuildConfigurationDescription
257
- .getActiveConfig (projectDescription );
258
- autoDesc .setBuilder (curBuilder );
259
- coreModel .setProjectDescription (theTestProject , projectDescription );
260
- }
261
- projectFreshlyCreated = false ;
249
+ // clean so we will get a full build for this buider
250
+ theTestProject .build (IncrementalProjectBuilder .CLEAN_BUILD , monitor );
251
+
252
+ // set the builder
253
+ CoreModel coreModel = CoreModel .getDefault ();
254
+ ICProjectDescription projectDescription = coreModel .getProjectDescription (theTestProject , true );
255
+ IAutoBuildConfigurationDescription autoDesc = IAutoBuildConfigurationDescription
256
+ .getActiveConfig (projectDescription );
257
+ autoDesc .setBuilder (curBuilder );
258
+ coreModel .setProjectDescription (theTestProject , projectDescription );
259
+
262
260
theTestProject .build (IncrementalProjectBuilder .FULL_BUILD , monitor );
263
261
264
262
if (hasBuildErrors (theTestProject )!=null ) {
@@ -276,8 +274,7 @@ public static String buildAndVerifyGivenBuilders(String projectName, BoardDescri
276
274
}
277
275
}
278
276
}
279
- // clean so we will get a full build at the next build
280
- theTestProject .build (IncrementalProjectBuilder .CLEAN_BUILD , monitor );
277
+
281
278
}
282
279
if (!myLastFailMessage .isBlank ()) {
283
280
if (myCloseFailedProjectsSetting && theTestProject !=null ) {
0 commit comments