Skip to content

Commit

Permalink
Code coverage was not working in HTTP proc in Java (#907)
Browse files Browse the repository at this point in the history
Issue: 201799
  • Loading branch information
iroqueta authored Nov 6, 2024
1 parent 610d928 commit ac52594
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 37 deletions.
37 changes: 0 additions & 37 deletions gxweb/src/main/java/com/genexus/webpanels/GXWebObjectBase.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
import com.genexus.configuration.ConfigurationManager;
import com.genexus.diagnostics.core.ILogger;
import com.genexus.diagnostics.core.LogManager;
import com.genexus.diagnostics.GXDebugInfo;
import com.genexus.diagnostics.GXDebugManager;
import com.genexus.internet.HttpAjaxContext;
import com.genexus.internet.GXInternetConstants;
import com.genexus.internet.HttpContext;
Expand Down Expand Up @@ -217,41 +215,6 @@ protected String getPgmInstanceId(String cmpCtx)
return String.format("%s%s", cmpCtx, this.getPgmname().toUpperCase());
}

private GXDebugInfo dbgInfo = null;
protected void trkCleanup()
{
if(dbgInfo != null)
dbgInfo.onCleanup();
}

protected void initialize(int objClass, int objId, int dbgLines, long hash)
{
dbgInfo = GXDebugManager.getInstance().getDbgInfo(context, objClass, objId, dbgLines, hash);
}

protected void trk(int lineNro)
{
if(dbgInfo != null)
dbgInfo.trk(lineNro);
}

protected void trk(int lineNro, int lineNro2)
{
if(dbgInfo != null)
dbgInfo.trk(lineNro, lineNro2);
}

protected void trkrng(int lineNro, int lineNro2)
{
trkrng(lineNro, 0, lineNro2, 0);
}

protected void trkrng(int lineNro, int colNro, int lineNro2, int colNro2)
{
if(dbgInfo != null)
dbgInfo.trkRng(lineNro, colNro, lineNro2, colNro2);
}

protected void callWebObject(String url)
{
httpContext.wjLoc = url;
Expand Down
37 changes: 37 additions & 0 deletions java/src/main/java/com/genexus/GXObjectBase.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

import com.genexus.db.Namespace;
import com.genexus.db.UserInformation;
import com.genexus.diagnostics.GXDebugInfo;
import com.genexus.diagnostics.GXDebugManager;
import com.genexus.diagnostics.core.ILogger;
import com.genexus.diagnostics.core.LogManager;
import com.genexus.internet.HttpContext;
Expand Down Expand Up @@ -224,4 +226,39 @@ public void submit(int id, Object [] submitParms){
}
public void submitReorg(int id, Object [] submitParms) throws SQLException {
}

private GXDebugInfo dbgInfo = null;
protected void trkCleanup()
{
if(dbgInfo != null)
dbgInfo.onCleanup();
}

protected void initialize(int objClass, int objId, int dbgLines, long hash)
{
dbgInfo = GXDebugManager.getInstance().getDbgInfo(context, objClass, objId, dbgLines, hash);
}

protected void trk(int lineNro)
{
if(dbgInfo != null)
dbgInfo.trk(lineNro);
}

protected void trk(int lineNro, int lineNro2)
{
if(dbgInfo != null)
dbgInfo.trk(lineNro, lineNro2);
}

protected void trkrng(int lineNro, int lineNro2)
{
trkrng(lineNro, 0, lineNro2, 0);
}

protected void trkrng(int lineNro, int colNro, int lineNro2, int colNro2)
{
if(dbgInfo != null)
dbgInfo.trkRng(lineNro, colNro, lineNro2, colNro2);
}
}

0 comments on commit ac52594

Please sign in to comment.