Skip to content
This repository has been archived by the owner on Jan 14, 2019. It is now read-only.

FAQ and Troubleshooting

Dmitry Baev edited this page Jan 18, 2016 · 38 revisions

Can't generate report locally

  1. No implementation for org.eclipse.aether.RepositorySystem was bound. while locating ru.yandex.qatools.allure.report.AllureReportMojo
 **Solution**: Since 1.4.0 Allure required Maven version 3.1.1 or above

#### Java heap space related to org.aspectj.weaver.*
>You can see the following stacktrace:
>```
>java.lang.OutOfMemoryError: Java heap space
 at java.util.HashMap.createEntry(HashMap.java:869)
 at java.util.HashMap.addEntry(HashMap.java:856)
 at java.util.HashMap.put(HashMap.java:484)
 at java.util.HashSet.add(HashSet.java:217)
 at org.aspectj.apache.bcel.generic.InstructionHandle.addTargeter(InstructionHandle.java:161)
 at org.aspectj.apache.bcel.generic.MethodGen.<init>(MethodGen.java:300)
 at org.aspectj.weaver.bcel.LazyMethodGen.initialize(LazyMethodGen.java:366)
 at org.aspectj.weaver.bcel.LazyMethodGen.markAsChanged(LazyMethodGen.java:534)
 at org.aspectj.weaver.bcel.LazyMethodGen.getBody(LazyMethodGen.java:924)
 at org.aspectj.weaver.bcel.BcelShadow.makeShadowForMethod(BcelShadow.java:679)
 at org.aspectj.weaver.bcel.BcelShadow.makeMethodExecution(BcelShadow.java:675)
 at org.aspectj.weaver.bcel.BcelShadow.makeMethodExecution(BcelShadow.java:655)
 at org.aspectj.weaver.bcel.BcelClassWeaver.match(BcelClassWeaver.java:2618)
 at org.aspectj.weaver.bcel.BcelClassWeaver.weave(BcelClassWeaver.java:481)
 at org.aspectj.weaver.bcel.BcelClassWeaver.weave(BcelClassWeaver.java:101)
 at org.aspectj.weaver.bcel.BcelWeaver.weave(BcelWeaver.java:1691)
 at org.aspectj.weaver.bcel.BcelWeaver.weaveWithoutDump(BcelWeaver.java:1635)
 at org.aspectj.weaver.bcel.BcelWeaver.weaveAndNotify(BcelWeaver.java:1400)
 at org.aspectj.weaver.bcel.BcelWeaver.weave(BcelWeaver.java:1186)

Solution: add the following content to resources/META-INF/aop.xml:

<aspectj>
    <weaver options="">
        <include within="{mask for your classes package, 
                        'ru.yandex.qatools.allure..*' as example}"/>
    </weaver>
</aspectj>

See http://www.eclipse.org/aspectj/doc/released/devguide/ltw-configuration.html for more details.

Allure CLI: java.lang.RuntimeException: java.lang.IllegalArgumentException: Parameter 'directory' is not a directory

You should specify the path to the directory containing XML files, and not to XML files directly.

Solution: make sure you launch CLI as follows:

$ allure /path/to/directory/with/xml/files # CLI 2.0+

XML files created but no steps, attachments or parameters are present (mainly a Java issue)

You didn't specify the -javaagent JVM argument. This is mandatory when working with steps, attachments and parameters, because we're using AspectJ to process them.

Solution:: make sure the JVM is being launched with -javaagent path/to/aspectj-weaver.jar. See the example on how this is done with Maven.

XML files are successfully created during the test run but no HTML report is then generated

This is mainly caused by incompatible versions of the Allure adapter and report generator tool (CLI, Maven plugin, etc.). Versions 1.3.x and 1.4.x of Allure are using incompatible XML formats.

Solution: check that the Allure adapter version is equal to the Allure report generator version. So if you're using command line tool 1.3.9, then your Allure adapter version should also be 1.3.x. We guarantee full compatibility of minor versions (1.3.1 is compatible to 1.3.9, but 1.4.0 is not compatible to 1.3.9).

Escaping troubles: seeing &lt; and &gt; in the report instead of < and >

Titles and names containing these characters are incorrectly escaped.

Solution: You're probably using outdated JAXB implementation. Check that com.sun.xml.bind:jaxb-impl version 2.2.2 or later is used everywhere in your project.

Endless loading screen when open allure report using Chrome browser

See https://github.com/allure-framework/allure-core/wiki/FAQ-and-Troubleshooting#i-see-nothing-when-opening-the-report-page-in-my-browser--access-denied-message

Also it could be caused by Jenkins Security. Check that you have the correct security configuration in Jenkins with Allure

I see nothing when opening the report page in my browser \ "Access denied" message

This means that report data failed to load. Possible solutions:

  • When opening the report from the local file, either open it in Firefox or launch Chrome with the --allow-file-access-from-files flag. For other browsers, you need to enable cross-origin requests to local files.
  • Upload the report to the web server and open it from there
  • If you get a 404 error from the remote server, check logs in order to verify that the report was built successfully.
  • If you still experience problems, please email us Debug section contents and we'll help you to resolve the problem.
  • If your test framework is JUnit, check that you're using version 4. Allure is incompatible with version 3 of JUnit and that's why no data is gathered from tests.

Can't open report by link with file://

Allure is a rich application and requires addtional resources which cannot be loaded into local file. Please, use allure open command from allure-cli or use any web-server to see report on local machine

"Error getting reports from the plugin..." during Maven build

When running a Maven build with Allure Maven Plugin, you can see the following error:

[INFO] Error getting reports from the plugin 'ru.yandex.qatools.allure:allure-maven-plugin:1.3.7': Unable to load the mojo 'ru.yandex.qatools.allure:allure-maven-plugin:1.3.7:report' in the plugin 'ru.yandex.qatools.allure:allure-maven-plugin'. A required class is missing: Lorg/apache/maven/plugin/BuildPluginManager; org.apache.maven.plugin.BuildPluginManager

> **Solution:** you need to use Maven version 3.

#### Unsupported major.minor version 51.0
> This error can happen when trying to use any Allure code including examples:
> ```
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.16:test (default-test) on project allure-testng-example: Execution default-test of goal org.apache.maven.plugins:maven surefire-plugin:2.16:test failed: There was an error in the forked process
[ERROR] java.lang.UnsupportedClassVersionError: ru/yandex/qatools/allure/testng/AllureTestListener : Unsupported major.minor version 51.0
[ERROR] at java.lang.ClassLoader.defineClass1(Native Method)
[ERROR] at java.lang.ClassLoader.defineClassCond(ClassLoader.java:637)
[ERROR] at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
[ERROR] at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)

Solution: you need to use Java 1.7+.

java.lang.NoClassDefFoundError: org/apache/commons/io/Charsets

This error happens when you're using the Apache Commons IO library in your project and your version is below 2.4.

java.lang.NoClassDefFoundError: org/apache/commons/io/Charsets at ru.yandex.qatools.allure.utils.AllureResultsUtils.writeAttachment(AllureResultsUtils.java:95) at ru.yandex.qatools.allure.utils.AllureResultsUtils.writeAttachment(AllureResultsUtils.java:86) at ru.yandex.qatools.allure.events.MakeAttachEvent.process(MakeAttachEvent.java:25) at ru.yandex.qatools.allure.events.MakeAttachEvent.process(MakeAttachEvent.java:13) at ru.yandex.qatools.allure.Allure.fire(Allure.java:54) at ru.yandex.qatools.allure.aspects.AllureAttachAspects.attach(AllureAttachAspects.java:35)

> **Solution:** check that Apache Commons IO 2.4+ is used everywhere in your project.
Clone this wiki locally