Skip to content

Commit

Permalink
Fix for issue #195
Browse files Browse the repository at this point in the history
  • Loading branch information
tsantalis committed Nov 20, 2024
1 parent 2de7b96 commit 8e13ab9
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 18 deletions.
1 change: 1 addition & 0 deletions src/main/java/org/codetracker/HistoryImpl.java
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ public String getCommitterName() {
@Override
public int compareTo(HistoryInfo<C> toCompare) {
return Comparator.comparing(HistoryInfo<C>::getCommitTime)
.thenComparing(HistoryInfo<C>::getAuthoredTime)
.thenComparing(HistoryInfo<C>::getChangeType)
.compare(this, toCompare);
}
Expand Down
2 changes: 1 addition & 1 deletion src/test/resources/blame/blameTestUntilCommitZero3.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ a2783ed22 java/compiler/impl/src/com/intellij/compiler/actions/CompileDirtyActio
7460e5ada source/com/intellij/compiler/actions/CompileDirtyAction.java (Maxim Shafirov 2005-01-13 20:44:30 +0000 25) public class CompileDirtyAction extends CompileActionBase {
26)
7460e5ada source/com/intellij/compiler/actions/CompileDirtyAction.java (Maxim Shafirov 2005-01-13 20:44:30 +0000 27) protected void doAction(DataContext dataContext, Project project) {
0104f1489 java/compiler/impl/src/com/intellij/compiler/actions/CompileDirtyAction.java (Vladislav.Soroka 2016-09-21 09:30:57 +0000 28) ProjectTaskManager.getInstance(project).buildAllModules();
53ddd10a4 java/compiler/impl/src/com/intellij/compiler/actions/CompileDirtyAction.java (Vladislav.Soroka 2016-09-21 09:30:57 +0000 28) ProjectTaskManager.getInstance(project).buildAllModules();
7460e5ada source/com/intellij/compiler/actions/CompileDirtyAction.java (Maxim Shafirov 2005-01-13 20:44:30 +0000 29) }
30)
a2783ed22 java/compiler/impl/src/com/intellij/compiler/actions/CompileDirtyAction.java (Alexey Kudravtsev 2018-08-06 12:29:49 +0000 31) public void update(@NotNull AnActionEvent e){
Expand Down
6 changes: 3 additions & 3 deletions src/test/resources/blame/blameTestWithLocalRepo4.txt
Original file line number Diff line number Diff line change
Expand Up @@ -407,12 +407,12 @@ b8035a7ac javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpre
2d3f5e219 javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 407) Integer lastElementIndex = removedGroup.getLastElementIndex();
2d3f5e219 javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 408) Optional<Integer> indentation = removedGroup.getIndentation();
409)
4f9e0c67e javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 410) if (indentation.isPresent() && !isReplaced(lastElementIndex)) {
b8035a7ac javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 410) if (indentation.isPresent() && !isReplaced(lastElementIndex)) {
2d3f5e219 javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 411) for (int i = 0; i < indentation.get(); i++) {
4f9e0c67e javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 412) if (originalElements.get(originalIndex).isSpaceOrTab()) {
b8035a7ac javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 412) if (originalElements.get(originalIndex).isSpaceOrTab()) {
b8035a7ac javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 413) // If the current element is a space, remove it
2d3f5e219 javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 414) nodeText.removeElement(originalIndex);
b8035a7ac javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 415) } else if (originalIndex >= 1 && originalElements.get(originalIndex - 1).isSpaceOrTab()) {
5b277fef9 javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 415) } else if (originalIndex >= 1 && originalElements.get(originalIndex - 1).isSpaceOrTab()) {
b8035a7ac javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 416) // If the current element is not a space itself we remove the space in front of it
4f9e0c67e javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 417) nodeText.removeElement(originalIndex - 1);
4f9e0c67e javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java (Thomas Leu 2018-06-07 20:54:17 +0000 418) originalIndex--;
Expand Down
2 changes: 1 addition & 1 deletion src/test/resources/blame/blameTestWithLocalRepo7.txt
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ c2d9a533b junit5-engine/src/main/java/org/junit/gen5/engine/junit5/descriptor/Cl
9693d5389 junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/descriptor/ClassTestDescriptor.java (Marc Philipp 2018-06-10 10:56:39 +0000 203) public void after(JupiterEngineExecutionContext context) {
204)
137f831bb junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/descriptor/ClassTestDescriptor.java (Marc Philipp 2018-07-07 20:15:38 +0000 205) ThrowableCollector throwableCollector = context.getThrowableCollector();
c1d682aee junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/descriptor/ClassTestDescriptor.java (Marc Philipp 2018-07-07 20:15:38 +0000 206) Throwable previousThrowable = throwableCollector.getThrowable();
137f831bb junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/descriptor/ClassTestDescriptor.java (Marc Philipp 2018-07-07 20:15:38 +0000 206) Throwable previousThrowable = throwableCollector.getThrowable();
207)
62c433c14 junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/descriptor/ClassTestDescriptor.java (Sam Brannen 2016-06-25 19:29:20 +0000 208) if (context.beforeAllMethodsExecuted()) {
3e3b40213 junit-jupiter-engine/src/main/java/org/junit/jupiter/engine/descriptor/ClassTestDescriptor.java (Sam Brannen 2016-06-25 20:02:49 +0000 209) invokeAfterAllMethods(context);
Expand Down
Loading

0 comments on commit 8e13ab9

Please sign in to comment.