WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Commit 478fefe

Browse files
committed
fix failing tests and resolve coderabbitai comment
1 parent 1576552 commit 478fefe

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

app/server/appsmith-server/src/main/java/com/appsmith/server/aspect/ce/GitRouteAspectCE.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -593,7 +593,7 @@ protected Mono<?> getLocalBranches(Context ctx) {
593593
*/
594594
protected Mono<?> clone(Context ctx) {
595595
List<String> metaArgs = List.of(
596-
ctx.getGitProfile().getAuthorName(),
596+
ctx.getGitProfile().getAuthorEmail(),
597597
ctx.getGitProfile().getAuthorName(),
598598
ctx.getGitKey(),
599599
ctx.getGitMeta().getRemoteUrl(),

app/server/appsmith-server/src/test/java/com/appsmith/server/aspect/GitRouteAspectTest.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import com.appsmith.external.git.constants.ce.RefType;
44
import com.appsmith.server.annotations.GitRoute;
55
import com.appsmith.server.artifacts.gitRoute.GitRouteArtifact;
6+
import com.appsmith.server.aspect.ce.GitRouteAspectCE;
67
import com.appsmith.server.constants.ArtifactType;
78
import com.appsmith.server.domains.Application;
89
import com.appsmith.server.domains.Artifact;
@@ -66,7 +67,7 @@ void setUp() {
6667
// ---------------------- Helpers ----------------------
6768

6869
private static Class<?> contextClass() throws Exception {
69-
return Class.forName("com.appsmith.server.aspect.GitRouteAspect$Context");
70+
return Class.forName("com.appsmith.server.aspect.ce.GitRouteAspectCE$Context");
7071
}
7172

7273
private static Object newContext() throws Exception {
@@ -90,7 +91,8 @@ private static Object getCtx(Object ctx, String field) throws Exception {
9091

9192
@SuppressWarnings("unchecked")
9293
private <T> Mono<T> invokeMono(String methodName, Class<?>[] paramTypes, Object... args) throws Exception {
93-
Method m = GitRouteAspect.class.getDeclaredMethod(methodName, paramTypes);
94+
// Methods are in GitRouteAspectCE, but accessible through GitRouteAspect
95+
Method m = GitRouteAspectCE.class.getDeclaredMethod(methodName, paramTypes);
9496
m.setAccessible(true);
9597
return (Mono<T>) m.invoke(aspect, args);
9698
}

0 commit comments

Comments
 (0)