Проблема:
В Jenkins генерируется пустой отчет от Allure 2.
Настройки:
Jenkins настроен на Ubuntu server
Установлен Allure Jenkins Plugin версии 2.26.0
Allur версии 2.6.0.
Настройки Allure Jenkins Plugin:
Вывод консоли Jenkins после прохождения тестов:
Started by user e[8mha:////4G+2kLWPW3+IoVnNhJM6AQqP9PUlZ1i2mANUBnbql7ePAAAAlB+LCAAAAAAAAP9b85aBtbiIQTGjNKU4P08vOT+vOD8nVc83PyU1x6OyILUoJzMv2y+/JJUBAhiZGBgqihhk0NSjKDWzXb3RdlLBUSYGJk8GtpzUvPSSDB8G5tKinBIGIZ+sxLJE/ZzEvHT94JKizLx0a6BxUmjGOUNodHsLgAymEgYO/dLi1CL9wkQAfBB1070AAAA=e[0mQA
Building in workspace /var/lib/jenkins/workspace/test2
[test2] $ /bin/sh -xe /tmp/jenkins1218746870063586306.sh
- cd /home/torcue/Tenx
- rm -rf /home/torcue/Tenx/allure-results/47a17f65-5e40-4ae3-b556-9a14a9bfc378-result.json /home/torcue/Tenx/allure-results/ab492a24-6e86-490f-b32f-ba5a0ad05a17-result.json /home/torcue/Tenx/allure-results/fdcfcaaf-f568-41e8-bd68-dd9aa0c0c798-result.json
- py.test Cclinic/TrackerDashboard/regression/tests/LoginPage/test_LoginPage.py --alluredir allure-results
============================= test session starts ==============================
platform linux – Python 3.6.3, pytest-3.4.0, py-1.5.2, pluggy-0.6.0
rootdir: /home/torcue/Tenx, inifile:
plugins: xdist-1.22.0, forked-0.2, allure-pytest-2.3.2b1
collected 3 items
Cclinic/TrackerDashboard/regression/tests/LoginPage/test_LoginPage.py … [ 66%]
. [100%]
========================== 3 passed in 52.83 seconds ===========================
[test2] $ /var/lib/jenkins/tools/ru.yandex.qatools.allure.jenkins.tools.AllureCommandlineInstallation/Allure/bin/allure generate -c -o /var/lib/jenkins/workspace/test2/allure-report
allure-results does not exists
Report successfully generated to /var/lib/jenkins/workspace/test2/allure-report
Allure report was successfully generated.
Creating artifact for the build.
Artifact was added to the build.
Finished: SUCCESS
Ругается на “allure-results does not exists”. Хотя папка существует и --alluredir allure-results сохранила данные для формирования отчета
Config job (/var/lib/jenkins/jobs/test2/config.xml):
<?xml version='1.0' encoding='UTF-8'?>
<project>
<description></description>
<keepDependencies>false</keepDependencies>
<properties/>
<scm class="hudson.scm.NullSCM"/>
<canRoam>true</canRoam>
<disabled>false</disabled>
<blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
<blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
<triggers/>
<concurrentBuild>false</concurrentBuild>
<builders>
<hudson.tasks.Shell>
<command>cd /home/torcue/Tenx
rm -rf /home/torcue/Tenx/allure-results/*
py.test Cclinic/TrackerDashboard/regression/tests/LoginPage/test_LoginPage.py --alluredir allure-results</command>
</hudson.tasks.Shell>
</builders>
<publishers>
<ru.yandex.qatools.allure.jenkins.AllureReportPublisher plugin="allure-jenkins-plugin@2.26.0">
<jdk></jdk>
<properties/>
<results>
<ru.yandex.qatools.allure.jenkins.config.ResultsConfig>
<path>allure-results</path>
</ru.yandex.qatools.allure.jenkins.config.ResultsConfig>
</results>
<reportBuildPolicy>ALWAYS</reportBuildPolicy>
<includeProperties>false</includeProperties>
<disabled>false</disabled>
<report>allure-report</report>
</ru.yandex.qatools.allure.jenkins.AllureReportPublisher>
</publishers>
<buildWrappers/>
</project>