Lines 358-366
Link Here
|
358 |
fullBuild(); |
358 |
fullBuild(); |
359 |
|
359 |
|
360 |
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$ |
360 |
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 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
361 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
362 |
expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
362 |
expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
363 |
expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
363 |
expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
364 |
|
364 |
|
365 |
JavaCore.setOptions(options); |
365 |
JavaCore.setOptions(options); |
366 |
} finally { |
366 |
} finally { |
Lines 452-463
Link Here
|
452 |
fullBuild(); |
452 |
fullBuild(); |
453 |
|
453 |
|
454 |
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$ |
454 |
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 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
455 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
456 |
expectingOnlySpecificProblemsFor(p2,new Problem[]{ |
456 |
expectingOnlySpecificProblemsFor(p2,new Problem[]{ |
457 |
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),//$NON-NLS-1$ //$NON-NLS-2$ |
457 |
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),//$NON-NLS-1$ //$NON-NLS-2$ |
458 |
new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, -1)//$NON-NLS-1$ //$NON-NLS-2$ |
458 |
new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH)//$NON-NLS-1$ //$NON-NLS-2$ |
459 |
}); |
459 |
}); |
460 |
expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
460 |
expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
461 |
|
461 |
|
462 |
JavaCore.setOptions(options); |
462 |
JavaCore.setOptions(options); |
463 |
} finally { |
463 |
} finally { |
Lines 549-557
Link Here
|
549 |
fullBuild(); |
549 |
fullBuild(); |
550 |
|
550 |
|
551 |
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$ |
551 |
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 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
552 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
553 |
expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
553 |
expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
554 |
expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
554 |
expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
555 |
|
555 |
|
556 |
env.addClass(root1, "p1", "X", //$NON-NLS-1$ //$NON-NLS-2$ |
556 |
env.addClass(root1, "p1", "X", //$NON-NLS-1$ //$NON-NLS-2$ |
557 |
"package p1;\n"+ //$NON-NLS-1$ |
557 |
"package p1;\n"+ //$NON-NLS-1$ |
Lines 565-576
Link Here
|
565 |
incrementalBuild(); |
565 |
incrementalBuild(); |
566 |
|
566 |
|
567 |
expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z"}); //$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ |
567 |
expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p3.Z"}); //$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ |
568 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
568 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
569 |
expectingOnlySpecificProblemsFor(p2,new Problem[]{ |
569 |
expectingOnlySpecificProblemsFor(p2,new Problem[]{ |
570 |
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),//$NON-NLS-1$ //$NON-NLS-2$ |
570 |
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),//$NON-NLS-1$ //$NON-NLS-2$ |
571 |
new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, -1)//$NON-NLS-1$ //$NON-NLS-2$ |
571 |
new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH)//$NON-NLS-1$ //$NON-NLS-2$ |
572 |
}); |
572 |
}); |
573 |
expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
573 |
expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
574 |
|
574 |
|
575 |
JavaCore.setOptions(options); |
575 |
JavaCore.setOptions(options); |
576 |
} finally { |
576 |
} finally { |
Lines 651-668
Link Here
|
651 |
fullBuild(); |
651 |
fullBuild(); |
652 |
|
652 |
|
653 |
expectingCompilingOrder(new String[]{"p2.Y", "p3.Z", "p2.Y"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ |
653 |
expectingCompilingOrder(new String[]{"p2.Y", "p3.Z", "p2.Y"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ |
654 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
654 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
655 |
expectingOnlySpecificProblemsFor(p2,new Problem[]{ |
655 |
expectingOnlySpecificProblemsFor(p2,new Problem[]{ |
656 |
new Problem("p2", "The import p1 cannot be resolved", c2, 19, 21, CategorizedProblem.CAT_IMPORT),//$NON-NLS-1$ //$NON-NLS-2$ |
656 |
new Problem("p2", "The import p1 cannot be resolved", c2, 19, 21, CategorizedProblem.CAT_IMPORT),//$NON-NLS-1$ //$NON-NLS-2$ |
657 |
new Problem("p2", "X cannot be resolved to a type", c2, 73, 74, CategorizedProblem.CAT_TYPE),//$NON-NLS-1$ //$NON-NLS-2$ |
657 |
new Problem("p2", "X cannot be resolved to a type", c2, 73, 74, CategorizedProblem.CAT_TYPE),//$NON-NLS-1$ //$NON-NLS-2$ |
658 |
new Problem("p2", "X cannot be resolved to a type", c2, 87, 88, CategorizedProblem.CAT_TYPE),//$NON-NLS-1$ //$NON-NLS-2$ |
658 |
new Problem("p2", "X cannot be resolved to a type", c2, 87, 88, CategorizedProblem.CAT_TYPE),//$NON-NLS-1$ //$NON-NLS-2$ |
659 |
new Problem("p2", "The method foo() is undefined for the type Y", c2, 93, 96, CategorizedProblem.CAT_MEMBER),//$NON-NLS-1$ //$NON-NLS-2$ |
659 |
new Problem("p2", "The method foo() is undefined for the type Y", c2, 93, 96, CategorizedProblem.CAT_MEMBER),//$NON-NLS-1$ //$NON-NLS-2$ |
660 |
new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, -1)//$NON-NLS-1$ //$NON-NLS-2$ |
660 |
new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH)//$NON-NLS-1$ //$NON-NLS-2$ |
661 |
}); |
661 |
}); |
662 |
expectingOnlySpecificProblemsFor(p3,new Problem[]{ |
662 |
expectingOnlySpecificProblemsFor(p3,new Problem[]{ |
663 |
new Problem("p3", "X cannot be resolved to a type", c3, 51, 52, CategorizedProblem.CAT_TYPE),//$NON-NLS-1$ //$NON-NLS-2$ |
663 |
new Problem("p3", "X cannot be resolved to a type", c3, 51, 52, CategorizedProblem.CAT_TYPE),//$NON-NLS-1$ //$NON-NLS-2$ |
664 |
new Problem("p3", "The import p1 cannot be resolved", c3, 19, 21, CategorizedProblem.CAT_IMPORT),//$NON-NLS-1$ //$NON-NLS-2$ |
664 |
new Problem("p3", "The import p1 cannot be resolved", c3, 19, 21, CategorizedProblem.CAT_IMPORT),//$NON-NLS-1$ //$NON-NLS-2$ |
665 |
new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, -1)//$NON-NLS-1$ //$NON-NLS-2$ |
665 |
new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH)//$NON-NLS-1$ //$NON-NLS-2$ |
666 |
}); |
666 |
}); |
667 |
|
667 |
|
668 |
env.addClass(root1, "p1", "X", //$NON-NLS-1$ //$NON-NLS-2$ |
668 |
env.addClass(root1, "p1", "X", //$NON-NLS-1$ //$NON-NLS-2$ |
Lines 676-684
Link Here
|
676 |
); |
676 |
); |
677 |
incrementalBuild(); |
677 |
incrementalBuild(); |
678 |
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$ |
678 |
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 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
679 |
expectingOnlySpecificProblemFor(p1,new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
680 |
expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
680 |
expectingOnlySpecificProblemFor(p2,new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
681 |
expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, -1));//$NON-NLS-1$ //$NON-NLS-2$ |
681 |
expectingOnlySpecificProblemFor(p3,new Problem("p3", "A cycle was detected in the build path of project: P3", p3, -1, -1, CategorizedProblem.CAT_BUILDPATH));//$NON-NLS-1$ //$NON-NLS-2$ |
682 |
|
682 |
|
683 |
JavaCore.setOptions(options); |
683 |
JavaCore.setOptions(options); |
684 |
} finally { |
684 |
} finally { |
Lines 744-754
Link Here
|
744 |
expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p1.X", "p2.Y"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$ |
744 |
expectingCompilingOrder(new String[]{"p1.X", "p2.Y", "p1.X", "p2.Y"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$ |
745 |
expectingOnlySpecificProblemsFor(p1,new Problem[]{ |
745 |
expectingOnlySpecificProblemsFor(p1,new Problem[]{ |
746 |
new Problem("p1", "The import p22 cannot be resolved", c1, 32, 35, CategorizedProblem.CAT_IMPORT),//$NON-NLS-1$ //$NON-NLS-2$ |
746 |
new Problem("p1", "The import p22 cannot be resolved", c1, 32, 35, CategorizedProblem.CAT_IMPORT),//$NON-NLS-1$ //$NON-NLS-2$ |
747 |
new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, -1)//$NON-NLS-1$ //$NON-NLS-2$ |
747 |
new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH)//$NON-NLS-1$ //$NON-NLS-2$ |
748 |
}); |
748 |
}); |
749 |
expectingOnlySpecificProblemsFor(p2,new Problem[]{ |
749 |
expectingOnlySpecificProblemsFor(p2,new Problem[]{ |
750 |
new Problem("p2", "The import p11 cannot be resolved", c2, 32, 35, CategorizedProblem.CAT_IMPORT),//$NON-NLS-1$ //$NON-NLS-2$ |
750 |
new Problem("p2", "The import p11 cannot be resolved", c2, 32, 35, CategorizedProblem.CAT_IMPORT),//$NON-NLS-1$ //$NON-NLS-2$ |
751 |
new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, -1)//$NON-NLS-1$ //$NON-NLS-2$ |
751 |
new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH)//$NON-NLS-1$ //$NON-NLS-2$ |
752 |
}); |
752 |
}); |
753 |
|
753 |
|
754 |
env.addClass(root1, "p11", "XX", //$NON-NLS-1$ //$NON-NLS-2$ |
754 |
env.addClass(root1, "p11", "XX", //$NON-NLS-1$ //$NON-NLS-2$ |
Lines 767-777
Link Here
|
767 |
expectingCompilingOrder(new String[]{"p11.XX", "p22.YY", "p2.Y", "p1.X"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$ |
767 |
expectingCompilingOrder(new String[]{"p11.XX", "p22.YY", "p2.Y", "p1.X"});//$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$ //$NON-NLS-4$ |
768 |
expectingOnlySpecificProblemsFor(p1,new Problem[]{ |
768 |
expectingOnlySpecificProblemsFor(p1,new Problem[]{ |
769 |
new Problem("p1", "The import p22 is never used", c1, 32, 35, CategorizedProblem.CAT_UNNECESSARY_CODE),//$NON-NLS-1$ //$NON-NLS-2$ |
769 |
new Problem("p1", "The import p22 is never used", c1, 32, 35, CategorizedProblem.CAT_UNNECESSARY_CODE),//$NON-NLS-1$ //$NON-NLS-2$ |
770 |
new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, -1)//$NON-NLS-1$ //$NON-NLS-2$ |
770 |
new Problem("p1", "A cycle was detected in the build path of project: P1", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH)//$NON-NLS-1$ //$NON-NLS-2$ |
771 |
}); |
771 |
}); |
772 |
expectingOnlySpecificProblemsFor(p2,new Problem[]{ |
772 |
expectingOnlySpecificProblemsFor(p2,new Problem[]{ |
773 |
new Problem("p2", "The import p11 is never used", c2, 32, 35, CategorizedProblem.CAT_UNNECESSARY_CODE),//$NON-NLS-1$ //$NON-NLS-2$ |
773 |
new Problem("p2", "The import p11 is never used", c2, 32, 35, CategorizedProblem.CAT_UNNECESSARY_CODE),//$NON-NLS-1$ //$NON-NLS-2$ |
774 |
new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, -1)//$NON-NLS-1$ //$NON-NLS-2$ |
774 |
new Problem("p2", "A cycle was detected in the build path of project: P2", p2, -1, -1, CategorizedProblem.CAT_BUILDPATH)//$NON-NLS-1$ //$NON-NLS-2$ |
775 |
}); |
775 |
}); |
776 |
|
776 |
|
777 |
JavaCore.setOptions(options); |
777 |
JavaCore.setOptions(options); |
Lines 1217-1223
Link Here
|
1217 |
|
1217 |
|
1218 |
expectingOnlySpecificProblemsFor(p1,new Problem[]{ |
1218 |
expectingOnlySpecificProblemsFor(p1,new Problem[]{ |
1219 |
new Problem("p1", "The type p3.Z cannot be resolved. It is indirectly referenced from required .class files", x, 48, 49, CategorizedProblem.CAT_BUILDPATH),//$NON-NLS-1$ //$NON-NLS-2$ |
1219 |
new Problem("p1", "The type p3.Z cannot be resolved. It is indirectly referenced from required .class files", x, 48, 49, CategorizedProblem.CAT_BUILDPATH),//$NON-NLS-1$ //$NON-NLS-2$ |
1220 |
new Problem("p1", "The project was not built since its build path is incomplete. Cannot find the class file for p3.Z. Fix the build path then try building this project", p1, -1, -1, -1)//$NON-NLS-1$ //$NON-NLS-2$ |
1220 |
new Problem("p1", "The project was not built since its build path is incomplete. Cannot find the class file for p3.Z. Fix the build path then try building this project", p1, -1, -1, CategorizedProblem.CAT_BUILDPATH)//$NON-NLS-1$ //$NON-NLS-2$ |
1221 |
}); |
1221 |
}); |
1222 |
} finally { |
1222 |
} finally { |
1223 |
env.setBuildOrder(null); |
1223 |
env.setBuildOrder(null); |