Arquillian Drone Extension 1.2.0.Alpha2 Released

The Arquillian team is proud to announce the 1.2.0.Alpha2 release of the Arquillian Drone Extension component!

We’ve please to announce Drone 1.2.0.Alpha2. This release brings you PhantomJS support and an easier model for future extensions.


Significant changes since 1.2.0.Alpha1

Support for PhantomJS

PhantomJS allow you to run headless tests on a real browser. And Drone supports it out of the box.

arquillian.xml
<extension qualifier=“webdriver”>
<property name=“browserCapabilities”>phantomjs</property>
<property name=“phantomjs.binary.path”>/path/to/phantomjs.binary</property>
</extension>
Automatic Augmentation

RemoteWebDriver instances are now automatically augmented.

Discarding cookies for reusable browsers

You can now use reusable browser while ensuring cooking from previous test runs do not affect current test run. The default behavior is to delete the cookies. If you want to preserve previous behavior, you can use the reuseCookies configuration option.

arquillian.xml
<extension qualifier=“webdriver”>
<property name=“reuseCookies”>true</property>
</extension>

This release breaks implementation compatibility with previous Drone releases. You should not be affected by this unless you use Drone combined with other projects that depend on more then just SPI, such as Graphene 2. We are releasing new compatible versions of these projects; such as Graphene 2.0.0.Alpha4.
These changes were done in order to make Drone more reusable by third party projects to avoid similar problems in future.

I’d like to thank everybody involved in this release. You guys make testing a breeze!

We hope that you’ll enjoy the improvements and look forward to hear your feedback in the community forums.

What is Arquillian?

Arquillian is open source software that empowers you to test JVM-based applications more effectively. Created to defend the software galaxy from bugs, Arquillian brings your test to the runtime so you can focus on testing your application's behavior rather than managing the runtime. Using Arquillian, you can develop a comprehensive suite of tests from the convenience of your IDE and run them in any IDE, build tool or continuous integration environment.

Release details

Component Arquillian Drone Extension
Version 1.2.0.Alpha2 view tag
Release date 2013-04-12
Released by Lukas Fryc
Compiled against
  • Arquillian Core – 1.0.3.Final

Published artifacts org.jboss.arquillian.extension

  • org.jboss.arquillian.extension » arquillian-drone-api jar pom
  • org.jboss.arquillian.extension » arquillian-drone-bom pom
  • org.jboss.arquillian.extension » arquillian-drone-configuration jar pom
  • org.jboss.arquillian.extension » arquillian-drone-impl jar pom
  • org.jboss.arquillian.extension » arquillian-drone-selenium jar pom
  • org.jboss.arquillian.extension » arquillian-drone-selenium-depchain pom
  • org.jboss.arquillian.extension » arquillian-drone-selenium-server jar pom
  • org.jboss.arquillian.extension » arquillian-drone-spi jar pom
  • org.jboss.arquillian.extension » arquillian-drone-webdriver jar pom
  • org.jboss.arquillian.extension » arquillian-drone-webdriver-depchain pom

Release notes and resolved issues 11

PhantomJS; Automatic Augmentation; Discarding cookies for reusable browsers

Component Upgrade
  • ARQ-1308 - Update Selenium to 2.30.0
  • ARQ-1310 - Update Arquillian Core in Drone to 1.0.3.Final
  • ARQ-1349 - Drone: upgrade Selenium to 2.31.0 and phantomjsdriver to 1.0.3
Enhancement
  • ARQ-1314 - Better exception message when creating a new instance fails
  • ARQ-1350 - Drone: allow reuse of session even though all capabilities are not serializable
Feature Request
  • ARQ-1177 - Allow browser capabilities to be extensible
  • ARQ-1206 - Add configuration option to delete all cookies on reusable browser instance
  • ARQ-1307 - Support for GhostDriver / PhantomJS
  • ARQ-1351 - Drone: augment RemoteWebDriver instances automatically
  • ARQ-1363 - Drone SPI - provide service type for enhancing a instances instantiated by Drone
  • ARQ-1364 - Drone SPI - add DroneReady event fired when either class or method-level instance is created

Thanks to the following list of contributors: Lukas Fryc, Karel Piwko, Tomas Repel, Jiří Locker, Jan Papoušek, Aslak Knutsen

Graphene 2.0.0.Alpha4 Released

The Arquillian team is proud to announce the 2.0.0.Alpha4 release of the Graphene component!

As we are on the way to a first Beta release, we identified a need for sharing some of the recent Graphene improvements:

Highlighted Changes

Guard Improvements and Fixes

Request Guards were polished, extended and hardened. (read more)

Creating Page Fragments Programatically

Page Fragments can now be instantiated not only using dependency injection, but also programatically. (read more)

PhantomJS Support

You can now fully leverage awesomness of headless testing with PhantomJS.

Guarding Programatically Retrieved Elements

Elements retrieved programatically using WebElement#findElement(...) or WebElement#findElements(...) are now guarded against StaleElementReferenceException.

Automatic Inference of Locators

You no longer need to define a locator in simple forms – you can leverage their automatic inference from a injection point name. (read more)

Dependency Injection of SessionStorage and LocalStorage

These resources are now exposed directly via @ArquillianResource.

Dependency Injection of Selenium Resource Parametrized by WebElement

Selenium resources which takes WebElement as an argument in a constructor (e.g. Select) can be injected using FindBy.

Support for FindBys and FindBy(How, String)
 
Improved Integration with Drone

Drone 1.2.0.Alpha2’s new Enhancer API allow us to integrate with Drone seamlessly.

Deprecations

Deprecation of Old Variant of Waiting Fluent API

Graphene.element(...) and Graphene.attribute(...) are now deprecated and they will be removed in an upcoming releases.

Deprecated guardXhr replaced by guardAjax

Not all of us are familiar with abbreviation XHR (XMLHttpRequest). In order to make the API more clear for most of Graphene users, we have deprecated guardXhr and replaced it with guardAjax. guardXhr will be removed in upcoming releases.

Guard Improvements and Fixes

waitForHttp

When an Ajax request is followed by a relocation (HTTP request), guardXhr or guardHttp can’t deterministically wait for an end of a request – in these situations you can use waitForHttp instead.

Testing delayed requests

Guards now waits for a given time interval for a request to start and once the request is started, they wait the another interval for the request to finish.

Bug Fixes

Guards had problems on Android with deterministic waiting for HTTP requests.

Creating Page Fragments Programatically

Till this release, the only option to create a page fragment was injecting it:

@FindBy(...)
MyComponent component;

With Alpha4 we have added the possibility to create a page fragment programatically:

public <T> T getContent(Class<T> clazz) {
    return PageFragmentEnricher.createPageFragment(clazz, root);
}
@Test
public void testTabPanelSwitching() {
    Panel tab3 = tabPanel.switchTo(2);
    ContentOfTab content = tab3.getContent(ContentOfTab.class);
    assertEquals("The tab panel was not switched to third tab correctly!", "Content of the tab 3", content.text.getText());
    
    Panel tab1 = tabPanel.switchTo(0);
    content = tab1.getContent(ContentOfTab.class);
    assertEquals("The tab panel was not switched to first tab correctly!", "Content of the tab 1", content.text.getText());
}

You can find reference usage in this functional test together with an implementation of #getContent(Class<T>).

Automatic Inference of Locators

How many times you have written:

// look for input with a name 'firstname'
@FindBy(name = "firstname")
private WebElement firstname;

You can now simplify your tests to just

@FindBy
private WebElement firstname;

Graphene will automatically use the strategy How.ID_OR_NAME to locate the element by its ID or name.

Since this mechanism uses the strategy pattern, you can overwrite the default strategy for your test suite and therefore find elements by e.g. their class names or even JSF component IDs.

Roadmap

This release is a maintanance release on the way to Beta1.

What is Arquillian?

Arquillian is open source software that empowers you to test JVM-based applications more effectively. Created to defend the software galaxy from bugs, Arquillian brings your test to the runtime so you can focus on testing your application's behavior rather than managing the runtime. Using Arquillian, you can develop a comprehensive suite of tests from the convenience of your IDE and run them in any IDE, build tool or continuous integration environment.

Release details

Component Graphene
Version 2.0.0.Alpha4 view tag
Release date 2013-04-12
Released by Lukas Fryc
Compiled against
  • Arquillian Core – 1.0.3.Final

Published artifacts org.jboss.arquillian.graphene

  • org.jboss.arquillian.graphene » graphene-build-resources jar pom
  • org.jboss.arquillian.graphene » graphene-component-api jar pom
  • org.jboss.arquillian.graphene » graphene-selenium-api jar pom
  • org.jboss.arquillian.graphene » graphene-selenium-drone jar pom
  • org.jboss.arquillian.graphene » graphene-selenium-ftest-junit-container jar pom
  • org.jboss.arquillian.graphene » graphene-selenium-ftest-junit-standalone jar pom
  • org.jboss.arquillian.graphene » graphene-selenium-ftest-testng-container jar pom
  • org.jboss.arquillian.graphene » graphene-selenium-ftest-testng-standalone jar pom
  • org.jboss.arquillian.graphene » graphene-selenium-impl jar pom
  • org.jboss.arquillian.graphene » graphene-webdriver-ftest jar pom
  • org.jboss.arquillian.graphene » graphene-webdriver-impl jar pom
  • org.jboss.arquillian.graphene » graphene-webdriver-spi jar pom

Release notes and resolved issues 20

Q1/13: PhantomJS

Bug
  • ARQGRA-257 - Guards are not working with AndroidDriver
  • ARQGRA-262 - Element click with HTTP guard causes WebDriverException: ReferenceError: Graphene is not defined
  • ARQGRA-266 - Waiting for presence of element defined by jQuery selector sometimes causes "IllegalStateException: JQueryPageExtension can't be installed"
  • ARQGRA-272 - Introduced waitForHttp (guardXhr does not work for redirected pages)
  • ARQGRA-274 - The request guard does timeout for delayed requests
  • ARQGRA-289 - JavaScript interfaces fails on Chrome and PhantomJS
  • ARQGRA-290 - testAttributeIsPresent fails on Chrome and PhantomJS
Enhancement
  • ARQGRA-199 - Provide a way to create Page Fragments dynamically
  • ARQGRA-235 - Automatically infer ID locator from field name annotated just by @FindBy
  • ARQGRA-250 - Shortcut for waiting on element's attribute value
Feature Request
  • ARQGRA-220 - Locating elements with @FindBy(how = How.ID, using = "foobar") not working
  • ARQGRA-247 - Add support for enriching @FindBys annotations
  • ARQGRA-254 - Expose LocalStorage and SessionStorage enrichments directly
  • ARQGRA-258 - Provide injecting classes requiring WebElement in their constructors via @FindBy annotation
  • ARQGRA-259 - Provide timeout setting in fluent API
  • ARQGRA-273 - Intercept WebDriver to return proxies in findElement()/findElements() methods
Story
  • ARQGRA-286 - Support PhantomJSDriver in Graphene
Task
  • ARQGRA-168 - Create QUnit tests for Graphene.Page.RequestGuard.js
  • ARQGRA-284 - Rename guardXhr to guardAjax
  • ARQGRA-287 - Deprecate Graphene.element and attribute methods

Thanks to the following list of contributors: Jan Papoušek, Lukas Fryc, Juraj Huska, Jiri Stefek, Andreas Vallen

Arquillian GWT Testing extension 1.0.0.Alpha2 Released

The Arquillian team is proud to announce the 1.0.0.Alpha2 release of the Arquillian GWT Testing extension component!

This is an update of the Arquillian GWT extension to remove the need for the custom GwtArchive class. Arquillian GWT tests can now leverage the standard ShrinkWrap API for specifiying their deployments. The WebArchive is automatically enhanced to include all dependencies and configurations relevant to the GWT deployment.

Here’s an updated example of a complete test class:

GreeterRpcTest.java

@RunWith(Arquillian.class)
public class GreeterRpcTest extends ArquillianGwtTestCase {

  @Deployment
  public static WebArchive createDeployment() {
    return ShrinkWrap.create(WebArchive.class, "test.war")
      .addClass(Greeter.class)
      .addClass(GreetingService.class)
      .addClass(GreetingServiceImpl.class)
      .addAsWebInfResource(new File("src/main/webapp/WEB-INF/web.xml"));
  }

  @Test
  @RunAsGwtClient(moduleName = "org.myapp.MyGwtModule")
  public void testGreetingService() {
    GreetingServiceAsync greetingService = GWT.create(GreetingService.class);
    greetingService.greetServer("Hello!", new AsyncCallback<String>() {
      @Override
      public void onFailure(Throwable caught) {
        Assert.fail("Request failure: " + caught.getMessage());
      }

      @Override
      public void onSuccess(String result) {
        assertEquals("Received invalid response from Server", "Welcome!", result);
        finishTest();
      }
    });
    delayTestFinish(5000);
  }
}

Note that you will only need to extend ArquillianGwtTestCase if you want to inherit GWT’s asynchronous testing methods (finishTest and delayTestFinish).

We look forward to your feedback on this release in the community forums!

What is Arquillian?

Arquillian is open source software that empowers you to test JVM-based applications more effectively. Created to defend the software galaxy from bugs, Arquillian brings your test to the runtime so you can focus on testing your application's behavior rather than managing the runtime. Using Arquillian, you can develop a comprehensive suite of tests from the convenience of your IDE and run them in any IDE, build tool or continuous integration environment.

Release details

Component Arquillian GWT Testing extension
Version 1.0.0.Alpha2 view tag
Release date 2013-04-15
Released by Christian Sadilek
Compiled against
  • Arquillian Core – 1.0.2.Final

Published artifacts org.jboss.arquillian.extension

  • org.jboss.arquillian.extension » arquillian-gwt jar pom

Release notes and resolved issues 2

Automatic deployment archive enhancement for GWT

Feature Request
  • ARQ-1354 - Automatically enhance the deployment archive to include all dependencies and configurations relevant to the GWT deployment

Thanks to the following list of contributors: Christian Sadilek

Arquillian Persistence Extension 1.0.0.Alpha6 Released

The Arquillian team is proud to announce the 1.0.0.Alpha6 release of the Arquillian Persistence Extension component!

Arquillian Persistence Extension is back on the release train and the future plan is stronger than ever. The Alpha6 release brings a lot of improvements and fixes thanks to invaluable feedback from the community.

Big thanks go to Marco Cella, Matti Linnanvuori, Bernard Łabno, Tiago Wanke Marques, Karsten Ohme, Vineet Reynolds, Cyrill Ruettimann, Bryan Saunders, Anton Shaykin, Nicolas-Xavier Vanderlinden and Noah White for their feedback which led us to fix some minor annoyances and shortcomings of APE. We are proud of the vibrant and active community around Arquillian!

Some of the highlights in this release

Transaction support has been replaced with Transaction Extension. By default the JTA implementation is included. The only thing you will need to change in your tests is the import sttement for the @Transactional annotation. From now on it’s under org.jboss.arquillian.transaction.api.annotation.

Support for row ordering when comparing datasets. When using Generated ID’s for instance, such as UUID’s, the rows need to be sorted in order for the DbUnit comparison to pass. If they are not ordered, then the assertion is unreliable.

Improved error reporting, including rows comparision and misconfigured entries.

DTD support for flat XML data sets (DBUnit feature).

Proper support for multiple line SQL scripts with comments (ANSI SQL compliant)

We’ve also extended our test suite by adding Apache Derby to our continuous integration pipeline.

Important change: We re-groupped configuration entries arquillian.xml giving them more qualifiers:
persistence – for all basic settings
persistence-dbunit – for DBUnit specific configuration
persistence-script – for SQL related things
Please refer to our confluence documentation for detailed description.

We look forward to hearing your feedback about this release in the community forums!

What is Arquillian?

Arquillian is open source software that empowers you to test JVM-based applications more effectively. Created to defend the software galaxy from bugs, Arquillian brings your test to the runtime so you can focus on testing your application's behavior rather than managing the runtime. Using Arquillian, you can develop a comprehensive suite of tests from the convenience of your IDE and run them in any IDE, build tool or continuous integration environment.

Release details

Component Arquillian Persistence Extension
Version 1.0.0.Alpha6 view tag
Release date 2013-03-07
Released by Aslak Knutsen
Compiled against
  • Arquillian Core – 1.0.3.Final

Published artifacts org.jboss.arquillian.extension

  • org.jboss.arquillian.extension » arquillian-persistence-api jar pom
  • org.jboss.arquillian.extension » arquillian-persistence-impl jar pom
  • org.jboss.arquillian.extension » arquillian-persistence-integration-tests-testng jar pom

Release notes and resolved issues 25

Bug
  • ARQ-1028 - @ShouldMatchDataSet before persist
  • ARQ-1081 - DTD not supported by APE
  • ARQ-1086 - @CleanuUsingScript with phase NONE
  • ARQ-1087 - Wrong dump directory path
  • ARQ-1094 - @ShouldMatchDataSet Not Properly Comparing Datasets
  • ARQ-1100 - Datetime conversion does not work as expected for YAML data sets
  • ARQ-1101 - Exception with nested transaction with MySQL
  • ARQ-1127 - Order of scripts and data sets should be preserved when defined on class level
  • ARQ-1146 - Single statement which spans multiple lines is not handled properly
  • ARQ-1167 - Transactional support from Seam 3 interfere Persistence Extension resulting in ExclusiveTransactionException
  • ARQ-1208 - Multiple line statements are not handled properly
  • ARQ-1300 - Execute script handler does not properly ignore /* */ and {} ANSI compliant SQL comments
Enhancement
  • ARQ-1085 - Unify JPA Cache eviction events with APE
  • ARQ-1215 - Clean slf4j dependency
Feature Request
  • ARQ-1093 - Support for Row Ordering when Comparing Datasets
  • ARQ-1149 - Dataset comparision should collect all differences in the rows instead of failing on the first column
  • ARQ-1157 - Replace Persistence internal Transaction management with Transaction Extension
  • ARQ-1231 - Should observe required object ArquillianDescriptor instead of assuming Lifecycle
  • ARQ-1248 - Add Derby to the testing matrix
Task
  • ARQ-1342 - Clean up POM
  • ARQ-1343 - Schema creation scripts should be repeatable
Sub-task
  • ARQ-1158 - Extract JTA from APE and replace with Transaction Extension dependency
  • ARQ-1334 - Should inform if table defined for exclusion is not defined in the schema
  • ARQ-1335 - Should inform when non-defined configuration key encountered in arquillian.xml

Thanks to the following list of contributors: Bartosz Majsak, Aslak Knutsen, Vineet Reynolds, Jakub Narloch, Artur Dryomov

Arquillian GWT Testing extension 1.0.0.Alpha1 Released

The Arquillian team is proud to announce the 1.0.0.Alpha1 release of the Arquillian GWT Testing extension component!

This is the first release of the Arquillian GWT extension which aims to bring true integration testing to GWT.

Highlighted Features

Run GWT integration tests in Arquillian containers

This means that GWT integration tests can break free and execute in the actual runtime container instead of being tied to GWT’s embedded Jetty server.

Combining client-side and in-container tests

It is possible to combine GWT client-side and standard in-container tests in the same test class. This allows to test features without having to worry about the client-server bridge and should pave the way for future support of Arquillian Warp and Drone in GWT integration tests.

Getting Started

To start using the Arquillian GWT extension just add the following dependency to your project:

pom.xml
<dependency>
    <groupId>org.jboss.arquillian.extension</groupId>
    <artifactId>arquillian-gwt</artifactId>
    <version>1.0.0.Alpha1</version>
</dependency>

Writing Arquillian GWT tests

To run a test method as a GWT integration test either annotate the test class or test method with @RunAsGwtClient and specifiy the GWT module. If you annotate the test class all test methods in that class will run as GWT integration tests.

MyTestClass.java

@RunWith(Arquillian.class)
public class MyTestClass {

  @Test 
  @RunAsGwtClient(moduleName = "org.myapp.MyGwtModule")
  public void myGwtTest() {

  }
}

To help packaging your app for the test deployment Arquillian GWT provides a simple utility called GwtArchive. The next version of Arquillian GWT will automatically enhance the used WebArchive. So, you won’t need to use this utility in the future. Here’s a complete example:

GreeterRpcTest.java

@RunWith(Arquillian.class)
public class GreeterRpcTest extends ArquillianGwtTestCase {

  @Deployment
  public static WebArchive createDeployment() {
    return GwtArchive.get()
      .addClass(Greeter.class)
      .addClass(GreetingService.class)
      .addClass(GreetingServiceImpl.class);
  }

  @Test
  @RunAsGwtClient(moduleName = "org.myapp.MyGwtModule")
  public void testGreetingService() {
    GreetingServiceAsync greetingService = GWT.create(GreetingService.class);
    greetingService.greetServer("Hello!", new AsyncCallback<String>() {
      @Override
      public void onFailure(Throwable caught) {
        Assert.fail("Request failure: " + caught.getMessage());
      }

      @Override
      public void onSuccess(String result) {
        assertEquals("Received invalid response from Server", "Welcome!", result);
        finishTest();
      }
    });
    delayTestFinish(5000);
  }
}

Note that you will only need to extend ArquillianGwtTestCase if you want to inherit GWT’s asynchronous testing methods (finishTest and delayTestFinish).

We look forward to your feedback on this release in the community forums!

What is Arquillian?

Arquillian is open source software that empowers you to test JVM-based applications more effectively. Created to defend the software galaxy from bugs, Arquillian brings your test to the runtime so you can focus on testing your application's behavior rather than managing the runtime. Using Arquillian, you can develop a comprehensive suite of tests from the convenience of your IDE and run them in any IDE, build tool or continuous integration environment.

Release details

Component Arquillian GWT Testing extension
Version 1.0.0.Alpha1 view tag
Release date 2013-02-23
Released by Christian Sadilek
Compiled against
  • Arquillian Core – 1.0.2.Final

Published artifacts org.jboss.arquillian.extension

  • org.jboss.arquillian.extension » arquillian-gwt jar pom

Release notes and resolved issues 1

Initial prototype release

Thanks to the following list of contributors: Christian Sadilek, Karel Piwko, Aslak Knutsen