Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show container logs on update test failure #5872

Merged
merged 1 commit into from Nov 23, 2020

Conversation

npepinpe
Copy link
Member

Description

In the refactoring, it seems I broke showing the container logs when the test fails. This was because the TestWatcher extension is called after the resources have been closed, as a TestWatcher is supposed to only report on outcomes. I've moved the onFailure of the ContainerState now to the after test callback, and we can see if it failed by checking if an exception was thrown and not caught during the test.

Definition of Done

Not all items need to be done depending on the issue and the pull request.

Code changes:

  • The changes are backwards compatibility with previous versions
  • If it fixes a bug then PRs are created to backport the fix to the last two minor versions. You can trigger a backport by assigning labels (e.g. backport stable/0.25) to the PR, in case that fails you need to create backports manually.

Testing:

  • There are unit/integration tests that verify all acceptance criterias of the issue
  • New tests are written to ensure backwards compatibility with further versions
  • The behavior is tested manually
  • The impact of the changes is verified by a benchmark

Documentation:

  • The documentation is updated (e.g. BPMN reference, configuration, examples, get-started guides, etc.)
  • New content is added to the release announcement

@npepinpe
Copy link
Member Author

This isn't backport to 0.24 because I already fixed it on that branch.

Copy link
Contributor

@MiguelPires MiguelPires left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

bors r+

zeebe-bors bot added a commit that referenced this pull request Nov 18, 2020
5872: Show container logs on update test failure r=MiguelPires a=npepinpe

## Description

In the refactoring, it seems I broke showing the container logs when the test fails. This was because the `TestWatcher` extension is called after the resources have been closed, as a `TestWatcher` is supposed to only report on outcomes. I've moved the `onFailure` of the `ContainerState` now to the after test callback, and we can see if it failed by checking if an exception was thrown and not caught during the test.

## Definition of Done

_Not all items need to be done depending on the issue and the pull request._

Code changes:
* [x] The changes are backwards compatibility with previous versions
* [x] If it fixes a bug then PRs are created to [backport](https://github.com/zeebe-io/zeebe/compare/stable/0.24...develop?expand=1&template=backport_template.md&title=[Backport%200.24]) the fix to the last two minor versions. You can trigger a backport by assigning labels (e.g. `backport stable/0.25`) to the PR, in case that fails you need to create backports manually.

Testing:
* [x] There are unit/integration tests that verify all acceptance criterias of the issue
* [x] New tests are written to ensure backwards compatibility with further versions
* [x] The behavior is tested manually
* [ ] The impact of the changes is verified by a benchmark 

Documentation: 
* [ ] The documentation is updated (e.g. BPMN reference, configuration, examples, get-started guides, etc.)
* [ ] New content is added to the [release announcement](https://drive.google.com/drive/u/0/folders/1DTIeswnEEq-NggJ25rm2BsDjcCQpDape)


Co-authored-by: Nicolas Pépin-Perreault <nicolas.pepin-perreault@camunda.com>
@zeebe-bors
Copy link
Contributor

zeebe-bors bot commented Nov 18, 2020

Build failed:

@npepinpe
Copy link
Member Author

bors retry

weird because only the bors check is red, its merge build passed

zeebe-bors bot added a commit that referenced this pull request Nov 18, 2020
5872: Show container logs on update test failure r=MiguelPires a=npepinpe

## Description

In the refactoring, it seems I broke showing the container logs when the test fails. This was because the `TestWatcher` extension is called after the resources have been closed, as a `TestWatcher` is supposed to only report on outcomes. I've moved the `onFailure` of the `ContainerState` now to the after test callback, and we can see if it failed by checking if an exception was thrown and not caught during the test.

## Definition of Done

_Not all items need to be done depending on the issue and the pull request._

Code changes:
* [x] The changes are backwards compatibility with previous versions
* [x] If it fixes a bug then PRs are created to [backport](https://github.com/zeebe-io/zeebe/compare/stable/0.24...develop?expand=1&template=backport_template.md&title=[Backport%200.24]) the fix to the last two minor versions. You can trigger a backport by assigning labels (e.g. `backport stable/0.25`) to the PR, in case that fails you need to create backports manually.

Testing:
* [x] There are unit/integration tests that verify all acceptance criterias of the issue
* [x] New tests are written to ensure backwards compatibility with further versions
* [x] The behavior is tested manually
* [ ] The impact of the changes is verified by a benchmark 

Documentation: 
* [ ] The documentation is updated (e.g. BPMN reference, configuration, examples, get-started guides, etc.)
* [ ] New content is added to the [release announcement](https://drive.google.com/drive/u/0/folders/1DTIeswnEEq-NggJ25rm2BsDjcCQpDape)


Co-authored-by: Nicolas Pépin-Perreault <nicolas.pepin-perreault@camunda.com>
@zeebe-bors
Copy link
Contributor

zeebe-bors bot commented Nov 18, 2020

Build failed:

@npepinpe
Copy link
Member Author

bors retry

zeebe-bors bot added a commit that referenced this pull request Nov 19, 2020
5872: Show container logs on update test failure r=MiguelPires a=npepinpe

## Description

In the refactoring, it seems I broke showing the container logs when the test fails. This was because the `TestWatcher` extension is called after the resources have been closed, as a `TestWatcher` is supposed to only report on outcomes. I've moved the `onFailure` of the `ContainerState` now to the after test callback, and we can see if it failed by checking if an exception was thrown and not caught during the test.

## Definition of Done

_Not all items need to be done depending on the issue and the pull request._

Code changes:
* [x] The changes are backwards compatibility with previous versions
* [x] If it fixes a bug then PRs are created to [backport](https://github.com/zeebe-io/zeebe/compare/stable/0.24...develop?expand=1&template=backport_template.md&title=[Backport%200.24]) the fix to the last two minor versions. You can trigger a backport by assigning labels (e.g. `backport stable/0.25`) to the PR, in case that fails you need to create backports manually.

Testing:
* [x] There are unit/integration tests that verify all acceptance criterias of the issue
* [x] New tests are written to ensure backwards compatibility with further versions
* [x] The behavior is tested manually
* [ ] The impact of the changes is verified by a benchmark 

Documentation: 
* [ ] The documentation is updated (e.g. BPMN reference, configuration, examples, get-started guides, etc.)
* [ ] New content is added to the [release announcement](https://drive.google.com/drive/u/0/folders/1DTIeswnEEq-NggJ25rm2BsDjcCQpDape)


Co-authored-by: Nicolas Pépin-Perreault <nicolas.pepin-perreault@camunda.com>
@zeebe-bors
Copy link
Contributor

zeebe-bors bot commented Nov 19, 2020

Build failed:

@npepinpe
Copy link
Member Author

The build hasn't finished yet and bors already failed it 🤔

@npepinpe
Copy link
Member Author

bors retry

zeebe-bors bot added a commit that referenced this pull request Nov 19, 2020
5872: Show container logs on update test failure r=MiguelPires a=npepinpe

## Description

In the refactoring, it seems I broke showing the container logs when the test fails. This was because the `TestWatcher` extension is called after the resources have been closed, as a `TestWatcher` is supposed to only report on outcomes. I've moved the `onFailure` of the `ContainerState` now to the after test callback, and we can see if it failed by checking if an exception was thrown and not caught during the test.

## Definition of Done

_Not all items need to be done depending on the issue and the pull request._

Code changes:
* [x] The changes are backwards compatibility with previous versions
* [x] If it fixes a bug then PRs are created to [backport](https://github.com/zeebe-io/zeebe/compare/stable/0.24...develop?expand=1&template=backport_template.md&title=[Backport%200.24]) the fix to the last two minor versions. You can trigger a backport by assigning labels (e.g. `backport stable/0.25`) to the PR, in case that fails you need to create backports manually.

Testing:
* [x] There are unit/integration tests that verify all acceptance criterias of the issue
* [x] New tests are written to ensure backwards compatibility with further versions
* [x] The behavior is tested manually
* [ ] The impact of the changes is verified by a benchmark 

Documentation: 
* [ ] The documentation is updated (e.g. BPMN reference, configuration, examples, get-started guides, etc.)
* [ ] New content is added to the [release announcement](https://drive.google.com/drive/u/0/folders/1DTIeswnEEq-NggJ25rm2BsDjcCQpDape)


Co-authored-by: Nicolas Pépin-Perreault <nicolas.pepin-perreault@camunda.com>
@zeebe-bors
Copy link
Contributor

zeebe-bors bot commented Nov 19, 2020

Build failed:

@npepinpe
Copy link
Member Author

bors retry

@zeebe-bors
Copy link
Contributor

zeebe-bors bot commented Nov 23, 2020

Build succeeded:

@zeebe-bors zeebe-bors bot merged commit a70033e into develop Nov 23, 2020
@zeebe-bors zeebe-bors bot deleted the np-fix-container-logs-on-fail branch November 23, 2020 08:43
@github-actions
Copy link
Contributor

Successfully created backport PR #5895 for stable/0.25.

zeebe-bors bot added a commit that referenced this pull request Nov 23, 2020
5895: [Backport stable/0.25] Show container logs on update test failure r=MiguelPires a=github-actions[bot]

# Description
Backport of #5872 to `stable/0.25`.

Co-authored-by: Nicolas Pépin-Perreault <nicolas.pepin-perreault@camunda.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants