[cleanup] Fix potential NPE in InteractionOrderingServices

Change-Id: I40f98fa68670c7a85d0b3398a1f39f0c4c9c3f96
Signed-off-by: Pierre-Charles David <pierre-charles.david@obeo.fr>
[test] Rename usecase data for this test

The data used for
RunRepairTest.testNoDirtyAfterMigrationWithFilterApplied has been
initially copied from CompositeFilterTest but not renamed.
The test RunRepairTest.testNoDirtyAfterMigrationWithFilterApplied fails
randomly on jenkins but not locally.
I think that this problem is due to a mix between the to use case data
without real explanation. 
This commit only renames the data to see if the problem persists or not
on jenkins.

Change-Id: I008e3b26f0314fa2a4a5afc91beea1963fd751fb
Signed-off-by: Laurent Redor <laurent.redor@obeo.fr>
[439095] Depend explicitly on Xerces


Bug: 439095
Change-Id: I4a6aca330832f428cc7aae82d005978c8c0a6420
Signed-off-by: Pierre-Charles David <pierre-charles.david@obeo.fr>
[437528] Handle edge centering during the arrange action.

* We now center the edge ends at the end of the arrange command.
* This commit fix the problem noticed in [1] (comment 15 of bug 437528).

[1] https://bugs.eclipse.org/bugs/show_bug.cgi?id=437528#c15

Bug: 437528
Change-Id: I71f06e71aeb89d53bc4d9deef21929c06ebcf4e5
Signed-off-by: Florian Barbin <florian.barbin@obeo.fr>
[430724] Enable the new saving policy when the Xtext bridge is present

It will be enabled for all sessions as soon as the oes.common.xtext
plug-in is available. AFAIK there is no existing mechanism which would
allow to be more precise.

Bug: 430724
Change-Id: Ic7932fb822200c3963a5926c5d75cb15d03885e3
Signed-off-by: Pierre-Charles David <pierre-charles.david@obeo.fr>
[test] The waited popup for session opening has not the right name.

After the opening of a session (UIResource.openSession();), we wait
that the load progress monitor popup is closed. But the popup title
currently used, "Progress Information", is not the right one. Currently,
the title is "Loading models" locally and "Loading models (as username)"
on Jenkins.
This probably explains some random failing tests (for example
ExportDiagramAsImagesTest).

Change-Id: Ie70d6afe977677ba2ec9af801a5b9e94e479d3ad
Signed-off-by: Laurent Redor <laurent.redor@obeo.fr>
[test] Use the default SWTBotPreferences.SCREENSHOTS_DIR folder 

Use the default SWTBotPreferences.SCREENSHOTS_DIR folder for
screenshots. This allows to override it by using system property
<org.eclipse.swtbot.screenshots.dir> as explained in the javadoc of this
constant. This is useful under Tycho to generate screenshots in the
"target" folder to be cleaned at each launch.

After this commit the pom.xml that launches test will be updated to
override <org.eclipse.swtbot.screenshots.dir> property with a line like
this:

<org.eclipse.swtbot.screenshots.dir>${project.build.directory}/screenshots</org.eclipse.swtbot.screenshots.dir>

Change-Id: If6baaf093572dcaee11d78722405f892740cb8aa
Signed-off-by: Laurent Redor <laurent.redor@obeo.fr>
[437528] Fix potential NPE if getArrangeCommand returns null.

Bug: 437528
Change-Id: Iea77e14cb9e64bd5e5d4620d5d5af282dc7317e2
Signed-off-by: Florian Barbin <florian.barbin@obeo.fr>
[445603] Do not save in a transaction if the domain is disposed

If we can detect the Transaction Editing Domain has already been
disposed when doSave() is invoked, do not try to use an exclusive
transaction, as its commit() will fail with an NPE in this case, causing
the later parts of doSave() not to be executed even though the resources
may have actually been saved correctly on disk.

If we cannot know for sure when the save is invoked (as is the case in
SaveSessionJob which is called asynchronously), play it safe and disable
the use of a transaction unconditionally.

Bug: 445603
Change-Id: I83ca3122ee1f9d84c1ee56aee532137b44f85cb8
Signed-off-by: Pierre-Charles David <pierre-charles.david@obeo.fr>
[445603] Save sessions in post-commit and in an exclusive transaction by default

Bug: 445603
Change-Id: I27168186f4d60c758b20028dcd5ef10e42576299
Signed-off-by: Pierre-Charles David <pierre-charles.david@obeo.fr>
[test] Override some SWTBot methods to use screenshots constant folder

The SWTBotTestCase.captureScreenshot() does not used the constant
SWTBotPreferences.SCREENSHOTS_DIR that allows to override it by using
system property
<org.eclipse.swtbot.screenshots.dir> as explained in the javadoc of this
constant.
This commit overrides and duplicates some methods to replace an hard
coded folder name by this constant

Change-Id: I384664ab548295c30db4688a174bfd09cc315027
Signed-off-by: Laurent Redor <laurent.redor@obeo.fr>
[test] Override the default SWTBotPreferences.SCREENSHOTS_DIR folder

Override the default SWTBotPreferences.SCREENSHOTS_DIR folder to set
this folder inside the "target" folder to be cleaned at each launch.

Change-Id: Ia5e40b12d40766986ba9ba84abbc2b4f2038582f
Signed-off-by: Laurent Redor <laurent.redor@obeo.fr>