Fixed automatic project launch from product definition editor Requires
explicit guava inclusion (dangerous operation, requires retest of RCPTT
installation from update site). Fixed infinite remote launch
configuration tab update. Adapted tests to reflect change in code
information tooltip The browser control was replaced with edit box.
Change-Id: I8b1e4f73ffb9345731b26c3f5b5e41165b216627
diff --git a/launching/org.eclipse.rcptt.launching-feature/feature.xml b/launching/org.eclipse.rcptt.launching-feature/feature.xml
index 4d85e48..4d49907 100644
--- a/launching/org.eclipse.rcptt.launching-feature/feature.xml
+++ b/launching/org.eclipse.rcptt.launching-feature/feature.xml
@@ -9,7 +9,6 @@
Contributors:
Xored Software Inc - initial API and implementation and/or initial documentation
-->
-
<feature
id="org.eclipse.rcptt.launching"
label="RCPTT launching components"
@@ -112,4 +111,11 @@
version="2.2.0.qualifier"
unpack="false"/>
+ <plugin
+ id="com.google.guava"
+ download-size="0"
+ install-size="0"
+ version="0.0.0"
+ unpack="false"/>
+
</feature>
diff --git a/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/AUTArgumentsBlock.java b/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/AUTArgumentsBlock.java
index 2c8738c..4af97ac 100644
--- a/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/AUTArgumentsBlock.java
+++ b/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/AUTArgumentsBlock.java
@@ -14,6 +14,8 @@
import org.eclipse.debug.core.ILaunchConfiguration;
import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.rcptt.launching.IQ7Launch;
+import org.eclipse.rcptt.launching.Q7LaunchUtils;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.ModifyEvent;
import org.eclipse.swt.events.ModifyListener;
@@ -26,9 +28,6 @@
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Text;
-import org.eclipse.rcptt.launching.IQ7Launch;
-import org.eclipse.rcptt.launching.Q7LaunchUtils;
-
public final class AUTArgumentsBlock {
private RemoteAUTMainTab fTab;
@@ -39,9 +38,10 @@
private Text hostField;
ModifyListener listener = new ModifyListener() {
+ @Override
public void modifyText(ModifyEvent e) {
// fT3ab.validateTab();
- fTab.scheduleUpdateJob();
+ fTab.updateLaunchConfigurationDialog();
}
};
@@ -85,6 +85,7 @@
teslaPortField.addModifyListener(listener);
VerifyListener verity = new VerifyListener() {
+ @Override
public void verifyText(VerifyEvent e) {
for (char c : e.text.toCharArray()) {
if (!Character.isDigit(c)) {
@@ -102,6 +103,7 @@
final int port[] = { 0 };
if (hostField != null && !hostField.isDisposed()) {
hostField.getDisplay().syncExec(new Runnable() {
+ @Override
public void run() {
hostName[0] = getHostName();
port[0] = getECLPort();
diff --git a/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/RemoteAUTMainTab.java b/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/RemoteAUTMainTab.java
index 2773bfd..f5e3fdd 100644
--- a/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/RemoteAUTMainTab.java
+++ b/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/RemoteAUTMainTab.java
@@ -28,58 +28,56 @@
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Event;
import org.eclipse.swt.widgets.Listener;
-import org.eclipse.ui.progress.WorkbenchJob;
public class RemoteAUTMainTab extends AbstractLaunchConfigurationTab {
private AUTArgumentsBlock fLocationBlock;
// private ILaunchConfigurationTab[] tabs;
// private RemoteTabGroup group;
- private Job fRereshJob;
- private Job validateJob;
+ private final Job validateJob = new Job("Connection validate job") {
+ {
+ setSystem(true);
+ }
+ @Override
+ protected IStatus run(IProgressMonitor monitor) {
+ String lastMessage = getErrorMessage();
+ String msg = fLocationBlock.validate();
+ if ((msg == null && lastMessage == null) || msg != null && msg.equals(lastMessage)) {
+ return Status.OK_STATUS;
+ }
+ setErrorMessage(msg);
+ final Control control = RemoteAUTMainTab.super.getControl();
+ if (control.isDisposed()) {
+ return Status.OK_STATUS;
+ }
+ control.getDisplay().asyncExec(new Runnable() {
+ @Override
+ public void run() {
+ if (!control.isDisposed()) {
+ updateLaunchConfigurationDialog();
+ }
+ }
+ });
+ return Status.OK_STATUS;
+ }
+
+ };
- public RemoteAUTMainTab(RemoteTabGroup group) {
+
+ public RemoteAUTMainTab() {
super();
- // this.group = group;
createLocationBlock();
}
- protected Job createUpdateJob() {
- return new WorkbenchJob(getControl().getDisplay(), "Update LCD") { //$NON-NLS-1$
- public IStatus runInUIThread(IProgressMonitor monitor) {
- if (!getControl().isDisposed()) {
- updateLaunchConfigurationDialog();
- }
- return Status.OK_STATUS;
- }
-
- public boolean shouldRun() {
- return !getControl().isDisposed();
- }
- };
- }
-
+ @Override
protected long getUpdateJobDelay() {
return 200;
}
- private Job getUpdateJob() {
- if (fRereshJob == null) {
- fRereshJob = createUpdateJob();
- fRereshJob.setSystem(true);
- }
- return fRereshJob;
- }
-
- protected void scheduleUpdateJob() {
- Job job = getUpdateJob();
- job.cancel(); // cancel existing job
- job.schedule(getUpdateJobDelay());
- }
-
@Override
protected void updateLaunchConfigurationDialog() {
- validateTab();
+ validateJob.cancel();
+ validateJob.schedule();
super.updateLaunchConfigurationDialog();
}
@@ -87,6 +85,7 @@
fLocationBlock = new AUTArgumentsBlock(this);
}
+ @Override
public void createControl(Composite parent) {
final ScrolledComposite scrollContainer = new ScrolledComposite(parent,
SWT.V_SCROLL);
@@ -104,6 +103,7 @@
// This results in scrollbar scrolling when user tabs to a control that
// is not in the field of view.
Listener listener = new Listener() {
+ @Override
public void handleEvent(Event e) {
Control child = (Control) e.widget;
Rectangle bounds = child.getBounds();
@@ -132,51 +132,22 @@
setControl(scrollContainer);
}
+ @Override
public void initializeFrom(ILaunchConfiguration config) {
fLocationBlock.initializeFrom(config);
}
- private Job validateJob() {
- if (validateJob == null) {
- validateJob = new Job("Connection validate job") {
- @Override
- protected IStatus run(IProgressMonitor monitor) {
- setErrorMessage(null);
- setMessage(null);
- String msg = fLocationBlock.validate();
- if (msg != null) {
- setErrorMessage(msg);
- }
- Control control = RemoteAUTMainTab.super.getControl();
- if (control.isDisposed()) {
- return Status.OK_STATUS;
- }
- control.getDisplay().asyncExec(new Runnable() {
- public void run() {
- updateLaunchConfigurationDialog();
- }
- });
- return Status.OK_STATUS;
- }
- };
- validateJob.setSystem(true);
- }
- return validateJob;
- }
-
- public void validateTab() {
- validateJob().cancel();
- validateJob().schedule(500);
- }
-
+ @Override
public void performApply(ILaunchConfigurationWorkingCopy config) {
fLocationBlock.performApply(config);
}
+ @Override
public void setDefaults(ILaunchConfigurationWorkingCopy config) {
fLocationBlock.setDefaults(config);
}
+ @Override
public String getName() {
return "Remote AUT Launch configuration";
}
diff --git a/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/RemoteTabGroup.java b/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/RemoteTabGroup.java
index 0bfc8fb..eab3033 100644
--- a/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/RemoteTabGroup.java
+++ b/rcp/org.eclipse.rcptt.launching.remote.ui/src/org/eclipse/rcptt/internal/launching/remote/ui/RemoteTabGroup.java
@@ -18,9 +18,10 @@
public class RemoteTabGroup extends AbstractLaunchConfigurationTabGroup {
+ @Override
public void createTabs(ILaunchConfigurationDialog dialog, String mode) {
ILaunchConfigurationTab[] tabs = null;
- tabs = new ILaunchConfigurationTab[] { new RemoteAUTMainTab(this),
+ tabs = new ILaunchConfigurationTab[] { new RemoteAUTMainTab(),
new CommonTab() };
setTabs(tabs);
}
diff --git a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment 1-line.test b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment 1-line.test
index 851846c..52b5f07 100644
--- a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment 1-line.test
+++ b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment 1-line.test
@@ -6,8 +6,8 @@
Element-Version: 3.0
External-Reference:
Id: _bUx9oCbQEeSJvYFSUnsXEQ
-Runtime-Version: 1.5.2.201408180747
-Save-Time: 8/22/14 5:16 PM
+Runtime-Version: 2.2.0.201612300018
+Save-Time: 2/3/17 5:08 PM
Testcase-Type: ecl
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac
@@ -24,7 +24,7 @@
key-type Enter
}
get-editor "New Java Class Procs" | get-section Script | get-text-viewer | hover-text 36 9 -with Left
-get-window -from "Information Window" | get-control Browser | get-property text -raw | invoke toLowerCase |
+get-window -from "Information Window" | get-editbox | get-property text -raw | invoke toLowerCase |
invoke contains "description of create-java-class procedure" | verify-true
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac--
diff --git a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment 2-lines.test b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment 2-lines.test
index 81b730c..9fa8b84 100644
--- a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment 2-lines.test
+++ b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment 2-lines.test
@@ -6,8 +6,8 @@
Element-Version: 3.0
External-Reference:
Id: _pLJ3kCbQEeSJvYFSUnsXEQ
-Runtime-Version: 1.5.2.201408180747
-Save-Time: 8/22/14 5:25 PM
+Runtime-Version: 2.2.0.201612300018
+Save-Time: 2/3/17 9:08 PM
Testcase-Type: ecl
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac
@@ -26,8 +26,10 @@
key-type Enter
}
get-editor "New Java Class Procs" | get-section Script | get-text-viewer | hover-text 36 9 -with Left
-get-window -from "Information Window" | get-control Browser | get-property text -raw | invoke toLowerCase | invoke contains "procedure <b>create-java-class</b>" | verify-true
-get-window -from "Information Window" | get-control Browser | get-property text -raw | invoke toLowerCase | invoke contains "description of create-java-class procedure second description line" | verify-true
+with [get-window -from "Information Window" | get-editbox | get-property text -raw | invoke toLowerCase ] {
+ invoke contains "procedure <b>create-java-class</b>" | verify-true
+ invoke contains "description of create-java-class procedure second description line" | verify-true
+}
// Adds linebreak
with [get-editor "New Java Class Procs" | get-section Script | get-text-viewer] {
@@ -35,9 +37,11 @@
key-type Enter
}
get-editor "New Java Class Procs" | get-section Script | get-text-viewer | hover-text 36 9 -with Left
-get-window -from "Information Window" | get-control Browser | get-property text -raw | invoke toLowerCase | invoke contains "procedure <b>create-java-class</b>"
-get-window -from "Information Window" | get-control Browser | get-property text -raw | invoke toLowerCase | invoke contains "description of create-java-class procedure second description line" | verify-false
-get-window -from "Information Window" | get-control Browser | get-property text -raw | invoke toLowerCase | invoke contains "second description line" | verify-true
+with [get-window -from "Information Window" | get-editbox | get-property text -raw | invoke toLowerCase ] {
+ invoke contains "procedure <b>create-java-class</b>"
+ invoke contains "description of create-java-class procedure second description line" | verify-false
+ invoke contains "second description line" | verify-true
+}
//"Procedure <b>create-java-class</b>\\n"
// + "<br /> Description of create-java-class procedure Second description line\\n"
diff --git a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment javadoc.test b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment javadoc.test
index 1f14252..4c43b66 100644
--- a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment javadoc.test
+++ b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Comment javadoc.test
@@ -6,8 +6,8 @@
Element-Version: 3.0
External-Reference:
Id: _GG-CECaOEeS4ZoAAFrP9Rg
-Runtime-Version: 1.5.4.201411241327
-Save-Time: 12/1/14 1:28 PM
+Runtime-Version: 2.2.0.201612300018
+Save-Time: 2/3/17 8:46 PM
Testcase-Type: ecl
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac
@@ -27,8 +27,8 @@
key-type Enter
}
get-editor "New Java Class Procs" | get-section Script | get-text-viewer | hover-text 36 9 -with Left
- with [get-window -from "Information Window" | get-control Browser | get-property text -raw | invoke toLowerCase]{
-invoke contains "procedure <b>open-new-class-dialog</b>" | verify-true
-invoke contains "description of open-new-class-dialog"| verify-true
- }
+with [get-window -from "Information Window" | get-editbox | get-property text -raw | invoke toLowerCase ] {
+ invoke contains "procedure <b>open-new-class-dialog</b>" | verify-true
+ invoke contains "description of open-new-class-dialog"| verify-true
+}
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac--
diff --git a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Context.test b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Context.test
index 6805e06..d2aeb34 100644
--- a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Context.test
+++ b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/Content assist/Procedure documentation/Context.test
@@ -6,8 +6,8 @@
Element-Version: 3.0
External-Reference:
Id: _d1NdkCbREeSJvYFSUnsXEQ
-Runtime-Version: 2.0.1.201508250612
-Save-Time: 8/25/15 4:56 PM
+Runtime-Version: 2.2.0.201612300018
+Save-Time: 2/3/17 8:47 PM
Testcase-Type: ecl
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac
@@ -26,11 +26,8 @@
-get-window -from "Information Window" | get-control Browser | get-property text -raw | invoke toLowerCase | invoke contains
-
-"procedure <b>create-java-class</b>" | verify-true
-
-get-window -from "Information Window" | get-control Browser | get-property text -raw | invoke toLowerCase | invoke contains
-
-"description of create-java-class procedure" | verify-true
+with [get-window -from "Information Window" | get-editbox | get-property text -raw | invoke toLowerCase ] {
+ invoke contains "procedure <b>create-java-class</b>" | verify-true
+ invoke contains "description of create-java-class procedure" | verify-true
+}
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac--
diff --git a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/QS-2221_CheckErrorMessages.test b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/QS-2221_CheckErrorMessages.test
index bda90d6..ff5aa27 100644
--- a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/QS-2221_CheckErrorMessages.test
+++ b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/QS-2221_CheckErrorMessages.test
@@ -6,8 +6,8 @@
Element-Version: 3.0
External-Reference:
Id: _L_I_YP2xEeKZNomN8DrgVg
-Runtime-Version: 1.5.0.qualifier
-Save-Time: 6/15/14 5:46 PM
+Runtime-Version: 2.2.0.201612300018
+Save-Time: 2/3/17 8:58 PM
Testcase-Type: ecl
------=_.description-216f885c-d591-38ce-8ea2-e4f8cb4d6ffa
@@ -36,15 +36,13 @@
get-preferences-menu | click
with [get-window Preferences] {
+ maximize
get-tree | select "RCP Testing Tool/ECL Editor/Content Assist"
get-editbox -after [get-label "Auto Activation Delay (ms)"] | set-text ""
+ get-editbox -index 1 | get-property text | equals "Autoactivation delay should be positive number" | verify-true
+ get-editbox -after [get-label "Auto Activation Delay (ms)"] | set-text "-90"
+ get-editbox -index 1 | get-property text | equals "Autoactivation delay should be positive number" | verify-true
+ get-editbox -after [get-label "Auto Activation Delay (ms)"] | set-text 150
+ get-editbox -index 1 | get-property text | equals "Autoactivation delay should be positive number" | verify-false
}
-get-window Preferences | get-editbox -index 1 | get-property text | equals "Autoactivation delay should be positive number"
- | verify-true
-get-window Preferences | get-editbox -after [get-label "Auto Activation Delay (ms)"] | set-text "-90"
-get-window Preferences | get-editbox -index 1 | get-property text | equals "Autoactivation delay should be positive number"
- | verify-true
-get-window Preferences | get-editbox -after [get-label "Auto Activation Delay (ms)"] | set-text 150
-get-window Preferences | get-editbox -index 1 | get-property text | equals "Autoactivation delay should be positive number"
- | verify-false
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac--
diff --git a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/QS-2821_Add tooltip information for references.test b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/QS-2821_Add tooltip information for references.test
index 310d56b..e0d3ba0 100644
--- a/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/QS-2821_Add tooltip information for references.test
+++ b/rcpttTests/ECL_IDE_module/editors/ScenarioEditor/QS-2821_Add tooltip information for references.test
@@ -1,14 +1,13 @@
--- RCPTT testcase ---
Format-Version: 1.0
-Q7-vendor: www.xored.com/q7
Contexts: _ymiyse5IEeCU6db9MgIBkA,__ZTV8Au2EeOLiPM97zhEfw
Element-Name: QS-2821_Add tooltip information for references
Element-Type: testcase
Element-Version: 3.0
External-Reference:
Id: _hMoCUAu-EeOLiPM97zhEfw
-Q7-Runtime-Version: 1.5.0.201406131029
-Save-Time: 6/13/14 7:10 PM
+Runtime-Version: 2.2.0.201612300018
+Save-Time: 2/3/17 8:59 PM
Testcase-Type: ecl
------=_.description-216f885c-d591-38ce-8ea2-e4f8cb4d6ffa
@@ -40,7 +39,7 @@
hover-text 2 9
}
get-editor Dummy | get-section Script | get-text-viewer | hover-text 2 9
-with [get-window -from "Information Window" | get-control Browser] {
+with [get-window -from "Information Window" | get-editbox] {
get-property className | equals "org.eclipse.swt.browser.Browser" | verify-true
get-property text | contains "newClassTitle" | verify-true
}