View | Details | Raw Unified | Return to bug 174348 | Differences between
and this patch

Collapse All | Expand All

(-)src/org/eclipse/jdt/core/tests/model/ClasspathInitializerTests.java (-5 / +5 lines)
Lines 805-811 Link Here
805
		}
805
		}
806
		assertExceptionEquals(
806
		assertExceptionEquals(
807
			"Unexpected expection", 
807
			"Unexpected expection", 
808
			"Project cannot reference itself: P1", 
808
			"Project 'P1' cannot reference itself", 
809
			exception);
809
			exception);
810
	} finally {
810
	} finally {
811
		stopDeltas();
811
		stopDeltas();
Lines 1108-1114 Link Here
1108
		createFile("/P1/lib.jar", "");
1108
		createFile("/P1/lib.jar", "");
1109
		IClasspathEntry variable = JavaCore.newVariableEntry(new Path("TEST_DEPRECATED"), null, null);
1109
		IClasspathEntry variable = JavaCore.newVariableEntry(new Path("TEST_DEPRECATED"), null, null);
1110
		IJavaModelStatus status = JavaConventions.validateClasspathEntry(project, variable, false);
1110
		IJavaModelStatus status = JavaConventions.validateClasspathEntry(project, variable, false);
1111
		assertStatus("Classpath variable 'TEST_DEPRECATED' in project P1 is deprecated: 'Test deprecated flag'", status);
1111
		assertStatus("Classpath variable 'TEST_DEPRECATED' in project 'P1' is deprecated: Test deprecated flag", status);
1112
		assertFalse("Status should not be OK", status.isOK());
1112
		assertFalse("Status should not be OK", status.isOK());
1113
		assertEquals("Status should have WARNING severity", IStatus.WARNING, status.getSeverity());
1113
		assertEquals("Status should have WARNING severity", IStatus.WARNING, status.getSeverity());
1114
		assertEquals("Status should have deprecated code", IJavaModelStatusConstants.DEPRECATED_VARIABLE, status.getCode());
1114
		assertEquals("Status should have deprecated code", IJavaModelStatusConstants.DEPRECATED_VARIABLE, status.getCode());
Lines 1132-1138 Link Here
1132
		IJavaProject project = createJavaProject("P1");
1132
		IJavaProject project = createJavaProject("P1");
1133
		IClasspathEntry variable = JavaCore.newVariableEntry(new Path("TEST_DEPRECATED"), null, null);
1133
		IClasspathEntry variable = JavaCore.newVariableEntry(new Path("TEST_DEPRECATED"), null, null);
1134
		IJavaModelStatus status = JavaConventions.validateClasspathEntry(project, variable, false);
1134
		IJavaModelStatus status = JavaConventions.validateClasspathEntry(project, variable, false);
1135
		assertStatus("Project P1 is missing required library: 'lib.jar'", status);
1135
		assertStatus("Project 'P1' is missing required library: 'lib.jar'", status);
1136
		assertFalse("Status should not be OK", status.isOK());
1136
		assertFalse("Status should not be OK", status.isOK());
1137
		assertEquals("Status should have WARNING severity", IStatus.ERROR, status.getSeverity());
1137
		assertEquals("Status should have WARNING severity", IStatus.ERROR, status.getSeverity());
1138
		assertEquals("Status should have deprecated code", IJavaModelStatusConstants.INVALID_CLASSPATH, status.getCode());
1138
		assertEquals("Status should have deprecated code", IJavaModelStatusConstants.INVALID_CLASSPATH, status.getCode());
Lines 1187-1193 Link Here
1187
		createFile("/P1/lib.jar", "");
1187
		createFile("/P1/lib.jar", "");
1188
		IClasspathEntry variable = JavaCore.newVariableEntry(new Path("TEST_DEPRECATED_READ_ONLY"), null, null);
1188
		IClasspathEntry variable = JavaCore.newVariableEntry(new Path("TEST_DEPRECATED_READ_ONLY"), null, null);
1189
		IJavaModelStatus status = JavaConventions.validateClasspathEntry(project, variable, false);
1189
		IJavaModelStatus status = JavaConventions.validateClasspathEntry(project, variable, false);
1190
		assertStatus("Classpath variable 'TEST_DEPRECATED_READ_ONLY' in project P1 is deprecated: 'A deprecated and read-only initializer'", status);
1190
		assertStatus("Classpath variable 'TEST_DEPRECATED_READ_ONLY' in project 'P1' is deprecated: A deprecated and read-only initializer", status);
1191
		assertFalse("Status should not be OK", status.isOK());
1191
		assertFalse("Status should not be OK", status.isOK());
1192
		assertEquals("Status should have WARNING severity", IStatus.WARNING, status.getSeverity());
1192
		assertEquals("Status should have WARNING severity", IStatus.WARNING, status.getSeverity());
1193
		assertEquals("Status should have deprecated code", IJavaModelStatusConstants.DEPRECATED_VARIABLE, status.getCode());
1193
		assertEquals("Status should have deprecated code", IJavaModelStatusConstants.DEPRECATED_VARIABLE, status.getCode());
Lines 1228-1234 Link Here
1228
		IMarker[] markers = project.getProject().findMarkers(IJavaModelMarker.BUILDPATH_PROBLEM_MARKER, false, IResource.DEPTH_ZERO);
1228
		IMarker[] markers = project.getProject().findMarkers(IJavaModelMarker.BUILDPATH_PROBLEM_MARKER, false, IResource.DEPTH_ZERO);
1229
		sortMarkers(markers);
1229
		sortMarkers(markers);
1230
		assertMarkers("Unexpected marker(s)",
1230
		assertMarkers("Unexpected marker(s)",
1231
			"Classpath variable 'TEST_DEPRECATED_READ_ONLY' in project P1 is deprecated: 'A deprecated and read-only initializer'",
1231
			"Classpath variable 'TEST_DEPRECATED_READ_ONLY' in project 'P1' is deprecated: A deprecated and read-only initializer",
1232
			markers);
1232
			markers);
1233
		assertEquals("Marker on deprecated variable should be a WARNING", IMarker.SEVERITY_WARNING, markers[0].getAttribute(IMarker.SEVERITY, -1));
1233
		assertEquals("Marker on deprecated variable should be a WARNING", IMarker.SEVERITY_WARNING, markers[0].getAttribute(IMarker.SEVERITY, -1));
1234
	} finally {
1234
	} finally {
(-)src/org/eclipse/jdt/core/tests/model/ClasspathTests.java (-35 / +35 lines)
Lines 682-688 Link Here
682
		
682
		
683
		assertStatus(
683
		assertStatus(
684
			"should have detected duplicate entries on the classpath", 
684
			"should have detected duplicate entries on the classpath", 
685
			"Build path contains duplicate entry: \'src\' for project P",
685
			"Build path contains duplicate entry: \'src\' for project 'P'",
686
			status);
686
			status);
687
	} finally {
687
	} finally {
688
		this.deleteProject("P");
688
		this.deleteProject("P");
Lines 801-807 Link Here
801
		status = JavaConventions.validateClasspathEntry(p[0], newClasspath[1], true);
801
		status = JavaConventions.validateClasspathEntry(p[0], newClasspath[1], true);
802
		assertStatus(
802
		assertStatus(
803
			"should have detected external source folder through a container on the classpath", 
803
			"should have detected external source folder through a container on the classpath", 
804
			"Invalid classpath container: \'container/default\' in project P0",
804
			"Invalid classpath container: 'container/default' in project 'P0'",
805
			status);
805
			status);
806
806
807
	} finally {
807
	} finally {
Lines 1099-1105 Link Here
1099
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1099
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1100
		
1100
		
1101
		assertStatus(
1101
		assertStatus(
1102
			"Path \'/S/bin\' must denote location inside project P",
1102
			"Path \'/S/bin\' must denote location inside project 'P'",
1103
			status);
1103
			status);
1104
	} finally {
1104
	} finally {
1105
		this.deleteProject("P");
1105
		this.deleteProject("P");
Lines 1146-1152 Link Here
1146
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1146
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1147
		
1147
		
1148
		assertStatus(
1148
		assertStatus(
1149
			"Multiple output locations are disabled in project P, cannot associate entry: \'src\' with a specific output",
1149
			"Multiple output locations are disabled in project 'P', cannot associate entry: \'src\' with a specific output",
1150
			status);
1150
			status);
1151
	} finally {
1151
	} finally {
1152
		this.deleteProject("P");
1152
		this.deleteProject("P");
Lines 1171-1177 Link Here
1171
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1171
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1172
		
1172
		
1173
		assertStatus(
1173
		assertStatus(
1174
			"Inclusion or exclusion patterns are disabled in project P, cannot selectively include or exclude from entry: \'src\'",
1174
			"Inclusion or exclusion patterns are disabled in project 'P', cannot selectively include or exclude from entry: \'src\'",
1175
			status);
1175
			status);
1176
	} finally {
1176
	} finally {
1177
		this.deleteProject("P");
1177
		this.deleteProject("P");
Lines 1194-1200 Link Here
1194
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1194
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1195
		
1195
		
1196
		assertStatus(
1196
		assertStatus(
1197
			"Source folder \'src\' in project P cannot output to distinct source folder \'src2\'",
1197
			"Source folder \'src\' in project 'P' cannot output to distinct source folder \'src2\'",
1198
			status);
1198
			status);
1199
	} finally {
1199
	} finally {
1200
		this.deleteProject("P");
1200
		this.deleteProject("P");
Lines 1267-1273 Link Here
1267
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1267
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1268
		
1268
		
1269
		assertStatus(
1269
		assertStatus(
1270
			"Source folder \'src\' in project P cannot output to library \'lib2\'",
1270
			"Source folder \'src\' in project 'P' cannot output to library \'lib2\'",
1271
			status);
1271
			status);
1272
	} finally {
1272
	} finally {
1273
		this.deleteProject("P");
1273
		this.deleteProject("P");
Lines 1380-1386 Link Here
1380
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1380
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1381
		
1381
		
1382
		assertStatus(
1382
		assertStatus(
1383
			"Source folder \'src\' in project P should be allowed to output to excluded source subfolder \'src/output\'",
1383
			"Source folder \'src\' in project 'P' should be allowed to output to excluded source subfolder \'src/output\'",
1384
			"OK",
1384
			"OK",
1385
			status);
1385
			status);
1386
	} finally {
1386
	} finally {
Lines 1472-1478 Link Here
1472
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1472
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1473
		
1473
		
1474
		assertStatus(
1474
		assertStatus(
1475
			"Source folder \'src1\' in project P cannot output to distinct source folder \'src1/src2\'",
1475
			"Source folder \'src1\' in project 'P' cannot output to distinct source folder \'src1/src2\'",
1476
			status);
1476
			status);
1477
	} finally {
1477
	} finally {
1478
		this.deleteProject("P");
1478
		this.deleteProject("P");
Lines 1588-1594 Link Here
1588
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1588
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1589
		
1589
		
1590
		assertStatus(
1590
		assertStatus(
1591
			"Inclusion or exclusion patterns are disabled in project P, cannot selectively include or exclude from entry: \'src\'",
1591
			"Inclusion or exclusion patterns are disabled in project 'P', cannot selectively include or exclude from entry: \'src\'",
1592
			status);
1592
			status);
1593
	} finally {
1593
	} finally {
1594
		this.deleteProject("P");
1594
		this.deleteProject("P");
Lines 1609-1615 Link Here
1609
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1609
		IJavaModelStatus status = JavaConventions.validateClasspath(proj, newCP, proj.getOutputLocation());
1610
		
1610
		
1611
		assertStatus(
1611
		assertStatus(
1612
			"Source folder \'src\' in project P should not be allowed to output to included source subfolder \'src/output\'",
1612
			"Source folder \'src\' in project 'P' should not be allowed to output to included source subfolder \'src/output\'",
1613
			"Cannot nest output folder \'P/src/output\' inside \'P/src\'",
1613
			"Cannot nest output folder \'P/src/output\' inside \'P/src\'",
1614
			status);
1614
			status);
1615
	} finally {
1615
	} finally {
Lines 1741-1754 Link Here
1741
		IClasspathEntry container = JavaCore.newContainerEntry(new Path("JRE_CONTAINER"), ClasspathEntry.NO_ACCESS_RULES, extraAttributes, false);
1741
		IClasspathEntry container = JavaCore.newContainerEntry(new Path("JRE_CONTAINER"), ClasspathEntry.NO_ACCESS_RULES, extraAttributes, false);
1742
		IJavaModelStatus status = JavaConventions.validateClasspathEntry(proj, container, false);
1742
		IJavaModelStatus status = JavaConventions.validateClasspathEntry(proj, container, false);
1743
		assertStatus(
1743
		assertStatus(
1744
			"Duplicate extra attribute: \'javadoc_location\' in classpath entry \'JRE_CONTAINER\' for project P1",
1744
			"Duplicate extra attribute: \'javadoc_location\' in classpath entry \'JRE_CONTAINER\' for project 'P1'",
1745
			status);
1745
			status);
1746
1746
1747
		// Verify library entry validation
1747
		// Verify library entry validation
1748
		IClasspathEntry library = JavaCore.newLibraryEntry(new Path(getExternalJCLPathString()), null, null, ClasspathEntry.NO_ACCESS_RULES, extraAttributes, false);
1748
		IClasspathEntry library = JavaCore.newLibraryEntry(new Path(getExternalJCLPathString()), null, null, ClasspathEntry.NO_ACCESS_RULES, extraAttributes, false);
1749
		status = JavaConventions.validateClasspathEntry(proj, library, false);
1749
		status = JavaConventions.validateClasspathEntry(proj, library, false);
1750
		assertStatus(
1750
		assertStatus(
1751
			"Duplicate extra attribute: \'javadoc_location\' in classpath entry \'"+getExternalJCLPath()+"\' for project P1",
1751
			"Duplicate extra attribute: \'javadoc_location\' in classpath entry \'"+getExternalJCLPath()+"\' for project 'P1'",
1752
			status);
1752
			status);
1753
1753
1754
		// Verify project entry validation
1754
		// Verify project entry validation
Lines 1756-1762 Link Here
1756
		IClasspathEntry projectEntry = JavaCore.newProjectEntry(new Path("/P2"), ClasspathEntry.NO_ACCESS_RULES, false, extraAttributes, false);
1756
		IClasspathEntry projectEntry = JavaCore.newProjectEntry(new Path("/P2"), ClasspathEntry.NO_ACCESS_RULES, false, extraAttributes, false);
1757
		status = JavaConventions.validateClasspathEntry(proj, projectEntry, false);
1757
		status = JavaConventions.validateClasspathEntry(proj, projectEntry, false);
1758
		assertStatus(
1758
		assertStatus(
1759
			"Duplicate extra attribute: \'javadoc_location\' in classpath entry \'/P2\' for project P1",
1759
			"Duplicate extra attribute: \'javadoc_location\' in classpath entry \'/P2\' for project 'P1'",
1760
			status);
1760
			status);
1761
1761
1762
		// Verify source entry validation
1762
		// Verify source entry validation
Lines 1764-1777 Link Here
1764
		IClasspathEntry sourceEntry = JavaCore.newSourceEntry(new Path("/P1/src"), new IPath[0], new IPath[0], null, extraAttributes);
1764
		IClasspathEntry sourceEntry = JavaCore.newSourceEntry(new Path("/P1/src"), new IPath[0], new IPath[0], null, extraAttributes);
1765
		status = JavaConventions.validateClasspathEntry(proj, sourceEntry, false);
1765
		status = JavaConventions.validateClasspathEntry(proj, sourceEntry, false);
1766
		assertStatus(
1766
		assertStatus(
1767
			"Duplicate extra attribute: \'javadoc_location\' in classpath entry \'src\' for project P1",
1767
			"Duplicate extra attribute: \'javadoc_location\' in classpath entry \'src\' for project 'P1'",
1768
			status);
1768
			status);
1769
1769
1770
		// Verify variable entry validation
1770
		// Verify variable entry validation
1771
		IClasspathEntry variable = JavaCore.newVariableEntry(new Path("JCL_LIB"), new Path("JCL_SRC"), null, ClasspathEntry.NO_ACCESS_RULES, extraAttributes, false);
1771
		IClasspathEntry variable = JavaCore.newVariableEntry(new Path("JCL_LIB"), new Path("JCL_SRC"), null, ClasspathEntry.NO_ACCESS_RULES, extraAttributes, false);
1772
		status = JavaConventions.validateClasspathEntry(proj, variable, false);
1772
		status = JavaConventions.validateClasspathEntry(proj, variable, false);
1773
		assertStatus(
1773
		assertStatus(
1774
			"Duplicate extra attribute: \'javadoc_location\' in classpath entry \'"+getExternalJCLPath()+"\' for project P1",
1774
			"Duplicate extra attribute: \'javadoc_location\' in classpath entry \'"+getExternalJCLPath()+"\' for project 'P1'",
1775
			status);
1775
			status);
1776
	} finally {
1776
	} finally {
1777
		this.deleteProject("P1");
1777
		this.deleteProject("P1");
Lines 2342-2348 Link Here
2342
		);
2342
		);
2343
		assertMarkers(
2343
		assertMarkers(
2344
			"Unexpected markers",
2344
			"Unexpected markers",
2345
			"XML format error in \'.classpath\' file of project P: Bad format",
2345
			"XML format error in \'.classpath\' file of project 'P': Bad format",
2346
			project);
2346
			project);
2347
	} finally {
2347
	} finally {
2348
		this.deleteProject("P");
2348
		this.deleteProject("P");
Lines 2364-2370 Link Here
2364
		);
2364
		);
2365
		assertMarkers(
2365
		assertMarkers(
2366
			"Unexpected markers",
2366
			"Unexpected markers",
2367
			"Illegal entry in \'.classpath\' of project P file: Unknown kind: \'src1\'",
2367
			"Illegal entry in \'.classpath\' of project 'P' file: Unknown kind: \'src1\'",
2368
			javaProject);
2368
			javaProject);
2369
			
2369
			
2370
		// Verify that error marker is not removed after build
2370
		// Verify that error marker is not removed after build
Lines 2374-2380 Link Here
2374
		waitForAutoBuild();
2374
		waitForAutoBuild();
2375
		assertMarkers(
2375
		assertMarkers(
2376
			"Unexpected markers",
2376
			"Unexpected markers",
2377
			"Illegal entry in \'.classpath\' of project P file: Unknown kind: \'src1\'",
2377
			"Illegal entry in \'.classpath\' of project 'P' file: Unknown kind: \'src1\'",
2378
			javaProject);
2378
			javaProject);
2379
	} finally {
2379
	} finally {
2380
		this.deleteProject("P");
2380
		this.deleteProject("P");
Lines 2392-2398 Link Here
2392
		IJavaProject proj =  createJavaProject("P", new String[] {}, new String[] {externalPath}, "bin");
2392
		IJavaProject proj =  createJavaProject("P", new String[] {}, new String[] {externalPath}, "bin");
2393
		assertMarkers(
2393
		assertMarkers(
2394
			"Unexpected markers",
2394
			"Unexpected markers",
2395
			"Required library cannot denote external folder: \'" + externalPath + "\' for project P",
2395
			"Required library cannot denote external folder: \'" + externalPath + "\' for project 'P'",
2396
			proj);
2396
			proj);
2397
	} finally {
2397
	} finally {
2398
		deleteProject("P");
2398
		deleteProject("P");
Lines 2407-2413 Link Here
2407
		IJavaProject proj = createJavaProject("P", new String[] {}, new String[] {jarPath}, "bin");
2407
		IJavaProject proj = createJavaProject("P", new String[] {}, new String[] {jarPath}, "bin");
2408
		assertMarkers(
2408
		assertMarkers(
2409
			"Unexpected markers",
2409
			"Unexpected markers",
2410
			"Project P is missing required library: \'" + jarPath + "\'",
2410
			"Project 'P' is missing required library: \'" + jarPath + "\'",
2411
			proj);
2411
			proj);
2412
	} finally {
2412
	} finally {
2413
		deleteProject("P");
2413
		deleteProject("P");
Lines 2421-2427 Link Here
2421
		IJavaProject proj = createJavaProject("P", new String[] {}, new String[] {"/P/nonExisting.jar"}, "bin");
2421
		IJavaProject proj = createJavaProject("P", new String[] {}, new String[] {"/P/nonExisting.jar"}, "bin");
2422
		assertMarkers(
2422
		assertMarkers(
2423
			"Unexpected markers",
2423
			"Unexpected markers",
2424
			"Project P is missing required library: \'nonExisting.jar\'",
2424
			"Project 'P' is missing required library: \'nonExisting.jar\'",
2425
			proj);
2425
			proj);
2426
	} finally {
2426
	} finally {
2427
		deleteProject("P");
2427
		deleteProject("P");
Lines 2437-2443 Link Here
2437
		IJavaProject proj =  createJavaProject("P2", new String[] {}, new String[] {"/P1/existing.txt"}, "bin");
2437
		IJavaProject proj =  createJavaProject("P2", new String[] {}, new String[] {"/P1/existing.txt"}, "bin");
2438
		assertMarkers(
2438
		assertMarkers(
2439
			"Unexpected markers",
2439
			"Unexpected markers",
2440
			"Illegal type of archive for required library: \'/P1/existing.txt\' in project P2",
2440
			"Illegal type of archive for required library: \'/P1/existing.txt\' in project 'P2'",
2441
			proj);
2441
			proj);
2442
	} finally {
2442
	} finally {
2443
		deleteProject("P1");
2443
		deleteProject("P1");
Lines 2455-2461 Link Here
2455
		IJavaProject proj = createJavaProject("P2", new String[] {}, new String[] {}, new String[] {"/P1/src1/src2"}, "bin");
2455
		IJavaProject proj = createJavaProject("P2", new String[] {}, new String[] {}, new String[] {"/P1/src1/src2"}, "bin");
2456
		assertMarkers(
2456
		assertMarkers(
2457
			"Unexpected markers",
2457
			"Unexpected markers",
2458
			"Project P2 is missing required source folder: \'/P1/src1/src2\'",
2458
			"Project 'P2' is missing required source folder: \'/P1/src1/src2\'",
2459
			proj);
2459
			proj);
2460
	} finally {
2460
	} finally {
2461
		deleteProject("P1");
2461
		deleteProject("P1");
Lines 2482-2488 Link Here
2482
		waitForAutoBuild();
2482
		waitForAutoBuild();
2483
		assertMarkers(
2483
		assertMarkers(
2484
			"Unexpected markers",
2484
			"Unexpected markers",
2485
			"Unable to read \'.classpath\' file of project P",
2485
			"Unable to read \'.classpath\' file of project 'P'",
2486
			javaProject);
2486
			javaProject);
2487
	} finally {
2487
	} finally {
2488
		this.deleteProject("P");
2488
		this.deleteProject("P");
Lines 2501-2507 Link Here
2501
		javaProject.setRawClasspath(classpath, null);
2501
		javaProject.setRawClasspath(classpath, null);
2502
		this.assertMarkers(
2502
		this.assertMarkers(
2503
			"Unexpected markers",
2503
			"Unexpected markers",
2504
			"Project A is missing required Java project: \'B\'",
2504
			"Project 'A' is missing required Java project: \'B\'",
2505
			javaProject);
2505
			javaProject);
2506
	} finally {
2506
	} finally {
2507
		this.deleteProject("A");
2507
		this.deleteProject("A");
Lines 2521-2527 Link Here
2521
				"");
2521
				"");
2522
		this.assertMarkers(
2522
		this.assertMarkers(
2523
			"Unexpected markers",
2523
			"Unexpected markers",
2524
			"Project A is missing required Java project: \'B\'",
2524
			"Project 'A' is missing required Java project: \'B\'",
2525
			javaProject);
2525
			javaProject);
2526
	} finally {
2526
	} finally {
2527
		this.deleteProject("A");
2527
		this.deleteProject("A");
Lines 2568-2585 Link Here
2568
				"");
2568
				"");
2569
		this.assertMarkers(
2569
		this.assertMarkers(
2570
			"Unexpected markers for project A",
2570
			"Unexpected markers for project A",
2571
			"A cycle was detected in the build path of project: A",
2571
			"A cycle was detected in the build path of project 'A'",
2572
			projectA);
2572
			projectA);
2573
		this.assertMarkers(
2573
		this.assertMarkers(
2574
			"Unexpected markers for project B",
2574
			"Unexpected markers for project B",
2575
			"A cycle was detected in the build path of project: B",
2575
			"A cycle was detected in the build path of project 'B'",
2576
			projectB);
2576
			projectB);
2577
		
2577
		
2578
		// delete project B	
2578
		// delete project B	
2579
		this.deleteProject("B");
2579
		this.deleteProject("B");
2580
		this.assertMarkers(
2580
		this.assertMarkers(
2581
			"Unexpected markers for project A after deleting of project B",
2581
			"Unexpected markers for project A after deleting of project B",
2582
			"Project A is missing required Java project: \'B\'",
2582
			"Project 'A' is missing required Java project: \'B\'",
2583
			projectA);
2583
			projectA);
2584
			
2584
			
2585
		// add project B back
2585
		// add project B back
Lines 2592-2602 Link Here
2592
				"");
2592
				"");
2593
		this.assertMarkers(
2593
		this.assertMarkers(
2594
			"Unexpected markers for project A after adding project B back",
2594
			"Unexpected markers for project A after adding project B back",
2595
			"A cycle was detected in the build path of project: A",
2595
			"A cycle was detected in the build path of project 'A'",
2596
			projectA);
2596
			projectA);
2597
		this.assertMarkers(
2597
		this.assertMarkers(
2598
			"Unexpected markers for project B after adding project B back",
2598
			"Unexpected markers for project B after adding project B back",
2599
			"A cycle was detected in the build path of project: B",
2599
			"A cycle was detected in the build path of project 'B'",
2600
			projectB);
2600
			projectB);
2601
2601
2602
	} finally {
2602
	} finally {
Lines 3324-3330 Link Here
3324
		);
3324
		);
3325
		assertMarkers(
3325
		assertMarkers(
3326
			"Unexpected markers",
3326
			"Unexpected markers",
3327
			"Build path contains duplicate entry: \'src\' for project P",
3327
			"Build path contains duplicate entry: \'src\' for project 'P'",
3328
			project);
3328
			project);
3329
	} finally {
3329
	} finally {
3330
		this.deleteProject("P");
3330
		this.deleteProject("P");
Lines 3625-3632 Link Here
3625
		
3625
		
3626
		assertMarkers(
3626
		assertMarkers(
3627
			"Unexpected markers",
3627
			"Unexpected markers",
3628
			"Project P is missing required source folder: \'src1\'\n" + 
3628
			"Project 'P' is missing required source folder: \'src1\'\n" + 
3629
			"Project P is missing required source folder: \'src2\'",
3629
			"Project 'P' is missing required source folder: \'src2\'",
3630
			JavaCore.create(project));
3630
			JavaCore.create(project));
3631
	} finally {
3631
	} finally {
3632
		deleteProject("P");
3632
		deleteProject("P");
(-)src/org/eclipse/jdt/core/tests/builder/MultiProjectTests.java (-28 / +28 lines)
Lines 359-367 Link Here
359
			fullBuild();
359
			fullBuild();
360
			
360
			
361
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z", "p1.X", "p2.Y", "p3.Z", "p1.X"});//$NON-NLS-1$//$NON-NLS-2$//$NON-NLS-3$//$NON-NLS-4$//$NON-NLS-5$//$NON-NLS-6$//$NON-NLS-7$
361
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z", "p1.X", "p2.Y", "p3.Z", "p1.X"});//$NON-NLS-1$//$NON-NLS-2$//$NON-NLS-3$//$NON-NLS-4$//$NON-NLS-5$//$NON-NLS-6$//$NON-NLS-7$
362
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
362
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project 'P1'", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
363
			expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
363
			expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project 'P2'", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
364
			expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
364
			expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project 'P3'", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
365
			
365
			
366
			JavaCore.setOptions(options);
366
			JavaCore.setOptions(options);
367
		} finally {
367
		} finally {
Lines 453-464 Link Here
453
			fullBuild();
453
			fullBuild();
454
			
454
			
455
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z", "p1.X", "p2.Y", "p3.Z", "p1.X"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$//$NON-NLS-5$ //$NON-NLS-6$//$NON-NLS-7$
455
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z", "p1.X", "p2.Y", "p3.Z", "p1.X"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$//$NON-NLS-5$ //$NON-NLS-6$//$NON-NLS-7$
456
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
456
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project 'P1'", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
457
			expectingOnlySpecificProblemsFor(p2,new Problem[]{
457
			expectingOnlySpecificProblemsFor(p2,new Problem[]{
458
					new Problem("p2", "The method bar(Y, int) in the type X is not applicable for the arguments (Y)", c2, 106, 109, CategorizedProblem.CAT_MEMBER, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
458
					new Problem("p2", "The method bar(Y, int) in the type X is not applicable for the arguments (Y)", c2, 106, 109, CategorizedProblem.CAT_MEMBER, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
459
					new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
459
					new Problem("p2", "A cycle was detected in the build path of project 'P2'", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
460
			});
460
			});
461
			expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
461
			expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project 'P3'", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
462
			
462
			
463
			JavaCore.setOptions(options);
463
			JavaCore.setOptions(options);
464
		} finally {
464
		} finally {
Lines 550-558 Link Here
550
			fullBuild();
550
			fullBuild();
551
			
551
			
552
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z", "p1.X", "p2.Y", "p3.Z", "p1.X"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$//$NON-NLS-5$ //$NON-NLS-6$//$NON-NLS-7$
552
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z", "p1.X", "p2.Y", "p3.Z", "p1.X"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$//$NON-NLS-5$ //$NON-NLS-6$//$NON-NLS-7$
553
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
553
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project 'P1'", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
554
			expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
554
			expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project 'P2'", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
555
			expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
555
			expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project 'P3'", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
556
			
556
			
557
			env.addClass(root1, "p1", "X", //$NON-NLS-1$ //$NON-NLS-2$
557
			env.addClass(root1, "p1", "X", //$NON-NLS-1$ //$NON-NLS-2$
558
				"package p1;\n"+ //$NON-NLS-1$
558
				"package p1;\n"+ //$NON-NLS-1$
Lines 566-577 Link Here
566
			incrementalBuild();
566
			incrementalBuild();
567
			
567
			
568
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z"}); //$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ 
568
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z"}); //$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ 
569
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
569
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project 'P1'", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
570
			expectingOnlySpecificProblemsFor(p2,new Problem[]{
570
			expectingOnlySpecificProblemsFor(p2,new Problem[]{
571
					new Problem("p2", "The method bar(Y, int) in the type X is not applicable for the arguments (Y)", c2, 106, 109, CategorizedProblem.CAT_MEMBER, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
571
					new Problem("p2", "The method bar(Y, int) in the type X is not applicable for the arguments (Y)", c2, 106, 109, CategorizedProblem.CAT_MEMBER, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
572
					new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
572
					new Problem("p2", "A cycle was detected in the build path of project 'P2'", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
573
			});
573
			});
574
			expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
574
			expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project 'P3'", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
575
	
575
	
576
			JavaCore.setOptions(options);
576
			JavaCore.setOptions(options);
577
		} finally {
577
		} finally {
Lines 652-669 Link Here
652
			fullBuild();
652
			fullBuild();
653
			
653
			
654
			expectingCompilingOrder(new String[]{"p2.Y", "p3.Z", "p2.Y"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$
654
			expectingCompilingOrder(new String[]{"p2.Y", "p3.Z", "p2.Y"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$
655
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
655
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project 'P1'", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
656
			expectingOnlySpecificProblemsFor(p2,new Problem[]{
656
			expectingOnlySpecificProblemsFor(p2,new Problem[]{
657
				new Problem("p2", "The import p1 cannot be resolved", c2, 19, 21, CategorizedProblem.CAT_IMPORT, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
657
				new Problem("p2", "The import p1 cannot be resolved", c2, 19, 21, CategorizedProblem.CAT_IMPORT, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
658
				new Problem("p2", "X cannot be resolved to a type", c2, 73, 74, CategorizedProblem.CAT_TYPE, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
658
				new Problem("p2", "X cannot be resolved to a type", c2, 73, 74, CategorizedProblem.CAT_TYPE, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
659
				new Problem("p2", "X cannot be resolved to a type", c2, 87, 88, CategorizedProblem.CAT_TYPE, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
659
				new Problem("p2", "X cannot be resolved to a type", c2, 87, 88, CategorizedProblem.CAT_TYPE, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
660
				new Problem("p2", "The method foo() is undefined for the type Y", c2, 93, 96, CategorizedProblem.CAT_MEMBER, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
660
				new Problem("p2", "The method foo() is undefined for the type Y", c2, 93, 96, CategorizedProblem.CAT_MEMBER, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
661
				new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
661
				new Problem("p2", "A cycle was detected in the build path of project 'P2'", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
662
			});
662
			});
663
			expectingOnlySpecificProblemsFor(p3,new Problem[]{
663
			expectingOnlySpecificProblemsFor(p3,new Problem[]{
664
				new Problem("p3", "X cannot be resolved to a type", c3, 51, 52, CategorizedProblem.CAT_TYPE, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
664
				new Problem("p3", "X cannot be resolved to a type", c3, 51, 52, CategorizedProblem.CAT_TYPE, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
665
				new Problem("p3", "The import p1 cannot be resolved", c3, 19, 21, CategorizedProblem.CAT_IMPORT, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
665
				new Problem("p3", "The import p1 cannot be resolved", c3, 19, 21, CategorizedProblem.CAT_IMPORT, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
666
				new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
666
				new Problem("p3", "A cycle was detected in the build path of project 'P3'", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
667
			});
667
			});
668
	
668
	
669
			env.addClass(root1, "p1", "X", //$NON-NLS-1$ //$NON-NLS-2$
669
			env.addClass(root1, "p1", "X", //$NON-NLS-1$ //$NON-NLS-2$
Lines 677-685 Link Here
677
				);
677
				);
678
			incrementalBuild();
678
			incrementalBuild();
679
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z", "p1.X", "p2.Y"}); //$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$//$NON-NLS-5$ 
679
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z", "p1.X", "p2.Y"}); //$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$//$NON-NLS-5$ 
680
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
680
			expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project 'P1'", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
681
			expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
681
			expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project 'P2'", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
682
			expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
682
			expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project 'P3'", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING));//$NON-NLS-1$ //$NON-NLS-2$
683
	
683
	
684
			JavaCore.setOptions(options);
684
			JavaCore.setOptions(options);
685
		} finally {
685
		} finally {
Lines 745-755 Link Here
745
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p1.X", "p2.Y"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$ 
745
			expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p1.X", "p2.Y"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$ 
746
			expectingOnlySpecificProblemsFor(p1,new Problem[]{
746
			expectingOnlySpecificProblemsFor(p1,new Problem[]{
747
				new Problem("p1", "The import p22 cannot be resolved", c1, 32, 35, CategorizedProblem.CAT_IMPORT, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
747
				new Problem("p1", "The import p22 cannot be resolved", c1, 32, 35, CategorizedProblem.CAT_IMPORT, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
748
				new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
748
				new Problem("p1", "A cycle was detected in the build path of project 'P1'", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
749
			});
749
			});
750
			expectingOnlySpecificProblemsFor(p2,new Problem[]{
750
			expectingOnlySpecificProblemsFor(p2,new Problem[]{
751
				new Problem("p2", "The import p11 cannot be resolved", c2, 32, 35, CategorizedProblem.CAT_IMPORT, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
751
				new Problem("p2", "The import p11 cannot be resolved", c2, 32, 35, CategorizedProblem.CAT_IMPORT, IMarker.SEVERITY_ERROR),//$NON-NLS-1$ //$NON-NLS-2$
752
				new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
752
				new Problem("p2", "A cycle was detected in the build path of project 'P2'", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
753
			});
753
			});
754
			
754
			
755
			env.addClass(root1, "p11", "XX", //$NON-NLS-1$ //$NON-NLS-2$
755
			env.addClass(root1, "p11", "XX", //$NON-NLS-1$ //$NON-NLS-2$
Lines 768-778 Link Here
768
			expectingCompilingOrder(new String[]{"p11.XX", "p22.YY", "p2.Y", "p1.X"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$
768
			expectingCompilingOrder(new String[]{"p11.XX", "p22.YY", "p2.Y", "p1.X"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$
769
			expectingOnlySpecificProblemsFor(p1,new Problem[]{
769
			expectingOnlySpecificProblemsFor(p1,new Problem[]{
770
				new Problem("p1", "The import p22 is never used", c1, 32, 35, CategorizedProblem.CAT_UNNECESSARY_CODE, IMarker.SEVERITY_WARNING),//$NON-NLS-1$ //$NON-NLS-2$
770
				new Problem("p1", "The import p22 is never used", c1, 32, 35, CategorizedProblem.CAT_UNNECESSARY_CODE, IMarker.SEVERITY_WARNING),//$NON-NLS-1$ //$NON-NLS-2$
771
				new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
771
				new Problem("p1", "A cycle was detected in the build path of project 'P1'", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
772
			});
772
			});
773
			expectingOnlySpecificProblemsFor(p2,new Problem[]{
773
			expectingOnlySpecificProblemsFor(p2,new Problem[]{
774
				new Problem("p2", "The import p11 is never used", c2, 32, 35, CategorizedProblem.CAT_UNNECESSARY_CODE, IMarker.SEVERITY_WARNING),//$NON-NLS-1$ //$NON-NLS-2$
774
				new Problem("p2", "The import p11 is never used", c2, 32, 35, CategorizedProblem.CAT_UNNECESSARY_CODE, IMarker.SEVERITY_WARNING),//$NON-NLS-1$ //$NON-NLS-2$
775
				new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
775
				new Problem("p2", "A cycle was detected in the build path of project 'P2'", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
776
			});
776
			});
777
			
777
			
778
			JavaCore.setOptions(options);
778
			JavaCore.setOptions(options);
Lines 853-865 Link Here
853
		fullBuild();
853
		fullBuild();
854
854
855
		expectingOnlySpecificProblemsFor(p1,new Problem[]{
855
		expectingOnlySpecificProblemsFor(p1,new Problem[]{
856
			new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
856
			new Problem("p1", "A cycle was detected in the build path of project 'P1'", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
857
		});
857
		});
858
		expectingOnlySpecificProblemsFor(p2,new Problem[]{
858
		expectingOnlySpecificProblemsFor(p2,new Problem[]{
859
			new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
859
			new Problem("p2", "A cycle was detected in the build path of project 'P2'", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
860
		});
860
		});
861
		expectingOnlySpecificProblemsFor(p3,new Problem[]{
861
		expectingOnlySpecificProblemsFor(p3,new Problem[]{
862
			new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
862
			new Problem("p3", "A cycle was detected in the build path of project 'P3'", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
863
		});
863
		});
864
		
864
		
865
	} finally {
865
	} finally {
Lines 939-951 Link Here
939
		fullBuild();
939
		fullBuild();
940
940
941
		expectingOnlySpecificProblemsFor(p1,new Problem[]{
941
		expectingOnlySpecificProblemsFor(p1,new Problem[]{
942
			new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
942
			new Problem("p1", "A cycle was detected in the build path of project 'P1'", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
943
		});
943
		});
944
		expectingOnlySpecificProblemsFor(p2,new Problem[]{
944
		expectingOnlySpecificProblemsFor(p2,new Problem[]{
945
			new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
945
			new Problem("p2", "A cycle was detected in the build path of project 'P2'", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
946
		});
946
		});
947
		expectingOnlySpecificProblemsFor(p3,new Problem[]{
947
		expectingOnlySpecificProblemsFor(p3,new Problem[]{
948
			new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
948
			new Problem("p3", "A cycle was detected in the build path of project 'P3'", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_WARNING)//$NON-NLS-1$ //$NON-NLS-2$
949
		});
949
		});
950
		
950
		
951
	} finally {
951
	} finally {
(-)src/org/eclipse/jdt/core/tests/builder/BuildpathTests.java (-6 / +6 lines)
Lines 110-122 Link Here
110
		expectingOnlySpecificProblemsFor(project2Path,
110
		expectingOnlySpecificProblemsFor(project2Path,
111
			new Problem[] {
111
			new Problem[] {
112
				new Problem("", "The project cannot be built until build path errors are resolved", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR), //$NON-NLS-1$ //$NON-NLS-2$
112
				new Problem("", "The project cannot be built until build path errors are resolved", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR), //$NON-NLS-1$ //$NON-NLS-2$
113
				new Problem("Build path", "Project CP2 is missing required Java project: 'CP1'", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
113
				new Problem("Build path", "Project 'CP2' is missing required Java project: 'CP1'", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
114
			}
114
			}
115
		);
115
		);
116
		expectingOnlySpecificProblemsFor(project3Path,
116
		expectingOnlySpecificProblemsFor(project3Path,
117
			new Problem[] {
117
			new Problem[] {
118
				new Problem("", "The project cannot be built until build path errors are resolved", project3Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR), //$NON-NLS-1$ //$NON-NLS-2$
118
				new Problem("", "The project cannot be built until build path errors are resolved", project3Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR), //$NON-NLS-1$ //$NON-NLS-2$
119
				new Problem("Build path", "Project CP3 is missing required library: '/CP1/temp.jar'", project3Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
119
				new Problem("Build path", "Project 'CP3' is missing required library: '/CP1/temp.jar'", project3Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
120
			}
120
			}
121
		);
121
		);
122
122
Lines 135-144 Link Here
135
		incrementalBuild();
135
		incrementalBuild();
136
		expectingOnlyProblemsFor(new IPath[] {project2Path, project3Path});
136
		expectingOnlyProblemsFor(new IPath[] {project2Path, project3Path});
137
		expectingOnlySpecificProblemFor(project2Path,
137
		expectingOnlySpecificProblemFor(project2Path,
138
			new Problem("Build path", "Project CP2 is missing required Java project: 'CP1'", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
138
			new Problem("Build path", "Project 'CP2' is missing required Java project: 'CP1'", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
139
		);
139
		);
140
		expectingOnlySpecificProblemFor(project3Path,
140
		expectingOnlySpecificProblemFor(project3Path,
141
			new Problem("Build path", "Project CP3 is missing required library: '/CP1/temp.jar'", project3Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
141
			new Problem("Build path", "Project 'CP3' is missing required library: '/CP1/temp.jar'", project3Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
142
		);
142
		);
143
143
144
		env.openProject(project1Path);
144
		env.openProject(project1Path);
Lines 531-537 Link Here
531
		expectingOnlySpecificProblemsFor(project2Path,
531
		expectingOnlySpecificProblemsFor(project2Path,
532
			new Problem[] {
532
			new Problem[] {
533
				new Problem("", "The project cannot be built until build path errors are resolved", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR), //$NON-NLS-1$ //$NON-NLS-2$
533
				new Problem("", "The project cannot be built until build path errors are resolved", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR), //$NON-NLS-1$ //$NON-NLS-2$
534
				new Problem("Build path", "Project MP2 is missing required Java project: 'MP1'", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
534
				new Problem("Build path", "Project 'MP2' is missing required Java project: 'MP1'", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
535
			}
535
			}
536
		);
536
		);
537
537
Lines 552-558 Link Here
552
		incrementalBuild();
552
		incrementalBuild();
553
		expectingOnlyProblemsFor(project2Path);
553
		expectingOnlyProblemsFor(project2Path);
554
		expectingOnlySpecificProblemFor(project2Path,
554
		expectingOnlySpecificProblemFor(project2Path,
555
			new Problem("Build path", "Project MP2 is missing required Java project: 'MP1'", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
555
			new Problem("Build path", "Project 'MP2' is missing required Java project: 'MP1'", project2Path, -1, -1, CategorizedProblem.CAT_BUILDPATH, IMarker.SEVERITY_ERROR) //$NON-NLS-1$ //$NON-NLS-2$
556
		);
556
		);
557
557
558
		project1Path = env.addProject("MP1"); //$NON-NLS-1$
558
		project1Path = env.addProject("MP1"); //$NON-NLS-1$
(-)model/org/eclipse/jdt/internal/core/util/messages.properties (-30 / +30 lines)
Lines 56-62 Link Here
56
operation_deleteElementProgress = Deleting elements...
56
operation_deleteElementProgress = Deleting elements...
57
operation_deleteResourceProgress = Deleting resources...
57
operation_deleteResourceProgress = Deleting resources...
58
operation_cannotRenameDefaultPackage = Default package cannot be renamed
58
operation_cannotRenameDefaultPackage = Default package cannot be renamed
59
operation_pathOutsideProject = Path ''{0}'' must denote location inside project {1}
59
operation_pathOutsideProject = Path ''{0}'' must denote location inside project ''{1}''
60
operation_sortelements = Sorting elements...
60
operation_sortelements = Sorting elements...
61
61
62
### working copy
62
### working copy
Lines 134-173 Link Here
134
classpath_cannotNestEntryInOutput = Cannot nest ''{0}'' inside output folder ''{1}''
134
classpath_cannotNestEntryInOutput = Cannot nest ''{0}'' inside output folder ''{1}''
135
classpath_cannotNestOutputInEntry = Cannot nest output folder ''{0}'' inside ''{1}''
135
classpath_cannotNestOutputInEntry = Cannot nest output folder ''{0}'' inside ''{1}''
136
classpath_cannotNestOutputInOutput = Cannot nest output folder ''{0}'' inside output folder ''{1}''
136
classpath_cannotNestOutputInOutput = Cannot nest output folder ''{0}'' inside output folder ''{1}''
137
classpath_cannotReadClasspathFile = Unable to read ''.classpath'' file of project {0}
137
classpath_cannotReadClasspathFile = Unable to read ''.classpath'' file of project ''{0}''
138
classpath_cannotReferToItself = Project cannot reference itself: {0}
138
classpath_cannotReferToItself = Project ''{0}'' cannot reference itself
139
classpath_cannotUseDistinctSourceFolderAsOutput = Source folder ''{0}'' in project {2} cannot output to distinct source folder ''{1}''
139
classpath_cannotUseDistinctSourceFolderAsOutput = Source folder ''{0}'' in project ''{2}'' cannot output to distinct source folder ''{1}''
140
classpath_cannotUseLibraryAsOutput = Source folder ''{0}'' in project {2} cannot output to library ''{1}''
140
classpath_cannotUseLibraryAsOutput = Source folder ''{0}'' in project ''{2}'' cannot output to library ''{1}''
141
classpath_closedProject = Required project: {0} needs to be open
141
classpath_closedProject = Required project ''{0}'' needs to be open
142
classpath_couldNotWriteClasspathFile = Could not write ''.classpath'' file of project {0}: {1}
142
classpath_couldNotWriteClasspathFile = Could not write ''.classpath'' file of project ''{0}'': {1}
143
classpath_cycle = A cycle was detected in the build path of project: {0}
143
classpath_cycle = A cycle was detected in the build path of project ''{0}''
144
classpath_duplicateEntryPath = Build path contains duplicate entry: ''{0}'' for project {1}
144
classpath_duplicateEntryPath = Build path contains duplicate entry: ''{0}'' for project ''{1}''
145
classpath_illegalContainerPath = Illegal classpath container path: ''{0}'' in project {1}, must have at least one segment (containerID+hints)
145
classpath_illegalContainerPath = Illegal classpath container path: ''{0}'' in project ''{1}'', must have at least one segment (containerID+hints)
146
classpath_illegalEntryInClasspathFile = Illegal entry in ''.classpath'' of project {0} file: {1}
146
classpath_illegalEntryInClasspathFile = Illegal entry in ''.classpath'' of project ''{0}'' file: {1}
147
classpath_illegalLibraryPath = Illegal path for required library: ''{0}'' in project {1}
147
classpath_illegalLibraryPath = Illegal path for required library: ''{0}'' in project ''{1}''
148
classpath_illegalLibraryArchive = Illegal type of archive for required library: ''{0}'' in project {1}
148
classpath_illegalLibraryArchive = Illegal type of archive for required library: ''{0}'' in project ''{1}''
149
classpath_illegalExternalFolder = Required library cannot denote external folder: ''{0}'' for project {1}
149
classpath_illegalExternalFolder = Required library cannot denote external folder: ''{0}'' for project ''{1}''
150
classpath_illegalProjectPath = Illegal path for required project: ''{0}'' in project {1}
150
classpath_illegalProjectPath = Illegal path for required project: ''{0}'' in project ''{1}''
151
classpath_illegalSourceFolderPath = Illegal path for required source folder: ''{0}'' in project {1}
151
classpath_illegalSourceFolderPath = Illegal path for required source folder: ''{0}'' in project ''{1}''
152
classpath_illegalVariablePath = Illegal classpath variable path: ''{0}'' in project {1}, must have at least one segment
152
classpath_illegalVariablePath = Illegal classpath variable path: ''{0}'' in project ''{1}'', must have at least one segment
153
classpath_invalidClasspathInClasspathFile = Invalid build path in ''.classpath'' file of project {0}: {1}
153
classpath_invalidClasspathInClasspathFile = Invalid build path in ''.classpath'' file of project ''{0}'': {1}
154
classpath_invalidContainer = Invalid classpath container: ''{0}'' in project {1}
154
classpath_invalidContainer = Invalid classpath container: ''{0}'' in project ''{1}''
155
classpath_mustEndWithSlash = End exclusion filter ''{0}'' with / to fully exclude ''{1}''
155
classpath_mustEndWithSlash = End exclusion filter ''{0}'' with / to fully exclude ''{1}''
156
classpath_unboundContainerPath = Unbound classpath container: ''{0}'' in project {1}
156
classpath_unboundContainerPath = Unbound classpath container: ''{0}'' in project ''{1}''
157
classpath_unboundLibrary = Project {1} is missing required library: ''{0}''
157
classpath_unboundLibrary = Project ''{1}'' is missing required library: ''{0}''
158
classpath_unboundProject = Project {1} is missing required Java project: ''{0}''
158
classpath_unboundProject = Project ''{1}'' is missing required Java project: ''{0}''
159
classpath_settingOutputLocationProgress = Setting output location for: ''{0}''
159
classpath_settingOutputLocationProgress = Setting output location for: ''{0}''
160
classpath_settingProgress = Setting classpath for: {0}
160
classpath_settingProgress = Setting classpath for: {0}
161
classpath_unboundSourceAttachment = Invalid source attachment: ''{0}'' for required library ''{1}'' in project {1}
161
classpath_unboundSourceAttachment = Invalid source attachment: ''{0}'' for required library ''{1}'' in project ''{1}''
162
classpath_unboundSourceFolder = Project {1} is missing required source folder: ''{0}''
162
classpath_unboundSourceFolder = Project ''{1}'' is missing required source folder: ''{0}''
163
classpath_unboundVariablePath = Unbound classpath variable: ''{0}'' in project {1}
163
classpath_unboundVariablePath = Unbound classpath variable: ''{0}'' in project ''{1}''
164
classpath_unknownKind = Unknown kind: ''{0}''
164
classpath_unknownKind = Unknown kind: ''{0}''
165
classpath_xmlFormatError = XML format error in ''.classpath'' file of project {0}: {1}
165
classpath_xmlFormatError = XML format error in ''.classpath'' file of project ''{0}'': {1}
166
classpath_disabledInclusionExclusionPatterns = Inclusion or exclusion patterns are disabled in project {1}, cannot selectively include or exclude from entry: ''{0}''
166
classpath_disabledInclusionExclusionPatterns = Inclusion or exclusion patterns are disabled in project ''{1}'', cannot selectively include or exclude from entry: ''{0}''
167
classpath_disabledMultipleOutputLocations = Multiple output locations are disabled in project {1}, cannot associate entry: ''{0}'' with a specific output
167
classpath_disabledMultipleOutputLocations = Multiple output locations are disabled in project ''{1}'', cannot associate entry: ''{0}'' with a specific output
168
classpath_incompatibleLibraryJDKLevel = Incompatible .class files version in required binaries. Project ''{0}'' is targeting a {1} runtime, but is compiled against ''{2}'' which requires a {3} runtime
168
classpath_incompatibleLibraryJDKLevel = Incompatible .class files version in required binaries. Project ''{0}'' is targeting a {1} runtime, but is compiled against ''{2}'' which requires a {3} runtime
169
classpath_duplicateEntryExtraAttribute = Duplicate extra attribute: ''{0}'' in classpath entry ''{1}'' for project {2}
169
classpath_duplicateEntryExtraAttribute = Duplicate extra attribute: ''{0}'' in classpath entry ''{1}'' for project ''{2}''
170
classpath_deprecated_variable = Classpath variable ''{0}'' in project {1} is deprecated: ''{2}''
170
classpath_deprecated_variable = Classpath variable ''{0}'' in project ''{1}'' is deprecated: {2}
171
171
172
### miscellaneous
172
### miscellaneous
173
file_notFound = File not found: ''{0}''
173
file_notFound = File not found: ''{0}''

Return to bug 174348