We are pleased to introduce Alfresco LDTP library (IN Progress): a Java based automation suite that will enable GUI testing (Windows and MAC) of Alfresco desktop applications.
In our open source solution we used the following repositories:
For MAC you will need:
- OS X system with Xcode installed (tested on 10.9) If you experience any issues, please feel free to open a ticket in the issue tracker.
- please also follow the Getting Started with Pyatom section from official page.
For Windows you will need:
- Windows XP/ Windows 7 SP1 / Winows 8 - as a minimum requirement.
- please follow the Installation Instruction of Cobra LDTP from official page.
Please take a look on LDTP User Manual
The Sync-ldtp
project uses Travis CI.
The .travis.yml
config file can be found in the root of the repository.
- Build: Build project
- Deploy: Deployment by publishing a snapshot to Nexus
Travis CI builds differ by branch:
master
branch:- regular builds which in a Build stages;
- deploying the artifact on nexus with the version mentioned in
pom.xml
on the Deploy stage.
feature/*
/fix/*
branches:- regular builds which include only the Build stage;
All other branches are ignored.
In order to trigger a new build for other branch name, update the working copy of .travis.yml
with your branch name.
- Checkout the code and install all dependencies:
$ git clone https://github.com/Alfresco/Sync-ldtp
$ mvn clean install -DskipTests
$ mvn clean test -Dgroups=MacOnly -DexcludedGroups=Office
If you have Office 2011 installed on your MAC you can run the Office unit tests as well:
$ mvn clean test -Dtest=org.alfresco.os.mac.app.office.v2011.Excel2011Test
Please take a look on the unit tests already implemented for our classes. Bellow you will find also a snipet of how to create a simple folder as a End User will do in Finder:
import java.io.File;
import org.alfresco.os.mac.app.FinderExplorer;
public class TestFinder
{
public static void main(String[] args)
{
FinderExplorer finder = new FinderExplorer();
File testFolder = new File(finder.getApplicationPath(), "SampleFolder");
finder.openApplication(); // this will open the Default /Documents folder of the current user
// creating a new folder
finder.createFolder(testFolder);
// you can also specify other default startup path, or navigate to another folder
finder.openFolder(testFolder);
// go up one level
finder.goToEnclosingFolder();
// or delete the folder
finder.deleteFolder(testFolder);
finder.exitApplication();
}
}