Arquillian Core 1.4.0.Final Released

The Arquillian team is proud to announce the 1.4.0.Final release of the Arquillian Core component!

Extended expression language in Arquillian configuration

In arquillian.xml file, properties are always defined explicitly, as a system property ${myproperty} or as an environment variable ${env.myenvironment}. But in both cases values are set before test execution.

With this release, you can implement your own way of resolving values, not just system properties or environment variables.

You need to register a new Arquillian service in ExtensionBuilder and it must conform following signature:

interface PropertyResolver {
    String getValue(String key);
}

key attribute is the expression set in arquillian.xml file as property value and it returns the resolved value.

You can see how we implement at Arquillian Core the system property/environment variable resolution using this SPI at registration of PropertyResolver and implementing PropertyResolver.

Currently apart from resolving properties from system properties and environment variables, we added a resolution of locations from classpath. For example:

<container qualifier="${arquillian.container:default}">
  <configuration>
    <property name="javaVmArguments">-Djavax.net.ssl.trustStore=${classpath(store.jks)}</property>
  </configuration>
</container>

In this example, property javax.net.ssl.trustStore is going to be set to the absolute location of file store.jks which is relative to root classpath.

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 Core
Version 1.4.0.Final view tag
Release date 2018-02-27
Released by Matous Jobanek
Compiled against

Published artifacts org.jboss.arquillian.core

  • org.jboss.arquillian.core » arquillian-core-api jar javadoc pom
  • org.jboss.arquillian.core » arquillian-core-spi jar javadoc pom
  • org.jboss.arquillian.core » arquillian-core-impl-base jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-api jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-spi jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-impl-base jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-api jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-spi jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-impl-base jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-spi jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-impl-base jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-api jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-spi jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-impl-base jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-core jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-standalone jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-container jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-core jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-standalone jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-container jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-cdi jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-ejb jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-resource jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-initialcontext jar javadoc pom
  • org.jboss.arquillian.protocol » arquillian-protocol-servlet jar javadoc pom
  • org.jboss.arquillian.protocol » arquillian-protocol-jmx jar javadoc pom
  • org.jboss.arquillian » arquillian-bom pom

Release notes and resolved issues 2

Enhancement
  • ARQ-2177 - Extend expression language in arquillian configuration
Bug
  • ARQ-2175 - DeploymentExceptionHandler can sometimes pass null to transformers

Thanks to the following list of contributors: Matous Jobanek, Matej Novotny, Hemani, Bartosz Majsak, Alex Soto

Arquillian Core 1.3.0.Final Released

Since we wrote this post we didn't laze around. Check our latest announcement.

The Arquillian team is proud to announce the 1.3.0.Final release of the Arquillian Core component!

Deployment Archives using Java SPI

Usually, you deploy into a container using @Deployment annotation. But now you can implement your own strategy to generate deployable archive. For this purpose we created simplified Java SPI org.jboss.arquillian.container.test.spi.client.deployment.AutomaticDeployment.

The service must conform following signature:

/**
* Method called for generating the deployment configuration.
* @param testClass of current running test.
* @return Model object that contains all the information related to deployment configuration.
*/
DeploymentConfiguration generateDeploymentScenario(TestClass testClass);

Moreover, you can use @BeforeDeployment method annotation which allows you to modify the archive before it is deployed. The method must be public static and receive as a parameter an org.jboss.shrinkwrap.api.Archive which is the archive created by AutomaticDeployment implementation. The method returns enriched org.jboss.shrinkwrap.api.Archive based on your needs.

@BeforeDeployment
public static Archive addDeploymentContent(Archive archive) {
    // Modify Archive
    return archive;
}

Test Observer

The inner communication between Arquillian Core and other Arquillian extensions is based on the event machine. To get information about the event flow you can run your tests using the property -Darquillian.debug=true.

In case you need to add an additional logic to the whole test suite, you can use Arquillian SPI and create your own Arquillian extension to observe any event that you need. The downside of this approach is that this extension is applied to all test classes.

In this release, we introduce a new annotation @Observer. Adding it to the test class you can specify additional observers that will be applied only to this specific test class (without any need of using SPI). You can observe any Arquillian event in the context of the related test class that you need (starting with BeforeClass and ending with AfterClass):

@RunWith(Arquillian.class)
@Observer(MyObserver.class)
public class MyTestCase {

The Arquillian observer class has to have a non-parametric constructor and the observer method should be defined by @Observes annotation:

public void observeBeforeClass(@Observes BeforeClass event) {

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 Core
Version 1.3.0.Final view tag
Release date 2018-02-05
Released by Bartosz Majsak
Compiled against

Published artifacts org.jboss.arquillian.core

  • org.jboss.arquillian.core » arquillian-core-api jar javadoc pom
  • org.jboss.arquillian.core » arquillian-core-spi jar javadoc pom
  • org.jboss.arquillian.core » arquillian-core-impl-base jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-api jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-spi jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-impl-base jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-api jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-spi jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-impl-base jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-spi jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-impl-base jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-api jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-spi jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-impl-base jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-core jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-standalone jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-container jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-core jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-standalone jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-container jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-cdi jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-ejb jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-resource jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-initialcontext jar javadoc pom
  • org.jboss.arquillian.protocol » arquillian-protocol-servlet jar javadoc pom
  • org.jboss.arquillian.protocol » arquillian-protocol-jmx jar javadoc pom
  • org.jboss.arquillian » arquillian-bom pom

Release notes and resolved issues 2

Enhancement
  • ARQ-2173 - Create of SPI for auto-deployment feature
  • ARQ-2174 - Provide a way of observing Arqullian events within a test class

Thanks to the following list of contributors: Bartosz Majsak, Matous Jobanek, Alex Soto

Arquillian Core 1.2.1.Final Released

Since we wrote this post we didn't laze around. Check our latest announcement.

The Arquillian team is proud to announce the 1.2.1.Final release of the Arquillian Core component!

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 Core
Version 1.2.1.Final view tag
Release date 2018-01-23
Released by Bartosz Majsak
Compiled against

Published artifacts org.jboss.arquillian.core

  • org.jboss.arquillian.core » arquillian-core-api jar javadoc pom
  • org.jboss.arquillian.core » arquillian-core-spi jar javadoc pom
  • org.jboss.arquillian.core » arquillian-core-impl-base jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-api jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-spi jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-impl-base jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-api jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-spi jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-impl-base jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-spi jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-impl-base jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-api jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-spi jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-impl-base jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-core jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-standalone jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-container jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-core jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-standalone jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-container jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-cdi jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-ejb jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-resource jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-initialcontext jar javadoc pom
  • org.jboss.arquillian.protocol » arquillian-protocol-servlet jar javadoc pom
  • org.jboss.arquillian.protocol » arquillian-protocol-jmx jar javadoc pom
  • org.jboss.arquillian » arquillian-bom pom

Release notes and resolved issues 3

Enhancement
  • ARQ-2172 - Remove duplication in TestRunnerAdaptor
Bug
  • ARQ-2169 - Already Exported/Exploded directory should delete if exists before exploding/exporting
  • ARQ-2171 - @ClassRules should not be executed in container

Thanks to the following list of contributors: Bartosz Majsak, Matous Jobanek, Dipak Pawar

Arquillian Core 1.2.0.Final Released

Since we wrote this post we didn't laze around. Check our latest announcement.

The Arquillian team is proud to announce the 1.2.0.Final release of the Arquillian Core component!

Welcome JUnit Rules for Arquillian

Just before Christmas holidays we are extremely excited to ship long awaited feature for JUnit integration. If you want to use Arquillian Testing Platform with other JUnit Runner, you can now use JUnit Rules – ArquillianTestClass and ArquillianTest – and happily let Arquillian do the heavy lifting for your tests. Hats off to Alexander Schwartz for providing initial implementation.

To get the similar functionality what the @RunWith(Arquillian.class) is offering you should require both rules i.e. ArquillianTestClass and ArquillianTest.

@ClassRule
public static ArquillianTestClass arquillianTestClass = new ArquillianTestClass();

@Rule
public ArquillianTest arquillianTest = new ArquillianTest();

@Deployment
public static JavaArchive createDeployment() {
    return ShrinkWrap.create(JavaArchive.class)
        .addClass(Greeter.class)
        .addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml");
}

@Inject
Greeter greeter;

@Test
public void should_greet_earthlings() throws Exception {
    String name = "Earthlings";
    Assert.assertEquals("Hello, " + name, greeter.greet(name));
}

In order to use any other JUnit Class or Method Rule with ArquillianClassTest or ArquillianTest rule, you have to use it with RuleChain having arquillian rules defined as outer rules.. e.g.

@Rule
public MethodRule testWatchman = MethodRuleChain.outer(new ArquillianTest().around(new TestWatchman());

There is no chain for method rules out of the box provided by JUnit so we have our own and you can use it if you need.

If you would like to see it in action, take a look at following examples

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 Core
Version 1.2.0.Final view tag
Release date 2017-12-20
Released by Bartosz Majsak
Compiled against

Published artifacts org.jboss.arquillian.core

  • org.jboss.arquillian.core » arquillian-core-api jar javadoc pom
  • org.jboss.arquillian.core » arquillian-core-spi jar javadoc pom
  • org.jboss.arquillian.core » arquillian-core-impl-base jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-api jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-spi jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-impl-base jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-api jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-spi jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-impl-base jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-spi jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-impl-base jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-api jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-spi jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-impl-base jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-core jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-standalone jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-container jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-core jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-standalone jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-container jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-cdi jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-ejb jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-resource jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-initialcontext jar javadoc pom
  • org.jboss.arquillian.protocol » arquillian-protocol-servlet jar javadoc pom
  • org.jboss.arquillian.protocol » arquillian-protocol-jmx jar javadoc pom
  • org.jboss.arquillian » arquillian-bom pom

Release notes and resolved issues 1

Feature Request
  • ARQ-1828 - Replace Testrunner with a JUnit-Rule

Thanks to the following list of contributors: Bartosz Majsak, Dipak Pawar, Alexander Schwartz

Arquillian Core 1.1.15.Final Released

Since we wrote this post we didn't laze around. Check our latest announcement.

The Arquillian team is proud to announce the 1.1.15.Final release of the Arquillian Core component!

We have released yet another minor version of Arquillian Core. This time with long lasted fix for TestNG test failures reporting.

Support for new TestNG versions

Finally, we have a fix landed in TestNG and Arquillian Core, supporting newer versions of TestNG. So grab it while it’s hot.

One important note here if you want to rely only on Maven Central repository – TestNG 6.12 is not in Maven Central and 6.13 refers to JCommander version which is also not in Maven Central (sic!). You can read about the problem here.

You have two options to mitigate it:

  • Use recently published TestNG 6.13.1 having proper JCommander dependency
  • Add version of JCommander which is published to Maven Central before TestNG dependency (e.g. 1.69 or 1.72).
<dependency>
  <groupId>com.beust</groupId>
  <artifactId>jcommander</artifactId>
  <version>1.69</version>
  <scope>test</scope>
</dependency>
<dependency>
  <groupId>org.testng</groupId>
  <artifactId>testng</artifactId>
  <version>${version.testng}</version>
  <scope>test</scope>
</dependency>

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 Core
Version 1.1.15.Final view tag
Release date 2017-11-27
Released by Bartosz Majsak
Compiled against

Published artifacts org.jboss.arquillian.core

  • org.jboss.arquillian.core » arquillian-core-api jar javadoc pom
  • org.jboss.arquillian.core » arquillian-core-spi jar javadoc pom
  • org.jboss.arquillian.core » arquillian-core-impl-base jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-api jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-spi jar javadoc pom
  • org.jboss.arquillian.config » arquillian-config-impl-base jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-api jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-spi jar javadoc pom
  • org.jboss.arquillian.test » arquillian-test-impl-base jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-spi jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-impl-base jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-api jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-spi jar javadoc pom
  • org.jboss.arquillian.container » arquillian-container-test-impl-base jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-core jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-standalone jar javadoc pom
  • org.jboss.arquillian.junit » arquillian-junit-container jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-core jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-standalone jar javadoc pom
  • org.jboss.arquillian.testng » arquillian-testng-container jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-cdi jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-ejb jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-resource jar javadoc pom
  • org.jboss.arquillian.testenricher » arquillian-testenricher-initialcontext jar javadoc pom
  • org.jboss.arquillian.protocol » arquillian-protocol-servlet jar javadoc pom
  • org.jboss.arquillian.protocol » arquillian-protocol-jmx jar javadoc pom
  • org.jboss.arquillian » arquillian-bom pom

Release notes and resolved issues 3

Enhancement
  • ARQ-2156 - Preserve exception and it's context while throwing it.
Bug
  • ARQ-2086 - Test failures not reported with recent versions of TestNG
  • ARQ-2157 - Lookup value is null if classpath contains multiple ResourceProviders which canProvide lookup

Thanks to the following list of contributors: Bartosz Majsak, Dipak Pawar, George Gastaldi