Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ extensions:
Yandex\Allure\Adapter\AllureAdapter:
deletePreviousResults: false
outputDirectory: allure-results
ignoredAnnotations:
- env
- dataprovider
```

`deletePreviousResults` will clear all `.xml` files from output directory (this
Expand All @@ -37,6 +40,8 @@ relatively to Codeception output directory (also known as `paths: log` in
codeception.yml) unless you specify an absolute path. You can traverse up using
`..` as usual. `outputDirectory` defaults to `allure-results`.

`ignoredAnnotations` is used to define extra custom annotations to ignore. It is empty by default.

To generate report from your favourite terminal,
[install](https://github.com/allure-framework/allure-cli#installation)
allure-cli and run following command (assuming you're in project root and using
Expand Down
2 changes: 2 additions & 0 deletions src/Yandex/Allure/Adapter/AllureAdapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@

const OUTPUT_DIRECTORY_PARAMETER = 'outputDirectory';
const DELETE_PREVIOUS_RESULTS_PARAMETER = 'deletePreviousResults';
const IGNORED_ANNOTATION_PARAMETER = 'ignoredAnnotations';
const DEFAULT_RESULTS_DIRECTORY = 'allure-results';
const DEFAULT_REPORT_DIRECTORY = 'allure-report';
const INITIALIZED_PARAMETER = '_initialized';
Expand Down Expand Up @@ -82,6 +83,7 @@ public function _initialize(array $ignoredAnnotations = [])
// Add standard PHPUnit annotations
Annotation\AnnotationProvider::addIgnoredAnnotations($this->ignoredAnnotations);
// Add custom ignored annotations
$ignoredAnnotations = $this->tryGetOption(IGNORED_ANNOTATION_PARAMETER, []);
Annotation\AnnotationProvider::addIgnoredAnnotations($ignoredAnnotations);
$outputDirectory = $this->getOutputDirectory();
$deletePreviousResults =
Expand Down