Skip to content

Commit 0603bd4

Browse files
authored
Merge pull request #470 from TESTARtool/remote_web_actions_dev
Add webdriver remote action to LLM conversation
2 parents bb1529f + f07f761 commit 0603bd4

15 files changed

Lines changed: 711 additions & 286 deletions

File tree

CHANGELOG

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
#TESTAR v2.7.21 (24-Feb-2026)
1+
#TESTAR v2.7.23 (5-Mar-2026)
2+
- Update webdriver remote actions descriptions
3+
- Add webdriver remote actions to LLM conversation
4+
5+
#TESTAR v2.7.22 (24-Feb-2026)
26
- Bump org.seleniumhq.selenium:selenium-java from 4.40.0 to 4.41.0
37
- Update devtools dependencies to v145
48
- Ignore dynamic numbers when deduplicating AndroidLogcatOracle messages

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.7.22
1+
2.7.23

testar/src/org/testar/action/priorization/llm/ActionHistory.java

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/***************************************************************************************************
22
*
3-
* Copyright (c) 2024 - 2025 Open Universiteit - www.ou.nl
4-
* Copyright (c) 2024 - 2025 Universitat Politecnica de Valencia - www.upv.es
3+
* Copyright (c) 2024 - 2026 Open Universiteit - www.ou.nl
4+
* Copyright (c) 2024 - 2026 Universitat Politecnica de Valencia - www.upv.es
55
*
66
* Redistribution and use in source and binary forms, with or without
77
* modification, are permitted provided that the following conditions are met:
@@ -40,6 +40,7 @@
4040
import org.testar.monkey.alayer.actions.CompoundAction;
4141
import org.testar.monkey.alayer.actions.PasteText;
4242
import org.testar.monkey.alayer.actions.Type;
43+
import org.testar.monkey.alayer.actions.WdRemoteTypeAction;
4344
import org.testar.monkey.alayer.actions.WdSelectListAction;
4445

4546
import java.util.ArrayList;
@@ -122,11 +123,15 @@ public String toString() {
122123
switch(type) {
123124
case "ClickTypeInto":
124125
case "PasteTextInto":
126+
case "RemoteType":
127+
case "RemoteScrollType":
125128
String input = getCompoundActionInputText(action);
126129
// TODO: Differentiate between types of input fields (numeric, password, etc.)
127130
builder.append(String.format("%s: Typed '%s' in TextField '%s'", actionId, input, description));
128131
break;
129132
case "LeftClickAt":
133+
case "RemoteClick":
134+
case "RemoteScrollClick":
130135
builder.append(String.format("%s: Clicked on '%s'", actionId, description));
131136
break;
132137
case "HistoryBackScript":
@@ -176,6 +181,11 @@ private String getCompoundActionInputText(Action action) {
176181
}
177182
}
178183

184+
if(action instanceof WdRemoteTypeAction) {
185+
CharSequence input = ((WdRemoteTypeAction) action).getKeys();
186+
return input == null ? "Unknown Action Input" : input.toString();
187+
}
188+
179189
return action.get(Tags.InputText, "Unknown Action Input");
180190
}
181191
}

testar/src/org/testar/action/priorization/llm/LlmParseActionResponse.java

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/***************************************************************************************************
22
*
3-
* Copyright (c) 2025 Open Universiteit - www.ou.nl
4-
* Copyright (c) 2025 Universitat Politecnica de Valencia - www.upv.es
3+
* Copyright (c) 2025 - 2026 Open Universiteit - www.ou.nl
4+
* Copyright (c) 2025 - 2026 Universitat Politecnica de Valencia - www.upv.es
55
*
66
* Redistribution and use in source and binary forms, with or without
77
* modification, are permitted provided that the following conditions are met:
@@ -46,6 +46,7 @@
4646
import org.testar.monkey.alayer.actions.NOP;
4747
import org.testar.monkey.alayer.actions.PasteText;
4848
import org.testar.monkey.alayer.actions.Type;
49+
import org.testar.monkey.alayer.actions.WdRemoteTypeAction;
4950
import org.testar.monkey.alayer.actions.WdSelectListAction;
5051
import org.testar.monkey.alayer.visualizers.TextVisualizer;
5152
import org.testar.monkey.alayer.webdriver.enums.WdTags;
@@ -178,6 +179,11 @@ private boolean setCompoundActionInputText(Action action, String inputText) {
178179
}
179180

180181
private boolean updateTextAction(Action action, Action innerAction, String inputText) {
182+
if(action instanceof WdRemoteTypeAction) {
183+
((WdRemoteTypeAction) action).setKeys(inputText);
184+
return true;
185+
}
186+
181187
innerAction.set(Tags.InputText, inputText);
182188

183189
String widgetDesc = action.get(Tags.OriginWidget).get(Tags.Desc, "<no description>");

testar/src/org/testar/llm/prompt/ActionWebPromptGenerator.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/***************************************************************************************************
22
*
3-
* Copyright (c) 2024 - 2025 Open Universiteit - www.ou.nl
4-
* Copyright (c) 2024 - 2025 Universitat Politecnica de Valencia - www.upv.es
3+
* Copyright (c) 2024 - 2026 Open Universiteit - www.ou.nl
4+
* Copyright (c) 2024 - 2026 Universitat Politecnica de Valencia - www.upv.es
55
*
66
* Redistribution and use in source and binary forms, with or without
77
* modification, are permitted provided that the following conditions are met:
@@ -160,11 +160,15 @@ public String generateActionSelectionPrompt(Set<Action> actions, State state, Ac
160160
switch (type) {
161161
case "ClickTypeInto":
162162
case "PasteTextInto":
163+
case "RemoteType":
164+
case "RemoteScrollType":
163165
// Differentiate between types of input fields. Example: password -> Password Field
164166
String fieldType = StringUtils.capitalize(widget.get(WdTags.WebType, "text"));
165167
builder.append(String.format("%s: Type in %sField '%s' ", actionId, fieldType, description));
166168
break;
167169
case "LeftClickAt":
170+
case "RemoteClick":
171+
case "RemoteScrollClick":
168172
builder.append(String.format("%s: Click on '%s' ", actionId, description));
169173
break;
170174
case "HistoryBackScript":

testar/src/org/testar/monkey/Main.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464

6565
public class Main {
6666

67-
public static final String TESTAR_VERSION = "v2.7.22 (24-Feb-2026)";
67+
public static final String TESTAR_VERSION = "v2.7.23 (5-Mar-2026)";
6868

6969
//public static final String TESTAR_DIR_PROPERTY = "DIRNAME"; //Use the OS environment to obtain TESTAR directory
7070
public static final String SETTINGS_FILE = "test.settings";

0 commit comments

Comments
 (0)